-
Notifications
You must be signed in to change notification settings - Fork 52
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
[MAINT] Prevent workers from trying to parse sys.argv upon intialization #850
Merged
trallard
merged 2 commits into
conda-incubator:main
from
peytondmurray:849-prevent-worker-parse-argv
Aug 2, 2024
Merged
[MAINT] Prevent workers from trying to parse sys.argv upon intialization #850
trallard
merged 2 commits into
conda-incubator:main
from
peytondmurray:849-prevent-worker-parse-argv
Aug 2, 2024
Conversation
This file contains 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
peytondmurray
added
type: bug 🐛
Something isn't working
area: testing ✅
needs: review 👀
type: maintenance 🛠
labels
Jul 11, 2024
✅ Deploy Preview for conda-store canceled.
|
Hmm, seems like we the server gets stuck waiting for workers with this change...
|
Okay, it looks like we actually are passing arguments to the worker via the command line:
Not sure what the best path is here - we don't want traitlets to parse every argument, but we need to be able to pass some arguments (i.e. only the traitlets arguments). 🤔 |
peytondmurray
force-pushed
the
849-prevent-worker-parse-argv
branch
from
July 12, 2024 02:12
2fcbfcc
to
07a759e
Compare
Turned out to be a bad test fixture. Fixed now! |
Related: #594 |
peytondmurray
added
the
needs: discussion 💬
This item needs team-level discussion before scoping
label
Jul 23, 2024
trallard
approved these changes
Aug 2, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area: testing ✅
needs: discussion 💬
This item needs team-level discussion before scoping
needs: review 👀
type: bug 🐛
Something isn't working
type: maintenance 🛠
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.
Fixes #849.
Description
CondaStoreWorker
instances subclasstraitlets.Application
.traitlets
can parsesys.argv
to set configuration variables for the application. In certain situations e.g. runningpytest -svv
, the worker initializes and immediately tries to parse-svv
as atraitlets
configuration variable, which of course does not exist.This PR fixes the
conda_store_config
fixture, which incorrectly manipulatessys.argv
, and inadvertently allows pytest args to get parsed astraitlets
configuration settings.Other minor change: updated the
.gitignore
to includeconda-store-ui
static files, which I missed when the privatization PR went through.Pull request checklist
How to test
Here's the original offending pytest invocation, which now works as intended: