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

Improve error message using serde_path_to_error #55

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

shan-pandian
Copy link

  • Adds path information to improves error message

@Xuanwo
Copy link
Owner

Xuanwo commented Sep 17, 2024

Thank you for this PR! I'm looking for ways to implement it in serde-env directly without relying on serde_path_to_error.

@DASPRiD
Copy link

DASPRiD commented Oct 1, 2024

It just took me forever to figure out what was going on. I have a nested structure, and the error message was just saying missing field 'server', instead of telling me that e.g. the environment variable SERVER_ADDRESS is missing.

So yeah, we definitely need better error messages :)

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.

3 participants