PD-97 Add unit test to check CLI/pypfb import#285
Open
paulineribeyre wants to merge 20 commits intomasterfrom
Open
PD-97 Add unit test to check CLI/pypfb import#285paulineribeyre wants to merge 20 commits intomasterfrom
paulineribeyre wants to merge 20 commits intomasterfrom
Conversation
|
The style in this PR agrees with This formatting comment was generated automatically by a script in uc-cdis/wool. |
Update test_cli to assert SystemExit 0
4d49336 to
740fc20
Compare
8c51895 to
befad2b
Compare
Avantol13
reviewed
Feb 4, 2026
| import pytest | ||
|
|
||
|
|
||
| def test_import_cli(monkeypatch): |
Contributor
There was a problem hiding this comment.
Suggested change
| def test_import_cli(monkeypatch): | |
| def test_import_cli(monkeypatch): | |
| """ | |
| Test that invoking the help from the CLI does not return an error | |
| """ |
Avantol13
reviewed
Feb 4, 2026
| # Load plug-ins from entry_points (syntax changes for python 3.12+) | ||
| major = sys.version_info[0] | ||
| minor = sys.version_info[1] | ||
| if major == 3 and minor >= 12: |
Contributor
There was a problem hiding this comment.
I would much rather try/catch than explicitly name major and minor versions in the code, but I don't feel super strongly about it. It's just that if in the long long future Python releases a 4 major, this is going to break again.
Avantol13
approved these changes
Feb 4, 2026
paulineribeyre
commented
Feb 4, 2026
Comment on lines
+354
to
+358
| for ep in entry_points(group="pfb.plugins"): | ||
| ep.load() | ||
| else: | ||
| for ep in entry_points().get("pfb.plugins", []): | ||
| ep.load() |
Contributor
Author
There was a problem hiding this comment.
i didn't look into how this works exactly, but it looks off to me that it's hardcoded to pfb.plugins here and called in both gen3/cli/pfb.py and gen3/cli/users.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Regression test for:
Link to JIRA ticket if there is one: https://ctds-planx.atlassian.net/browse/PD-97
New Features
Breaking Changes
Bug Fixes
Improvements
Dependency updates
Deployment changes