Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running Mapper Generation in Docker #455

Closed
doddi321 opened this issue Jul 22, 2022 · 1 comment
Closed

Running Mapper Generation in Docker #455

doddi321 opened this issue Jul 22, 2022 · 1 comment

Comments

@doddi321
Copy link

I'm trying to use the generation tool to generate my mapper interfaces but every time I try to build my docker image I get an error.

System.IO.FileNotFoundException

#15 11.31 Restored /src/Application/Application.csproj (in 9.61 sec).
#15 11.31 Restored /src/WebApplication1/WebApplication1.csproj (in 9.61 sec).
#15 13.12 Application -> /app/build/Application.dll
#15 15.27 Tool 'mapster.tool' (version '8.3.0') was restored. Available commands: dotnet-mapster
#15 15.27
#15 15.27 Restore was successful.
#15 15.70 Cannot find assembly path: FluentValidation (type=package, version=11.1.0)
#15 15.71 Unhandled exception. System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types.
#15 15.71 Could not load file or assembly 'FluentValidation, Version=11.0.0.0, Culture=neutral, PublicKeyToken=7de548da2fbae0f0'. The system cannot find the file specified.
#15 15.71
#15 15.71 at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
#15 15.71 at System.Reflection.Assembly.GetTypes()
#15 15.71 at Mapster.Tool.Extensions.Scan(CodeGenerationConfig config, Assembly assembly) in C:\Projects\Mapster\src\Mapster.Tool\Extensions.cs:line 177
#15 15.71 at Mapster.Tool.Program.GenerateModels(ModelOptions opt) in C:\Projects\Mapster\src\Mapster.Tool\Program.cs:line 146
#15 15.71 at CommandLine.ParserResultExtensions.WithParsed[T](ParserResult1 result, Action1 action)
#15 15.71 at Mapster.Tool.Program.Main(String[] args) in C:\Projects\Mapster\src\Mapster.Tool\Program.cs:line 17
#15 15.71 System.IO.FileNotFoundException: Could not load file or assembly 'FluentValidation, Version=11.0.0.0, Culture=neutral, PublicKeyToken=7de548da2fbae0f0'. The system cannot find the file specified.
#15 15.71
#15 15.71 File name: 'FluentValidation, Version=11.0.0.0, Culture=neutral, PublicKeyToken=7de548da2fbae0f0'
#15 15.72 /src/Application/Application.csproj(11,3): error MSB3073: The command "dotnet mapster model -a "/app/build/Application.dll"" exited with code 134.
#15 15.73
#15 15.73 Build FAILED.
#15 15.73
#15 15.73 /src/Application/Application.csproj(11,3): error MSB3073: The command "dotnet mapster model -a "/app/build/Application.dll"" exited with code 134.
#15 15.73 0 Warning(s)
#15 15.73 1 Error(s)

I have a WebApplication1 project that depends on Application and the Application contains the mapper logic, I'm trying to build the image for WebApplication1.

@stagep
Copy link

stagep commented Jan 7, 2025

In order to identify issues that are still active, we are closing issues that we believe are either resolved or are dormant. If your issue is still active then please reopen. Thanks.

@stagep stagep closed this as completed Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants