-
Notifications
You must be signed in to change notification settings - Fork 340
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
Consolidate requirements and repository configuration #789
Consolidate requirements and repository configuration #789
Conversation
…options.extras_require in setup.cfg
…irements directory, which mimics the the dependencies under the "developer" options.extras_require
Codecov Report
@@ Coverage Diff @@
## master #789 +/- ##
==========================================
- Coverage 96.91% 96.91% -0.01%
==========================================
Files 70 70
Lines 6931 6930 -1
==========================================
- Hits 6717 6716 -1
Misses 214 214
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.
Looking good so far!
setup.cfg
Outdated
developer = | ||
# install everything for developers | ||
%(docs)s | ||
%(extras)s | ||
%(tests)s |
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.
wow, does that actually work? Sick! I guess the good folks over at sunpy (e.g. Stuart) didn't know about it, see:
Lines 12 to 13 in 91db401
# Dev is everything | |
extras["dev"] = list(chain(*extras.values())) |
we'll have to dump that, probably, and update the docs th
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.
darn touchpad, that dev
is now developer
.
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.
Yeah, I noticed this too and had no idea we could do this. I like it!
requirements.txt
Outdated
@@ -0,0 +1,8 @@ | |||
# all dependencies required to build, run, test, and doucment plasmapy |
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.
# all dependencies required to build, run, test, and doucment plasmapy | |
# all dependencies required to build, run, test, and document PlasmaPy |
setup.cfg
Outdated
tests = | ||
pytest >= 5.1 | ||
theory = | ||
# for plasmapy.theory |
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.
# for plasmapy.theory | |
# for plasmapy.formulary |
Astropy now requires Numpy version >= 1.16.0, so we probably ought to update that requirement in this PR to be consistent with them. |
requirements/install.txt
Outdated
astropy >= 3.1 | ||
colorama >= 0.3 | ||
matplotlib >= 3.2 | ||
numpy >= 1.14 |
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.
numpy >= 1.14 | |
numpy >= 1.16 |
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.
Does it, now? That's likely a sign of units issues going away!
I just realized that requirements information will be needed for the CodeMeta file, so it's likely there will be one more place that will need to be updated... This could be done just prior to every release, though. |
I've been thinking that this would be worthwhile to prioritise. Would you mind if I picked this up from here? |
@namurphy @rocco8773 a question. f150758 claims that the I would gladly remove it from the release guidelines 😜 |
One funny thing I realized with with the |
@rocco8773 I'm not quite sure what you were referring to with the BaPSFlib setup. I cleaned it up as much as I could for now, though. |
Two issues that I'd rather leave for the next PR to touch these: This would probably simplify our conda packaging process a little. https://github.com/rocco8773/PlasmaPy/blob/7769ee263e7c70353fac9fa3496b1ff2befba90f/tox.ini#L53-L90 I have not yet been able to simplify these, and would definitely like to. I suspect that there might be some way to specify "take the minimum of the range for these extras", maybe a pip install flag... but I don't know yet. I will turn these into issues once this gets merged. |
Look how I structured and commented the requirements between the |
The appropriate comments were already there, just with |
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.
This has stalled out long enough, and doesn't break stuff; in the interest of getting it through before we have to fix more merge conflicts, let's get it in!
The primary goal here is to consolidate how we define package requirements (build, install, tests, docs, etc.). Right now package requirements/dependencies are declared manually in many of the repository configuration files. After the refactor, dependencies should only be defined in the
requirements/*.txt
files and thesetup.cfg
file, with appropriate comments to direct developers. Any configuration file that needs dependencies should refer to the locations just mentioned.This will most likely include housekeeping of the repository configuration files.