-
Notifications
You must be signed in to change notification settings - Fork 85
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
Rethink dependency configuration in pyproject.toml
#614
Comments
+1,000,000. I'd prefer everything in the pyproject.toml to be PEP-621 compliant regardless of the build/env tools we use.
I want to be able to just run tests directly in the dev environment as this makes leveraging IDE debuggers and tooling much easier (hooking up nox to IDEs is a bunch of extra unnecessary work), so, I'd generally prefer to keep the None of that precludes using nox -- it provides a nice interface for running "sessions" which can encompass testing, linting, doc builds, etc. That way, you get one interface to learn, which you can use for everything. In that vein, I'd want a pre-commit session as well, or just to use nox for all the stuff we do with pre-commit.
uv and pixi can now dynamically calculate this, so we'd need to use those tools and setup our dependencies compliant with that. They can be used in conjunction with nox though. Or, we can add some custom code to parameterize all of our dependencies at whatever granularity; here's an example implimentation:
Depending on what you mean here, I don't necessarily agree with this one, but reducing dependency duplication would be nice. I'd very much prefer a top-level name: earthaccess
channels:
- conda-forge
- nodefaults
dependencies:
- python>=3.9
- pip
- pip:
- --editable .[dev] |
Would |
Yeah, that's fine so long as we test the matrix of those environments, and at least Another thing I'd add: we should also test managing our dependencies with conda-forge seperate from pip, which we can do with nox. Pandas, for example, has different dependency constraints across pip and conda, for the same release version 🤦. |
I could go with this. Although under the hood it's doing the same thing :) On one hand, meets people where they are; on the other hand, misses the opportunity to skill folks up in a more standard tool to use for a pure python project. 🤷 I really just care about the duplication ;) |
I created new issues for each of these things :) |
Perhaps you are already aware, but Poetry is not going to be PEP 621 compliant (i.e. use |
😲 I was certain it was compatible with standard PEP621 fields. I haven't tried of course 😆 Maybe it's a good time to switch to setuptools or hatchling for build? 😁 |
@mfisher87, I'm going to come down hard on this because, frankly, I find that an insulting assertion. Using conda for environment management is not a skill issue and has very little to do with how a package is built and dependencies are specified. Conda is the de facto standard for the Jupyter ecosystem, especially JupyterHubs, and in Earth Observation spaces, which this package is directly targeted at, conda/mamba is often the primary way to manage environments because EO tools frequently depend on non-python libraries that can be anywhere from annoying to install via pip to completely unavailable. |
@jhkennedy I apologize that you heard an insult in my comment; I absolutely did not intend to imply that people who use conda lack skill. I use conda & mamba almost every day myself. I'm trying to say that when we wrap the thing we're doing in conda-language, we're obfuscating what we're doing and missing an opportunity to teach what we're doing. |
I have a few things I'd like to address, and maybe they should each be separate issues, but figured we should start discussion here :)
pyproject.toml
use PEP621 conventions to specify dependencies #617The text was updated successfully, but these errors were encountered: