question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Idea: Detect out-of-date environment in ”shell” and “run”

See original GitHub issue

Was working on Pipenv and got an ImportError when I do pipenv run .... Took me a minute to realise “oh yeah there’s a new dependency, I need to pipenv sync”.

It would be pretty neat if Pipenv can tell me something like

$ pipenv run ...
Notice: Your environment is out of sync to Pipfile.lock. Run pipenv sync or pipenv sync --dev to update!
[Attempt to run the script anyway]

I’m not sure if this is even feasible, but it would be a very-nice-to-have.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ncoghlancommented, May 25, 2018

Something that we could potentially do to make this a relatively fast check is to add a metadata file inside the venv directory that captures the lock file hash (which would thus go stale when git pull replaced your lock file).

I’d still be wary of adding that check to pipenv run for startup latency reasons, but that concern could be handled via a --skip-sync-check flag.

0reactions
uranusjrcommented, May 25, 2018

It still could take a while though. Maybe it’s a good idea to implement it as an opt-in, but that would make it a low-priority feature. I’m open to contributions if anyone is interested, however.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Jest | IntelliJ IDEA Documentation - JetBrains
... PHP · Python · Ruby · Shell scripts · Style sheets · TypeScript · XML · XPath and XSLT ... You can...
Read more >
`pipenv check` in a shell script errors from using outdated pip ...
Issue description. pipenv check works fine until I run it in a shell script. Then I get an error: pipenv install pipenv check...
Read more >
Cannot find the file specified when using subprocess.call('dir ...
On Windows with shell=True, the COMSPEC environment variable specifies the ... You do not need shell=True to run a batch file or console-based...
Read more >
Linux Shell / Shell Script Best Practices
Indicate the shell to run in the first line of shell scripts ... locate input and output based on the environment, such as...
Read more >
Frequently Asked Questions — Lmod 8.7.13 documentation
The issue is that some bash or tcsh users run ksh scripts and need access to the module command. In the K-shell, the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found