8000 python: warn people that they should look through the list of `optional-dependencies` by jfly · Pull Request #878 · nix-community/nix-init · GitHub
[go: up one dir, main page]

Skip to content

python: warn people that they should look through the list of optional-dependencies - #878

Merged
figsoda merged 1 commit into
nix-community:mainfrom
jfly:skip-some-optional-deps
Nov 4, 2026
Merged

figsoda merged 1 commit into
nix-community:mainfrom
jfly:skip-some-optional-deps

Conversation

@jfly
@jfly jfly commented Sep 13, 2026
Copy link
Copy Markdown
Contributor

Based on feedback I received in
NixOS/nixpkgs#559596 (comment)

Comment thread src/codegen/python.rs Outdated
writeln!(out, " ];")?;

for (extra, deps) in optional {
// <<< TODO: link to justification, or if none exists, write up an explanation >>>
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@SuperSandro2000, is there any documentation I can link to to justify this code?

@jfly
jfly commented Sep 13, 2026
Copy link
Copy Markdown
Contributor Author

CI failures seem to be about a bunch of unused python packages still getting added to the package arguments. Will require a little more logic to skip them. Marking this PR as draft for now. I'll fix this if folks think this is a correct change to make.

@jfly
jfly marked this pull request as draft September 13, 2026 17:54
@jfly
jfly commented Oct 13, 2026
Copy link
Copy Markdown
Contributor Author

@SuperSandro2000, WDYT?

@SuperSandro2000 SuperSandro2000 left a comment
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't think it is that ready 😅 nox and sdist can probably be removed, too.

I think we need an interactive selection here otherwise this will become a never ending challenge

@jfly
jfly commented Oct 14, 2026
Copy link
Copy Markdown
Contributor Author

I think we need an interactive selection here otherwise this will become a never ending challenge

Honestly that seems like worse UX than just including everything and letting people remove unwanted groups in their preferred text editor (where they can look at things holistically, and use vcs+undo/redo, etc).

How about a simple comment above the dependency groups that the user is expected to read and act upon? Something like "There are multiple dependency groups, look through them and remove unnecessary ones such as test, etc".

@SuperSandro2000
Copy link
Copy Markdown
Member

Yeah, maybe the comment is the best.

@jfly
jfly force-pushed the skip-some-optional-deps branch from 2b51e00 to 124f16c Compare October 29, 2026 14:36
@jfly jfly changed the title python: skip dev and test optional-dependencies python: warn people that they should look through the list of optional-dependencies Oct 29, 2026
@jfly
jfly commented Oct 29, 2026
Copy link
Copy Markdown
Contributor Author

Yeah, maybe the comment is the best.

Updated, PTAL!

@jfly
jfly marked this pull request as ready for review October 29, 2026 14:47
@jfly
jfly requested a review from SuperSandro2000 October 29, 2026 14:47
@figsoda figsoda left a comment
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

some nixpkgs documentation on the convention would be nice

im also be open to having a preset ignore list alongside the comment

@figsoda
figsoda merged commit 75ea46a into nix-community:main Nov 4, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

0