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.

Is there an easy way to upgrade python version in pipenv?

See original GitHub issue

There was an error in pipenv after I upgraded python by brew upgrade python and deleted old version by brew cleanup. To solve the problem, I have to run pipenv --rm and reinstall pipenv by pipenv install and this will installs all packages installed before. So is there an easy way to upgrade python version in pipenv?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:21 (5 by maintainers)

github_iconTop GitHub Comments

37reactions
uranusjrcommented, Jun 30, 2018

I believe pipenv install --python=/path/to/your/python automatically rebuilds the environment.

28reactions
andrewm4894commented, Sep 18, 2018

I think if you just do

pipenv --python 3.6

It will update the pipfile if needed AND apply the change. e.g. for me i got the below:

andrewm4894@dev:~/auto_arima$ pipenv --python 3.6
Virtualenv already exists!
Removing existing virtualenv...
Creating a virtualenv for this project...
Pipfile: /home/andrewm4894/auto_arima/Pipfile
Using /usr/bin/python3.6m (3.6.6) to create virtualenv...
⠋Running virtualenv with interpreter /usr/bin/python3.6m
Using base prefix '/usr'
New python executable in /home/andrewm4894/.local/share/virtualenvs/auto_arima-7RAnXuT8/bin/python3.6m
Also creating executable in /home/andrewm4894/.local/share/virtualenvs/auto_arima-7RAnXuT8/bin/python
Installing setuptools, pip, wheel...done.
Setting project for auto_arima-7RAnXuT8 to /home/andrewm4894/auto_arima

Virtualenv location: /home/andrewm4894/.local/share/virtualenvs/auto_arima-7RAnXuT8
Read more comments on GitHub >

github_iconTop Results From Across the Web

Change Python Version in Pipenv - Adebayo Osinulu - Medium
Change the “python_version” variable in your Pipfile to the new version you want. ... pipenv install --python=/path/to/your/python.
Read more >
Set python version when creating virtualenv using pipenv
"Edit the Pipfile" is the right way to go if you want to change the Python version of an existing environment. If you...
Read more >
Basic Usage of Pipenv - Read the Docs
$ cd myproject. Install from Pipfile, if there is one: · $ pipenv install. Or, add a package to your new project: ·...
Read more >
How to Manage your Python Projects with Pipenv and Pyenv
Managing Packages · pipenv install <package name> to install the latest version of the package under the [packages] section. · pipenv install < ......
Read more >
How to Update All Python Packages - ActiveState
This is because pip and pipenv do not resolve dependencies, unlike the ActiveState Platform. To ensure your environment doesn't break on upgrade ......
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