-
Notifications
You must be signed in to change notification settings - Fork 22
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 messages for absent/invalid schema path #22
Conversation
Precommit is still failing. Would like some help here, since this error is pretty opaque and I have no idea what's causing it. |
You'll likely need to run pre-commit on these files locally. The "Contributing" docs in Jupyter Server describe this better: https://github.com/jupyter-server/jupyter_server/blob/main/CONTRIBUTING.rst#code-styling We should probably add similar docs here. |
@Zsailer I was running it locally, but for some reason @blink1073 You know any other repos where this change should be made? |
Thanks, @dlqqq! |
The error messages for passing a path without a file present or for passing a string path (rather than a Pathlib object) to
EventLogger#register_event_schema()
were very obtuse. This PR addresses that and improves error output for both cases. Also:register_event_schema()
._load_schema()
. adds new exceptionsBefore
Passing a path without a file:
Passing a string path to
EventLogger#register_event_schema()
:After
Passing a path without a file:
Passing a string path to
EventLogger#register_event_schema()
:Notes
For some reason, pre-commit keeps failing my code while also not making any changes. Not sure if this will block the pipeline, so leaving a note here just in case.