Treating warnings as errors #262
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
@anushka255 - I'm seeing a lot of warnings on running the snakemake pipeline, primarily from
pandas. While these are not critical now, they will turn into hard-to-debug errors in the future (e.g.SettingWithCopyWarning) whenpandaschanges its behavior in some future version. The Aspire project, for example, decided to totally get rid ofpandasbecause they couldn't handle the regular API behavior changes from them.This PR treats all warnings as errors when running the tests, and should serve as a base PR to ensure we've weeded out all warnings. We can handle these gradually of course.
Trying to catch all warnings instead of only the ones from
pandasmight seem like an overkill, but I think the warnings originate from a handful of lines (unclosed files in tests, other changes likenp.random.shuffle(<series>) -> <series>.sample(frac=1)), so it should be manageable. If this turns into a never ending exercise then we can restrict ourselves topandas.