-
Notifications
You must be signed in to change notification settings - Fork 150
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
CommandHandleException with Command Name not command uuid #1491
Labels
Comments
Would you like to create a PR for this issue? |
I will try it. Give me some time. |
12 tasks
12 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is there an existing issue that is already proposing this?
Is your feature request related to a problem? Please describe it
Currently, we are having some random problems with the commandHandler that nestjs doesn't found the commandHandler, and this trigger the CommandHandlerException with an UUID, which makes it super dificult to debug.
Describe the solution you'd like
I would like that on the following line:
https://github.com/nestjs/cqrs/blob/master/src/command-bus.ts#L61
The name passed to the exception is the real name of the class, and not the ID. Currently I needed to go to the sourcecode in production, look at the line of the exception to search what command was failing.
Teachability, documentation, adoption, migration strategy
No response
What is the motivation / use case for changing the behavior?
Makes thinks easy to debug, I replicated a similar error here:
https://codesandbox.io/p/sandbox/exciting-wildflower-kqx3ky
And you can see the error is not really user friendly, If I had 4 or 5 commands, and after a refactor I get that error, It's not straight forward.
The text was updated successfully, but these errors were encountered: