Install from pipfile using pipenv install gives error
Asked Answered
C

6

19

I have a project where I'm trying to install from the pipfile using pipenv install. I get som error when installing. Before i describe the error, this is what I did:

  • Reinstall pipenv
  • Reinstall Python (by also removing all leftover folders and everything in PATH etc.)
  • Removing Python completely and then restarting computer and reinstalling again
  • Tried with both 32-bit and 64-bit version of Python

This is how I do:

  1. Downloading latest Python executable for Windows
  2. Installing the exec (tried both "quick install" and custom install for all users)
  3. Running Windows PowerShell as Administrator, doing pip install pipenv
  4. Going to my repository and running pipenv install

I also tried doing pipenv install inside pipenv shell. For all above I have the same error:

$ pipenv install
Installing dependencies from Pipfile.lock (8d815b)…
An error occurred while installing click==7.0 --hash=sha256:2335065e6395b9e67ca716de5f7526736bfa6ceead690adf616d925bdc622b13 --hash=sha256:5b94b49521f6456670fdb30cd82a4eca9412788a93fa6dd6df72c94d5a8ff2d7! Will try again.
An error occurred while installing flask==1.0.3 --hash=sha256:ad7c6d841e64296b962296c2c2dabc6543752985727af86a975072dea984b6f3 --hash=sha256:e7d32475d1de5facaa55e3958bc4ec66d3762076b074296aa50ef8fdc5b9df61! Will try again.
An error occurred while installing flask-cors==3.0.8 --hash=sha256:72170423eb4612f0847318afff8c247b38bd516b7737adfc10d1c2cdbb382d16 --hash=sha256:f4d97201660e6bbcff2d89d082b5b6d31abee04b1b3003ee073a6fd25ad1d69a! Will try again.
An error occurred while installing flask-jwt==0.3.2 --hash=sha256:49c0672fbde0f1cd3374bd834918d28956e3c521c7e00089cdc5380d323bd0ad! Will try again.
An error occurred while installing flask-sqlalchemy==2.4.0 --hash=sha256:0c9609b0d72871c540a7945ea559c8fdf5455192d2db67219509aed680a3d45a --hash=sha256:8631bbea987bc3eb0f72b1f691d47bd37ceb795e73b59ab48586d76d75a7c605! Will try again.
An error occurred while installing itsdangerous==1.1.0 --hash=sha256:321b033d07f2a4136d3ec762eac9f16a10ccd60f53c0c91af90217ace7ba1f19 --hash=sha256:b12271b2047cb23eeb98c8b5622e2e5c5e9abd9784a153e9d8ef9cb4dd09d749! Will try again.
An error occurred while installing jinja2==2.10.1 --hash=sha256:065c4f02ebe7f7cf559e49ee5a95fb800a9e4528727aec6f24402a5374c65013 --hash=sha256:14dd6caf1527abb21f08f86c784eac40853ba93edb79552aa1e4b8aef1b61c7b! Will try again.
An error occurred while installing markupsafe==1.1.1 --hash=sha256:00bc623926325b26bb9605ae9eae8a215691f33cae5df11ca5424f06f2d1f473 --hash=sha256:09027a7803a62ca78792ad89403b1b7a73a01c8cb65909cd876f7fcebd79b161 --hash=sha256:09c4b7f37d6c648cb13f9230d847adf22f8171b1ccc4d5682398e77f40309235 --hash=sha256:1027c282dad077d0bae18be6794e6b6b8c91d58ed8a8d89a89d5
9693b9131db5 --hash=sha256:24982cc2533820871eba85ba648cd53d8623687ff11cbb805be4ff7b4c971aff --hash=sha256:29872e92839765e546828bb7754a68c418d927cd064fd4708fab9fe9c8bb116b --hash=sha256:43a55c2930bbc139570ac2452adf3d70cdbb3cfe5912c71cdce1c2c6bbd9c5d1 --hash=sha256:46c99d2de99945ec5cb54f23c8cd5689f6d7177305ebff350a58ce5f8de1669e --hash=sha256:500d4957e52dd
c3351cabf489e79c91c17f6e0899158447047588650b5e69183 --hash=sha256:535f6fc4d397c1563d08b88e485c3496cf5784e927af890fb3c3aac7f933ec66 --hash=sha256:62fe6c95e3ec8a7fad637b7f3d372c15ec1caa01ab47926cfdf7a75b40e0eac1 --hash=sha256:6dd73240d2af64df90aa7c4e7481e23825ea70af4b4922f8ede5b9e35f78a3b1 --hash=sha256:717ba8fe3ae9cc0006d7c451f0bb265ee07739daf76355d063661
54ee68d221e --hash=sha256:79855e1c5b8da654cf486b830bd42c06e8780cea587384cf6545b7d9ac013a0b --hash=sha256:7c1699dfe0cf8ff607dbdcc1e9b9af1755371f92a68f706051cc8c37d447c905 --hash=sha256:88e5fcfb52ee7b911e8bb6d6aa2fd21fbecc674eadd44118a9cc3863f938e735 --hash=sha256:8defac2f2ccd6805ebf65f5eeb132adcf2ab57aa11fdf4c0dd5169a004710e7d --hash=sha256:98c7086708b163
d425c67c7a91bad6e466bb99d797aa64f965e9d25c12111a5e --hash=sha256:9add70b36c5666a2ed02b43b335fe19002ee5235efd4b8a89bfcf9005bebac0d --hash=sha256:9bf40443012702a1d2070043cb6291650a0841ece432556f784f004937f0f32c --hash=sha256:ade5e387d2ad0d7ebf59146cc00c8044acbd863725f887353a10df825fc8ae21 --hash=sha256:b00c1de48212e4cc9603895652c5c410df699856a2853135b39675
91e4beebc2 --hash=sha256:b1282f8c00509d99fef04d8ba936b156d419be841854fe901d8ae224c59f0be5 --hash=sha256:b2051432115498d3562c084a49bba65d97cf251f5a331c64a12ee7e04dacc51b --hash=sha256:ba59edeaa2fc6114428f1637ffff42da1e311e29382d81b339c1817d37ec93c6 --hash=sha256:c8716a48d94b06bb3b2524c2b77e055fb313aeb4ea620c8dd03a105574ba704f --hash=sha256:cd5df7552386641
0809ca100dc9681e301e3c27567cf498077e8551b6d20e42f --hash=sha256:e249096428b3ae81b08327a63a485ad0878de3fb939049038579ac0ef61e17e7! Will try again.
An error occurred while installing marshmallow==3.0.0rc7 --hash=sha256:1ba81630e38a4c143faf54833357758d0b013ba8b0707b115f795153e970e5c4 --hash=sha256:f8dcb1f1fb9ebd26b2edc91878f32a229a3c079520611a21955bf9d73be2ab41! Will try again.
An error occurred while installing pyjwt==1.4.2 --hash=sha256:87a831b7a3bfa8351511961469ed0462a769724d4da48a501cb8c96d1e17f570 --hash=sha256:99fe612dbe5f41e07124d9002c118c14f3ee703574ffa9779fee78135b8b94b6! Will try again.
An error occurred while installing pymysql==0.9.3 --hash=sha256:3943fbbbc1e902f41daf7f9165519f140c4451c179380677e6a848587042561a --hash=sha256:d8c059dcd81dedb85a9f034d5e22dcb4442c0b201908bede99e306d65ea7c8e7! Will try again.
An error occurred while installing six==1.12.0 --hash=sha256:3350809f0555b11f552448330d0b52d5f24c91a322ea4a15ef22629740f3761c --hash=sha256:d16a0141ec1a18405cd4ce8b4613101da75da0e9a7aec5bdd4fa804d0e0eba73! Will try again.
An error occurred while installing sqlalchemy==1.3.4 --hash=sha256:c7fef198b43ef31dfd783d094fd5ee435ce8717592e6784c45ba337254998017! Will try again.
An error occurred while installing werkzeug==0.15.4 --hash=sha256:865856ebb55c4dcd0630cdd8f3331a1847a819dda7e8c750d3db6f2aa6c0209c --hash=sha256:a0b915f0815982fb2a09161cb8f31708052d0951c3ba433ccc5e1aa276507ca6! Will try again.
  ================================ 14/14 - 00:00:01
Installing initially failed dependencies…
     ================================ 14/14 - 00:00:02
[pipenv.exceptions.InstallError]:   File "c:\program files\python37\lib\site-packages\pipenv\cli\command.py", line 254, in install
[pipenv.exceptions.InstallError]:       editable_packages=state.installstate.editables,
[pipenv.exceptions.InstallError]:   File "c:\program files\python37\lib\site-packages\pipenv\core.py", line 1874, in do_install
[pipenv.exceptions.InstallError]:       keep_outdated=keep_outdated
[pipenv.exceptions.InstallError]:   File "c:\program files\python37\lib\site-packages\pipenv\core.py", line 1253, in do_init
[pipenv.exceptions.InstallError]:       pypi_mirror=pypi_mirror,
[pipenv.exceptions.InstallError]:   File "c:\program files\python37\lib\site-packages\pipenv\core.py", line 862, in do_install_dependencies
[pipenv.exceptions.InstallError]:       _cleanup_procs(procs, False, failed_deps_queue, retry=False)
[pipenv.exceptions.InstallError]:   File "c:\program files\python37\lib\site-packages\pipenv\core.py", line 681, in _cleanup_procs
[pipenv.exceptions.InstallError]:       raise exceptions.InstallError(c.dep.name, extra=err_lines)
[pipenv.exceptions.InstallError]: []
[pipenv.exceptions.InstallError]: ['Could not import runpy module', "ModuleNotFoundError: No module named 'runpy'"]
ERROR: ERROR: Package installation failed...

I have tried googling this but have not found any solution. Since I'm a beginner at pip and pipenv, I'm at a total loss in what to do. I also ran python -m pipenv.help so that I could provide that info:

$ python -m pipenv.help
<details><summary>$ pipenv --support</summary>

Pipenv version: `'2018.11.26'`

Pipenv location: `'C:\\Program Files\\Python37\\lib\\site-packages\\pipenv'`

Python location: `'C:\\Program Files\\Python37\\python.exe'`

Python installations found:

  - `3.7.3`: `C:\Program Files\Python37\python.exe`

PEP 508 Information:


{'implementation_name': 'cpython',
 'implementation_version': '3.7.3',
 'os_name': 'nt',
 'platform_machine': 'AMD64',
 'platform_python_implementation': 'CPython',
 'platform_release': '10',
 'platform_system': 'Windows',
 'platform_version': '10.0.17134',
 'python_full_version': '3.7.3',
 'python_version': '3.7',
 'sys_platform': 'win32'}


System environment variables:

  - `ACLOCAL_PATH`
  - `ALLUSERSPROFILE`
  - `ANDROID_HOME`
  - `APPDATA`
  - `COMMONPROGRAMFILES`
  - `COMPUTERNAME`
  - `COMSPEC`
  - `CONFIG_SITE`
  - `CYGWIN_HOME`
  - `COMMONPROGRAMFILES(X86)`
  - `COMMONPROGRAMW6432`
  - `DISPLAY`
  - `DNX_HOME`
  - `DRIVERDATA`
  - `EXEPATH`
  - `GIT_PS1_SHOWDIRTYSTATE`
  - `GIT_PS1_SHOWSTASHSTATE`
  - `GIT_PS1_SHOWUNTRACKEDFILES`
  - `GIT_PS1_SHOWUPSTREAM`
  - `GRADLE_HOME`
  - `GYP_MSVS_VERSION`
  - `HOME`
  - `HOMEDRIVE`
  - `HOMEPATH`
  - `HOSTNAME`
  - `INFOPATH`
  - `JAVA_HOME`
  - `LANG`
  - `LOCALAPPDATA`
  - `LOGONSERVER`
  - `MANPATH`
  - `MINGW_CHOST`
  - `MINGW_PACKAGE_PREFIX`
  - `MINGW_PREFIX`
  - `MOZ_PLUGIN_PATH`
  - `MSYSTEM`
  - `MSYSTEM_CARCH`
  - `MSYSTEM_CHOST`
  - `MSYSTEM_PREFIX`
  - `NODE_PATH`
  - `NUMBER_OF_PROCESSORS`
  - `OLDPWD`
  - `ORIGINAL_PATH`
  - `ORIGINAL_TEMP`
  - `ORIGINAL_TMP`
  - `OS`
  - `ONEDRIVE`
  - `ONEDRIVECONSUMER`
  - `PATH`
  - `PATHEXT`
  - `PKG_CONFIG_PATH`
  - `PLINK_PROTOCOL`
  - `PROCESSOR_ARCHITECTURE`
  - `PROCESSOR_IDENTIFIER`
  - `PROCESSOR_LEVEL`
  - `PROCESSOR_REVISION`
  - `PROGRAMFILES`
  - `PS1`
  - `PSMODULEPATH`
  - `PUBLIC`
  - `PWD`
  - `PROGRAMDATA`
  - `PROGRAMFILES(X86)`
  - `PROGRAMW6432`
  - `REACT_APP_TEST_VAR`
  - `REACT_APP_TEST_VAR_TWO`
  - `SESSIONNAME`
  - `SHELL`
  - `SHLVL`
  - `SSH_AGENT_PID`
  - `SSH_ASKPASS`
  - `SSH_AUTH_SOCK`
  - `SYSTEMDRIVE`
  - `SYSTEMROOT`
  - `TEMP`
  - `TERM`
  - `TERMINAL_EMULATOR`
  - `TMP`
  - `TMPDIR`
  - `USERDOMAIN`
  - `USERDOMAIN_ROAMINGPROFILE`
  - `USERNAME`
  - `USERPROFILE`
  - `VS110COMNTOOLS`
  - `VS120COMNTOOLS`
  - `VS140COMNTOOLS`
  - `WINDIR`
  - `_`
  - `__INTELLIJ_COMMAND_HISTFILE__`
  - `PIP_DISABLE_PIP_VERSION_CHECK`
  - `PYTHONDONTWRITEBYTECODE`
  - `PIP_SHIMS_BASE_MODULE`
  - `PIP_PYTHON_PATH`
  - `PYTHONFINDER_IGNORE_UNSUPPORTED`

Pipenv–specific environment variables:


Debug–specific environment variables:

  - `PATH`: `C:\Users\mabj\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\local\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\mabj\bin;C:\Program Files\Python37\Scripts;C:\Program Files\Python37;C:\ProgramData\DockerDesktop\version-bin;C:\Program Files\D
ocker\Docker\Resources\bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\Intel\iCLS Client;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Dell\DW WLAN Card;C:\Program Files\Intel\iCLS Client;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;C:\Program Files\WIDCOMM\B
luetooth Software;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files\Git\cmd;C:\wamp64\bin\php\php7.1.23;C:\ProgramData\ComposerSetup\bin;C:\Users\mabj\AppData\Local\Android\sdk\platform-tools;C:\Users\mabj\AppData\Local\Android\sdk\tools;C:\Program Files (x86)\Microsoft Emulator Manager\1.0;C:\Program Files\PuTTY;C:\wamp64\bin\mysql\m
ysql5.7.14\bin;C:\Program Files (x86)\Gow\bin;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\WINDOWS\System32\OpenSSH;C:\Users\m
abj\.dnx\bin;C:\Program Files\Microsoft DNX\Dnvm;C:\Program Files\Microsoft SQL Server\130\Tools\Binn;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit;C:\cygwin64\bin;C:\Program Files\HashiCorp\Vault;C:\Program Files\nodejs;C:\Users\mabj\.dnx\bin;C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\Users\mabj\AppData\Roaming\np
m\node_modules\windows-build-tools\node_modules\.bin;C:\Users\mabj\AppData\Roaming\npm\node_modules\.bin;C:\Program Files\Docker\Docker\Resources\bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\Intel\iCLS Client;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Dell\DW WLAN Card;C:\Program Files\Intel\iCLS Client;C:
\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;C:\Program Files\WIDCOMM\Bluetooth Software;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files\Git\cmd;C:\wamp64\bin\php\php5.5.9;C:\ProgramData\ComposerSetup\bin;C:\Users\mabj\AppData\Local\Android\sdk\platform-tools;C:\Users\mabj\AppData\
Local\Android\sdk\tools;C:\Program Files (x86)\Microsoft Emulator Manager\1.0;C:\Program Files\PuTTY;C:\Program Files\nodejs;C:\wamp64\bin\mysql\mysql5.7.14\bin;C:\Program Files (x86)\Gow\bin;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel
\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\WINDOWS\System32\OpenSSH;C:\Program Files\Microsoft DNX\Dnvm;C:\Program Files\Microsoft SQL Server\130\Tools\Binn;C:\Ruby24-x64\bin;C:\Users\mabj\AppData\Local\Microsoft\WindowsApps;C:\Users\mabj\AppData\Roaming\Composer\vendor\bin;C:\Users\mabj
\AppData\Roaming\npm;C:\Program Files\Git\usr\bin\vendor_perl;C:\Program Files\Git\usr\bin\core_perl`
  - `SHELL`: `C:\Program Files\Git\usr\bin\bash.exe`
  - `LANG`: `sv_SE.UTF-8`
  - `PWD`: `C:/Users/mabj/Documents/repos/Philipsonska/philipsonska-api`


---------------------------

Contents of `Pipfile` ('C:\\Users\\mabj\\Documents\\repos\\Philipsonska\\philipsonska-api\\Pipfile'):

toml
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]

[packages]
flask-sqlalchemy = "*"
marshmallow = "*"
flask-cors = "*"
flask-jwt = "*"
pymysql = "*"

[requires]
python_version = "3.7"

[pipenv]
allow_prereleases = true




Contents of `Pipfile.lock` ('C:\\Users\\mabj\\Documents\\repos\\Philipsonska\\philipsonska-api\\Pipfile.lock'):

json
{
    "_meta": {
        "hash": {
            "sha256": "604f57d1e28a03d51d7def19bb003c466e6a9bdca8c852a20b83d6159c8d815b"
        },
        "pipfile-spec": 6,
        "requires": {
            "python_version": "3.7"
        },
        "sources": [
            {
                "name": "pypi",
                "url": "https://pypi.org/simple",
                "verify_ssl": true
            }
        ]
    },
    "default": {
        "click": {
            "hashes": [
                "sha256:2335065e6395b9e67ca716de5f7526736bfa6ceead690adf616d925bdc622b13",
                "sha256:5b94b49521f6456670fdb30cd82a4eca9412788a93fa6dd6df72c94d5a8ff2d7"
            ],
            "version": "==7.0"
        },
        "flask": {
            "hashes": [
                "sha256:ad7c6d841e64296b962296c2c2dabc6543752985727af86a975072dea984b6f3",
                "sha256:e7d32475d1de5facaa55e3958bc4ec66d3762076b074296aa50ef8fdc5b9df61"
            ],
            "version": "==1.0.3"
        },
        "flask-cors": {
            "hashes": [
                "sha256:72170423eb4612f0847318afff8c247b38bd516b7737adfc10d1c2cdbb382d16",
                "sha256:f4d97201660e6bbcff2d89d082b5b6d31abee04b1b3003ee073a6fd25ad1d69a"
            ],
            "index": "pypi",
            "version": "==3.0.8"
        },
        "flask-jwt": {
            "hashes": [
                "sha256:49c0672fbde0f1cd3374bd834918d28956e3c521c7e00089cdc5380d323bd0ad"
            ],
            "index": "pypi",
            "version": "==0.3.2"
        },
        "flask-sqlalchemy": {
            "hashes": [
                "sha256:0c9609b0d72871c540a7945ea559c8fdf5455192d2db67219509aed680a3d45a",
                "sha256:8631bbea987bc3eb0f72b1f691d47bd37ceb795e73b59ab48586d76d75a7c605"
            ],
            "index": "pypi",
            "version": "==2.4.0"
        },
        "itsdangerous": {
            "hashes": [
                "sha256:321b033d07f2a4136d3ec762eac9f16a10ccd60f53c0c91af90217ace7ba1f19",
                "sha256:b12271b2047cb23eeb98c8b5622e2e5c5e9abd9784a153e9d8ef9cb4dd09d749"
            ],
            "version": "==1.1.0"
        },
        "jinja2": {
            "hashes": [
                "sha256:065c4f02ebe7f7cf559e49ee5a95fb800a9e4528727aec6f24402a5374c65013",
                "sha256:14dd6caf1527abb21f08f86c784eac40853ba93edb79552aa1e4b8aef1b61c7b"
            ],
            "version": "==2.10.1"
        },
        "markupsafe": {
            "hashes": [
                "sha256:00bc623926325b26bb9605ae9eae8a215691f33cae5df11ca5424f06f2d1f473",
                "sha256:09027a7803a62ca78792ad89403b1b7a73a01c8cb65909cd876f7fcebd79b161",
                "sha256:09c4b7f37d6c648cb13f9230d847adf22f8171b1ccc4d5682398e77f40309235",
                "sha256:1027c282dad077d0bae18be6794e6b6b8c91d58ed8a8d89a89d59693b9131db5",
                "sha256:24982cc2533820871eba85ba648cd53d8623687ff11cbb805be4ff7b4c971aff",
                "sha256:29872e92839765e546828bb7754a68c418d927cd064fd4708fab9fe9c8bb116b",
                "sha256:43a55c2930bbc139570ac2452adf3d70cdbb3cfe5912c71cdce1c2c6bbd9c5d1",
                "sha256:46c99d2de99945ec5cb54f23c8cd5689f6d7177305ebff350a58ce5f8de1669e",
                "sha256:500d4957e52ddc3351cabf489e79c91c17f6e0899158447047588650b5e69183",
                "sha256:535f6fc4d397c1563d08b88e485c3496cf5784e927af890fb3c3aac7f933ec66",
                "sha256:62fe6c95e3ec8a7fad637b7f3d372c15ec1caa01ab47926cfdf7a75b40e0eac1",
                "sha256:6dd73240d2af64df90aa7c4e7481e23825ea70af4b4922f8ede5b9e35f78a3b1",
                "sha256:717ba8fe3ae9cc0006d7c451f0bb265ee07739daf76355d06366154ee68d221e",
                "sha256:79855e1c5b8da654cf486b830bd42c06e8780cea587384cf6545b7d9ac013a0b",
                "sha256:7c1699dfe0cf8ff607dbdcc1e9b9af1755371f92a68f706051cc8c37d447c905",
                "sha256:88e5fcfb52ee7b911e8bb6d6aa2fd21fbecc674eadd44118a9cc3863f938e735",
                "sha256:8defac2f2ccd6805ebf65f5eeb132adcf2ab57aa11fdf4c0dd5169a004710e7d",
                "sha256:98c7086708b163d425c67c7a91bad6e466bb99d797aa64f965e9d25c12111a5e",
                "sha256:9add70b36c5666a2ed02b43b335fe19002ee5235efd4b8a89bfcf9005bebac0d",
                "sha256:9bf40443012702a1d2070043cb6291650a0841ece432556f784f004937f0f32c",
                "sha256:ade5e387d2ad0d7ebf59146cc00c8044acbd863725f887353a10df825fc8ae21",
                "sha256:b00c1de48212e4cc9603895652c5c410df699856a2853135b3967591e4beebc2",
                "sha256:b1282f8c00509d99fef04d8ba936b156d419be841854fe901d8ae224c59f0be5",
                "sha256:b2051432115498d3562c084a49bba65d97cf251f5a331c64a12ee7e04dacc51b",
                "sha256:ba59edeaa2fc6114428f1637ffff42da1e311e29382d81b339c1817d37ec93c6",
                "sha256:c8716a48d94b06bb3b2524c2b77e055fb313aeb4ea620c8dd03a105574ba704f",
                "sha256:cd5df75523866410809ca100dc9681e301e3c27567cf498077e8551b6d20e42f",
                "sha256:e249096428b3ae81b08327a63a485ad0878de3fb939049038579ac0ef61e17e7"
            ],
            "version": "==1.1.1"
        },
        "marshmallow": {
            "hashes": [
                "sha256:1ba81630e38a4c143faf54833357758d0b013ba8b0707b115f795153e970e5c4",
                "sha256:f8dcb1f1fb9ebd26b2edc91878f32a229a3c079520611a21955bf9d73be2ab41"
            ],
            "index": "pypi",
            "version": "==3.0.0rc7"
        },
        "pyjwt": {
            "hashes": [
                "sha256:87a831b7a3bfa8351511961469ed0462a769724d4da48a501cb8c96d1e17f570",
                "sha256:99fe612dbe5f41e07124d9002c118c14f3ee703574ffa9779fee78135b8b94b6"
            ],
            "version": "==1.4.2"
        },
        "pymysql": {
            "hashes": [
                "sha256:3943fbbbc1e902f41daf7f9165519f140c4451c179380677e6a848587042561a",
                "sha256:d8c059dcd81dedb85a9f034d5e22dcb4442c0b201908bede99e306d65ea7c8e7"
            ],
            "index": "pypi",
            "version": "==0.9.3"
        },
        "six": {
            "hashes": [
                "sha256:3350809f0555b11f552448330d0b52d5f24c91a322ea4a15ef22629740f3761c",
                "sha256:d16a0141ec1a18405cd4ce8b4613101da75da0e9a7aec5bdd4fa804d0e0eba73"
            ],
            "version": "==1.12.0"
        },
        "sqlalchemy": {
            "hashes": [
                "sha256:c7fef198b43ef31dfd783d094fd5ee435ce8717592e6784c45ba337254998017"
            ],
            "version": "==1.3.4"
        },
        "werkzeug": {
            "hashes": [
                "sha256:865856ebb55c4dcd0630cdd8f3331a1847a819dda7e8c750d3db6f2aa6c0209c",
                "sha256:a0b915f0815982fb2a09161cb8f31708052d0951c3ba433ccc5e1aa276507ca6"
            ],
            "version": "==0.15.4"
        }
    },
    "develop": {}
}


</details>

Does anyone know how I can fix this

Cocainism answered 18/6, 2019 at 9:53 Comment(0)
S
0

runpy is a module in Python 3's standard library. Maybe you should re-install your Python 3.

Shedevil answered 20/6, 2019 at 2:21 Comment(0)
S
0

I had something similar (hash mismatch) and upgrading pip helped: pip install -r tools/requirements.txt

Seating answered 21/7, 2021 at 0:13 Comment(0)
C
0

Check Pipenv version: ensure that you are using a recent version of Pipenv. You can upgrade Pipenv using the following command:

pip install --upgrade pipenv
Casteel answered 4/12, 2023 at 17:5 Comment(0)
W
0

I have encountered some situations where porting a Pipenv environment from another system (i.e. from a project working on a OS to another OS) fails because the hashes on Pipfile.lock are platform specific. In those cases, deleting the Pipfile.lock was the solution, as then pipenv is forced to search for the appropriate installation files for your system, instead of trying to reproduce exactly the previous installation.

Specially because the error messages show that Pipfile.lock hashes are being used in the installation attempts, the proposed solution should fit this case.

Werbel answered 15/2, 2024 at 8:48 Comment(0)
L
0

Not claiming this is a complete answer, but hopefully it will get you most of the way to a solution.

I started by trying to reproduce the error you received on my platform. I didn't have pipenv in my environment so I installed the latest version available for my OS: version 2023.12.1 Also, I'm currently running Python 3.12.3 and pip 24.0.

Next, I copied and pasted the contents of your Pipfile and Pipfile.lock files to make local versions in my current directory. The only changes I made to the files' content were to remove the initial "toml" and "json" strings that were the first lines of their respective files. (My pipenv version complained about these lines.) And I adjusted the value for the "python_version" key in each of these files to match my Python version:

Pipfile:

[requires]
python_version = "3.12"

Pipfile.lock:

"requires": {
    "python_version": "3.12"
},

After that, I ran the same command you did: pipenv install which succeeded, generating the following output:

Pipfile.lock (8d815b) out of date, updating to (cda8cc)...
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
✔ Success!
Locking [dev-packages] dependencies...
Updated Pipfile.lock (d9818c4e99a250fdb7ba436c01f26a64a5fa25b0adf0e01d37a89e59edcda8cc)!
Installing dependencies from Pipfile.lock (cda8cc)...
To activate this project's virtualenv, run pipenv shell.
Alternatively, run a command inside the virtualenv with pipenv run.

The pipenv generated virtual environment was activated successfully by running one of the recommended commands: pipenv shell

Verifying that pipenv runs successfully using your Pipfile and Pipfile.lock files--even in a different environment--suggests a couple of things. First, it validates your toml and json files and eliminates concerns about the package hashes. Second, it demonstrates that pipenv install can run successfully with your configs for some set of Python, pip, and pipenv versions. So one potential solution would be to upgrade your versions of Python, pip, and pipenv. As @SidM14 mentions in an earlier answer, pipenv can be upgraded using:

pip install --upgrade pipenv

And upgrading pip on Windows--as suggested in @Radzor's answer--can be accomplished as described here: How to Install PIP on Windows (site linked by @apoclyps in answer to a related question). From the question, the submitter is very familiar with installing Python :D, but for completeness, a previous SO question addresses this specifically: How do I upgrade the Python installation in Windows 10?. Performing these version upgrades could potentially solve the problem.

If you're locked in to using Python 3.7, however, or have other limits on your pip and pipenv versions, you could revisit the clean-install process you are using to get Python, pip, and pipenv. This approach has the advantage of directly addressing the proximate cause of the problem, as suggested in @"Frost Ming"'s answer: a missing runpy module.

The relevant line from the error message generated by running `pipenv install' is:

'Could not import runpy module', "ModuleNotFoundError: No module named 'runpy'"

And there's another SO question that appears to address this issue specifically--on a similar platform and using the same Python version as the submitter: pipenv cannot find module 'runpy' when installing dependancies

If updating Python, pip, and pipenv versions doesn't work and trying the suggested clean-install process fails as well, there's still a direction for future research / troubleshooting. Since there is a known good install on a non-Windows platform, focusing on finding a root cause specific to a Windows Python environment--or that is related to differences between Python on Windows and Python on other OS's--seems reasonable. (I don't think this matters, but for the record I'm running Ubuntu 24.04 lts)

Lustick answered 4/6, 2024 at 6:41 Comment(0)
R
0

Open a command prompt and run:

python -c "import runpy; print(runpy)"

it will show path if runpy is present. If not, your Python installation might be incomplete or corrupted.

Roaring answered 16/7, 2024 at 18:27 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.