Closed EliottJaquierCPNV closed 2 years ago
I have experienced the same (or a similar) error on windows
Stack trace on Windows System.TypeInitializationException HResult=0x80131534 Message=The type initializer for 'MySql.Data.MySqlClient.MySqlConnectAttrs' threw an exception. Source=MySql.Data Arborescence des appels de procédure : at MySql.Data.MySqlClient.NativeDriver.SetConnectAttrs() at MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.Authenticate(Boolean reset) at MySql.Data.MySqlClient.NativeDriver.Authenticate(String authMethod, Boolean reset) at MySql.Data.MySqlClient.NativeDriver.Open() at MySql.Data.MySqlClient.Driver.Open() at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings) at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnection() at MySql.Data.MySqlClient.MySqlPool.GetPooledConnection() at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver() at MySql.Data.MySqlClient.MySqlPool.GetConnection() at MySql.Data.MySqlClient.MySqlConnection.Open() at ScannergicAPI.Repositories.DBConnector.OpenConnection() in C:\Users\eliot\Documents\GitHub\ScannergicBackendAPI\Scannergic\ScannergicAPI\Repositories\DBConnector.cs:line 44 at ScannergicAPI.Repositories.DBConnector.Select(String query) in C:\Users\eliot\Documents\GitHub\ScannergicBackendAPI\Scannergic\ScannergicAPI\Repositories\DBConnector.cs:line 69 at ScannergicAPI.Repositories.AllergenRequester.GetPlainAllergensInDB() in C:\Users\eliot\Documents\GitHub\ScannergicBackendAPI\Scannergic\ScannergicAPI\Repositories\AllergenRequester.cs:line 26 at TestScannergic.AllergenRequesterTests.GetPlainAllergensInDB_InitialCase_Success() in C:\Users\eliot\Documents\GitHub\ScannergicBackendAPI\Scannergic\TestScannergic\AllergenRequesterTests.cs:line 35
Exception interne 1 : FileNotFoundException : Could not load file or assembly 'System.Management, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Le fichier spécifié est introuvable.
new gitignore has resolve that problem
When accessing route /api/allergens, my server throw an Unhandled exception. II have a 'System.IO.FileNotFoundException: Could not load file or assembly 'System.Configuration.ConfigurationManager'
Request to this result
Config used (test server) :
Stack strace / sequence request in the test server:
info: Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker[3] Route matched with {action = "GetAllergens", controller = "Allergens"}. Executing controller action with signature ScannergicAPI.Entities.AllergenContainer GetAllergens() on controller ScannergicAPI.Controllers.AllergensController (ScannergicAPI).
info: Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker[2] Executed action ScannergicAPI.Controllers.AllergensController.GetAllergens (ScannergicAPI) in 133.973ms
info: Microsoft.AspNetCore.Routing.EndpointMiddleware[1] Executed endpoint 'ScannergicAPI.Controllers.AllergensController.GetAllergens (ScannergicAPI)'
fail: Microsoft.AspNetCore.Server.Kestrel[13] Connection id "0HMDUSA2LERPA", Request id "0HMDUSA2LERPA:00000002": An unhandled exception was thrown by the application. System.TypeInitializationException: The type initializer for 'MySql.Data.MySqlClient.Replication.ReplicationManager' threw an exception. ---> System.IO.FileNotFoundException: Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.