-
Hi, I've cloned mapperly, created one more Console project, added two project references:
After these manipulations, mapperly generates all the mappers, but I can't start debugging mapperly. Could you help me? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Note the compilation and therefore the execution of the source generator happens in a different process, before the command line application runs. Mapperly uses a compile constant |
Beta Was this translation helpful? Give feedback.
-
Hi, Thanks for the info here! but it might be good to add this as a part of readme or the official documentation. |
Beta Was this translation helpful? Give feedback.
Note the compilation and therefore the execution of the source generator happens in a different process, before the command line application runs.
Mapperly uses a compile constant
DEBUG_SOURCE_GENERATOR
to determine whether to attach a debugger. If it is set, it tries to attach a debugger (it usesDebugger.Launch()
on windows, on macos it tries to launch jetbrains rider) and waits for the connection of the debugger (up to 30seconds). If the automatic debugger attachment fails (eg. if rider can't be found on macos, you use linux, ...) you can use these 30 seconds to attach your debugger manually (for vs 2022 see attach to running processes). You can use theDefineConstants
dontet build or …