Skip to content
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

Option for the list command not to go out to the internet #1081

Closed
halloleo opened this issue Oct 11, 2023 · 3 comments · Fixed by #1163
Closed

Option for the list command not to go out to the internet #1081

halloleo opened this issue Oct 11, 2023 · 3 comments · Fixed by #1163
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@halloleo
Copy link

How would this feature be useful?

When using pipx while the system has no internet connection, pipx list takes an awful long time because before printing teh list of packages it tries to upgrade the shared libraries.

Describe the solution you'd like

The main purpose of the list command is to list what's there, so if I know I have no internet I should be able to say "Just give me the list. I don't care about doing other maintenance things." because these maintenance things won't work in any case.

Describe the solution you'd like
An option like --no-maintenance or --dont-update for the list command.

@dukecat0 dukecat0 added the enhancement New feature or request label Oct 12, 2023
@gaborbernat
Copy link
Contributor

PR welcome.

@gaborbernat gaborbernat added the help wanted Extra attention is needed label Dec 2, 2023
@dukecat0 dukecat0 added the good first issue Good for newcomers label Dec 9, 2023
@Gitznik
Copy link
Contributor

Gitznik commented Dec 22, 2023

I've had a quick look at this. From what I can see the only network connections during this command are in the shared_libs utility, that is called during verify_shared_libs.

While that step is simple enough to skip when a flag is provided, I'm wondering if there's a good way to verify in a test that the command does not attempt to make any network connections, especially in subprocesses. Happy to hear suggestions.

I'll work on this this weekend.

@halloleo
Copy link
Author

Cool. Glad to read the problem happens only in shard_libs.

Regarding a test: Maybe checking how long the command takes when it is running without network connection would give an indication: When it takes a time similar to the network timeout duration, it is probably trying to each the network...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants