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

Exposing helpful error messages #150

Merged

Conversation

blast-hardcheese
Copy link
Member

  • Added error messages to polymorphic discriminators (previous error: scala.MatchError: foo (of class java.lang.String))
  • Exposed underlying circe decoding errors
  • Removed incorrect usage of NoContentException

Initial work towards #148, actually exposing validation errors in clients and servers. Customization will be more tricky, still need to think about how that will work.

@blast-hardcheese
Copy link
Member Author

This flips the needle to overcommunicating client failures, which may be undesirable for consumers looking for security through obscurity. If this is your use case, using akka-http's mapResponse directive to suppress these messages.

@blast-hardcheese blast-hardcheese merged commit 082cc15 into guardrail-dev:master Jan 8, 2019
@blast-hardcheese blast-hardcheese deleted the helpful-error-messages branch January 8, 2019 22:58
@sledorze
Copy link

sledorze commented Jan 8, 2019

@blast-hardcheese thanks a lot!

@blast-hardcheese
Copy link
Member Author

@sledorze You're welcome! 0.41.4 is now available

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

Successfully merging this pull request may close these issues.

2 participants