-
-
Notifications
You must be signed in to change notification settings - Fork 593
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
Add default format detection for Databook.load() #488
Conversation
Codecov Report
@@ Coverage Diff @@
## master #488 +/- ##
==========================================
+ Coverage 90.67% 91.28% +0.60%
==========================================
Files 28 28
Lines 2616 2638 +22
==========================================
+ Hits 2372 2408 +36
+ Misses 244 230 -14
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please do not mix so many issues in one commit. Each issue should be a separate commit, even separate PRs. For max line length, it's still something undecided, I'd rather not change it for now.
Not the best PR, indeed. It's a bunch of minor changes prior to push some adapters we're using in prod. So, in order to ease these and other contributions, would you consider setting those conventions and adding a code formatter as a pre-commit hook? Are there guidelines for this at Jazzband? |
Frankly, I think it would be better to let formatting issues aside and concentrate on "real" changes instead, separated by concern. |
Code formatting reduces diffs and merging conflicts, and saves developers' time. In what sense is not a "real" change? |
Thanks for the PR! Formatting is a real change, but please create another PR or issue for that (or see #401 and linked PRs) and keep this one focused. If anything, it'll help us get this format detection reviewed and merged sooner. Thank you! |
Right, I should have searched for such an issue... I'm going to close this PR (it's already too unfocused) and I'll open separate PRs. Anyway, are there some guidelines for linting and code formatting at Jazzband? |
It varies by project. This one has some linting done by pre-commit, which you run using the pre-commit commands or with |
Unlike
Dataset.load()
, which defaults toNone
,Databook.load()
needs an explicit format value.This code raises
TypeError: load() missing 1 required positional argument: 'format'
:This PR also (without api changes):
Databook._package()
..load()
.UnsupportedFormat
exception for whendetect_format
fails to avoid the "Format 'None' cannot be loaded.'" message.