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

Do not raise an exception if the github token cannot be found #5668

merged 1 commit into from Jan 18, 2022


Copy link

@fjetter fjetter commented Jan 18, 2022

Raising an exception during module import is a bit rude. More importantly, this can lead to pytest test discovery failures.

markers docs, see

Copy link

@ian-r-rose ian-r-rose left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


Copy link

ian-r-rose commented Jan 18, 2022

From my perspective, this isn't intended to be a module to be imported, just a one-off script, so an alt would be to ignore this directory in the pytest automagic crawling process

Copy link
Member Author

fjetter commented Jan 18, 2022

Right, I didn't even look at the file. I just delayed the exception to the main script code block such that it doesn't raise on import but only when executed. the pytest.skip would be a bit awkward

@fjetter fjetter merged commit feac52b into dask:main Jan 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

None yet

2 participants