pipenv
pipenv copied to clipboard
pipenv install fails if subdirectory cannot be traversed
Issue description
python -m pipenv install
will raise an Error while traversing directories if a subdirectory cannot be accessed. The install
process fails.
Expected result
python -m pipenv install
should catch access errors, print a warning (PermissionError: cannot access path '.\foo'
), and then continue processing.
Actual result
python -m pipenv install
fails, python process exits. User cannot proceed with project development.
Steps to replicate
- Run in a powershell instance as
Administrator
.
function RemoveNTFSPermissions($path, $object, $permission) {
$FileSystemRights = [System.Security.AccessControl.FileSystemRights]$permission
$InheritanceFlag = [System.Security.AccessControl.InheritanceFlags]"ContainerInherit, ObjectInherit"
$PropagationFlag = [System.Security.AccessControl.PropagationFlags]"None"
$AccessControlType =[System.Security.AccessControl.AccessControlType]::Allow
$Account = New-Object System.Security.Principal.NTAccount($object)
$FileSystemAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule($Account, $FileSystemRights, $InheritanceFlag, $PropagationFlag, $AccessControlType)
$DirectorySecurity = Get-ACL $path
$DirectorySecurity.RemoveAccessRuleAll($FileSystemAccessRule)
Set-ACL $path -AclObject $DirectorySecurity
}
function RemoveInheritance($path) {
$isProtected = $true
$preserveInheritance = $true
$DirectorySecurity = Get-ACL $path
$DirectorySecurity.SetAccessRuleProtection($isProtected, $preserveInheritance)
Set-ACL $path -AclObject $DirectorySecurity
}
(Snippet from SO)
- create the inaccessible subdirectory. Replace values of
$path1
and$user1
$path1 = "C:\User\user1\project1"
$user1 = "HOST\user1"
cd $path1
mkdir ".\test-noaccess"
RemoveInheritance ".\test-noaccess"
RemoveNTFSPermissions ".\test-noaccess" $user1 "Modify, ChangePermissions, ExecuteFile, ListDirectory, FullControl, Read, ReadAndExecute, ReadAttributes, Traverse, Write, WriteData, WriteExtendedAttributes"
- In a powershell instance as the typical user
user1
PS> python -m pipenv install
Installing dependencies from Pipfile.lock (57ec73)...
Traceback (most recent call last):
File "C:\python.org.3.9.6\lib\runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\python.org.3.9.6\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\__main__.py", line 5, in <module>
cli()
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 1128, in __call__
return self.main(*args, **kwargs)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 1053, in main
rv = self.invoke(ctx)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 1395, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\decorators.py", line 84, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\click\core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\cli\command.py", line 194, in install
do_install(
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\core.py", line 1987, in do_install
do_init(
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\core.py", line 1251, in do_init
do_install_dependencies(
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\core.py", line 786, in do_install_dependencies
deps_list = list(lockfile.get_requirements(dev=dev, only=dev_only))
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\lockfile.py", line 275, in get_requirements
yield Requirement.from_pipfile(k, v)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 2745, in from_pipfile
r = FileRequirement.from_pipfile(name, pipfile)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 1841, in from_pipfile
arg_dict["parsed_line"] = Line(line)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 171, in __init__
self.parse()
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 1304, in parse
self.parse_name()
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 1030, in parse_name
name = self._parse_name_from_path()
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\requirements.py", line 993, in _parse_name_from_path
metadata = get_metadata(self.path)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 781, in get_metadata
dist = get_distinfo_dist(path, pkg_name=pkg_name)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 749, in get_distinfo_dist
dist_dir = next(iter(find_distinfo(path, pkg_name=pkg_name)), None)
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 741, in find_distinfo
for dist_dir in dist_dirs:
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 731, in <genexpr>
dist_dirs = (
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 704, in iter_metadata
with contextlib.closing(ScandirCloser(p)) as path_iterator:
File "C:\Users\user1\.virtualenvs\project1-IrhwCFbf\lib\site-packages\pipenv\vendor\requirementslib\models\setup_info.py", line 664, in __init__
self.iterator = scandir(path)
PermissionError: [WinError 5] Access is denied: 'C:/Users/user1/project1\\test-noaccess'
Details
$ pipenv --support
Pipenv version: '2021.11.23'
Pipenv location: 'C:\\Users\\user1\\.virtualenvs\\project1-IrhwCFbf\\lib\\site-packages\\pipenv'
Python location: 'C:\\Users\\user1\\.virtualenvs\\project1-IrhwCFbf\\Scripts\\python.exe'
Python installations found:
-
3.9.6
:C:\python.org.3.9.6\python.exe
PEP 508 Information:
{'implementation_name': 'cpython',
'implementation_version': '3.9.6',
'os_name': 'nt',
'platform_machine': 'AMD64',
'platform_python_implementation': 'CPython',
'platform_release': '10',
'platform_system': 'Windows',
'python_full_version': '3.9.6',
'python_version': '3.9',
'sys_platform': 'win32'}
System environment variables:
-
PIPENV_ACTIVE
-
PIP_DISABLE_PIP_VERSION_CHECK
-
PIP_PYTHON_PATH
Pipenv–specific environment variables:
-
PIPENV_ACTIVE
:1
Contents of Pipfile
(C:\\Users\\user1\\project1\\Pipfile
):
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true
[dev-packages]
# $ pipenv install --dev
attrs = "*"
codecov = "*"
coveralls = "*"
mypy = "*"
pipenv = "*"
pytest = "*"
pytest-cov = "*"
pytest-dependency = "*"
pyyaml = ">=4.2b1"
setuptools = "*"
wheel = "*"
yamllint = "*"
[win-packages]
# $ pipenv install --win
py2exe = "*"
[packages]
# $ pipenv install
attrs = "==21.4.0"
discogs-client = "2.3.0"
musicbrainzngs = "==0.7.1"
mutagen = "==1.45.1"
Pillow = "==8.4.0"
tabulate = "==0.8.9"
zipp = {editable = true, path = "."}
[pipenv]
allow_prereleases = false
Contents of Pipfile.lock
('C:\Users\user1\Project1\Pipfile.lock'):
{
"_meta": {
"hash": {
"sha256": "321939c61bf859d6c1e8fd5f663bd48bf67d68ded05560f7d8975cb06f57ec73"
},
"pipfile-spec": 6,
"requires": {},
"sources": [
{
"name": "pypi",
"url": "https://pypi.org/simple",
"verify_ssl": true
}
]
},
"default": {
"attrs": {
"hashes": [
"sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4",
"sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"
],
"index": "pypi",
"version": "==21.4.0"
},
"certifi": {
"hashes": [
"sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872",
"sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"
],
"version": "==2021.10.8"
},
"charset-normalizer": {
"hashes": [
"sha256:1eecaa09422db5be9e29d7fc65664e6c33bd06f9ced7838578ba40d58bdf3721",
"sha256:b0b883e8e874edfdece9c28f314e3dd5badf067342e42fb162203335ae61aa2c"
],
"markers": "python_version >= '3'",
"version": "==2.0.9"
},
"discogs-client": {
"hashes": [
"sha256:777094c0be682048a31d2c463d37e1c5725f3c3177d4f3eb05394d9f34931005",
"sha256:7e91f62a1bfee802e155d1f7c543e47fb5ef158d099e90e6b28f5e44a1f41d94",
"sha256:cc979fcbb5283f74d388c7111c8ed6bef920b01614a014d6b1c5d6fbb554bfc3"
],
"index": "pypi",
"version": "==2.3.0"
},
"idna": {
"hashes": [
"sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff",
"sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"
],
"markers": "python_version >= '3'",
"version": "==3.3"
},
"musicbrainzngs": {
"hashes": [
"sha256:ab1c0100fd0b305852e65f2ed4113c6de12e68afd55186987b8ed97e0f98e627",
"sha256:e841a8f975104c0a72290b09f59326050194081a5ae62ee512f41915090e1a10"
],
"index": "pypi",
"version": "==0.7.1"
},
"mutagen": {
"hashes": [
"sha256:6397602efb3c2d7baebd2166ed85731ae1c1d475abca22090b7141ff5034b3e1",
"sha256:9c9f243fcec7f410f138cb12c21c84c64fde4195481a30c9bfb05b5f003adfed"
],
"index": "pypi",
"version": "==1.45.1"
},
"oauthlib": {
"hashes": [
"sha256:42bf6354c2ed8c6acb54d971fce6f88193d97297e18602a3a886603f9d7730cc",
"sha256:8f0215fcc533dd8dd1bee6f4c412d4f0cd7297307d43ac61666389e3bc3198a3"
],
"markers": "python_version >= '3.6'",
"version": "==3.1.1"
},
"pillow": {
"hashes": [
"sha256:066f3999cb3b070a95c3652712cffa1a748cd02d60ad7b4e485c3748a04d9d76",
"sha256:0a0956fdc5defc34462bb1c765ee88d933239f9a94bc37d132004775241a7585",
"sha256:0b052a619a8bfcf26bd8b3f48f45283f9e977890263e4571f2393ed8898d331b",
"sha256:1394a6ad5abc838c5cd8a92c5a07535648cdf6d09e8e2d6df916dfa9ea86ead8",
"sha256:1bc723b434fbc4ab50bb68e11e93ce5fb69866ad621e3c2c9bdb0cd70e345f55",
"sha256:244cf3b97802c34c41905d22810846802a3329ddcb93ccc432870243211c79fc",
"sha256:25a49dc2e2f74e65efaa32b153527fc5ac98508d502fa46e74fa4fd678ed6645",
"sha256:2e4440b8f00f504ee4b53fe30f4e381aae30b0568193be305256b1462216feff",
"sha256:3862b7256046fcd950618ed22d1d60b842e3a40a48236a5498746f21189afbbc",
"sha256:3eb1ce5f65908556c2d8685a8f0a6e989d887ec4057326f6c22b24e8a172c66b",
"sha256:3f97cfb1e5a392d75dd8b9fd274d205404729923840ca94ca45a0af57e13dbe6",
"sha256:493cb4e415f44cd601fcec11c99836f707bb714ab03f5ed46ac25713baf0ff20",
"sha256:4acc0985ddf39d1bc969a9220b51d94ed51695d455c228d8ac29fcdb25810e6e",
"sha256:5503c86916d27c2e101b7f71c2ae2cddba01a2cf55b8395b0255fd33fa4d1f1a",
"sha256:5b7bb9de00197fb4261825c15551adf7605cf14a80badf1761d61e59da347779",
"sha256:5e9ac5f66616b87d4da618a20ab0a38324dbe88d8a39b55be8964eb520021e02",
"sha256:620582db2a85b2df5f8a82ddeb52116560d7e5e6b055095f04ad828d1b0baa39",
"sha256:62cc1afda735a8d109007164714e73771b499768b9bb5afcbbee9d0ff374b43f",
"sha256:70ad9e5c6cb9b8487280a02c0ad8a51581dcbbe8484ce058477692a27c151c0a",
"sha256:72b9e656e340447f827885b8d7a15fc8c4e68d410dc2297ef6787eec0f0ea409",
"sha256:72cbcfd54df6caf85cc35264c77ede902452d6df41166010262374155947460c",
"sha256:792e5c12376594bfcb986ebf3855aa4b7c225754e9a9521298e460e92fb4a488",
"sha256:7b7017b61bbcdd7f6363aeceb881e23c46583739cb69a3ab39cb384f6ec82e5b",
"sha256:81f8d5c81e483a9442d72d182e1fb6dcb9723f289a57e8030811bac9ea3fef8d",
"sha256:82aafa8d5eb68c8463b6e9baeb4f19043bb31fefc03eb7b216b51e6a9981ae09",
"sha256:84c471a734240653a0ec91dec0996696eea227eafe72a33bd06c92697728046b",
"sha256:8c803ac3c28bbc53763e6825746f05cc407b20e4a69d0122e526a582e3b5e153",
"sha256:93ce9e955cc95959df98505e4608ad98281fff037350d8c2671c9aa86bcf10a9",
"sha256:9a3e5ddc44c14042f0844b8cf7d2cd455f6cc80fd7f5eefbe657292cf601d9ad",
"sha256:a4901622493f88b1a29bd30ec1a2f683782e57c3c16a2dbc7f2595ba01f639df",
"sha256:a5a4532a12314149d8b4e4ad8ff09dde7427731fcfa5917ff16d0291f13609df",
"sha256:b8831cb7332eda5dc89b21a7bce7ef6ad305548820595033a4b03cf3091235ed",
"sha256:b8e2f83c56e141920c39464b852de3719dfbfb6e3c99a2d8da0edf4fb33176ed",
"sha256:c70e94281588ef053ae8998039610dbd71bc509e4acbc77ab59d7d2937b10698",
"sha256:c8a17b5d948f4ceeceb66384727dde11b240736fddeda54ca740b9b8b1556b29",
"sha256:d82cdb63100ef5eedb8391732375e6d05993b765f72cb34311fab92103314649",
"sha256:d89363f02658e253dbd171f7c3716a5d340a24ee82d38aab9183f7fdf0cdca49",
"sha256:d99ec152570e4196772e7a8e4ba5320d2d27bf22fdf11743dd882936ed64305b",
"sha256:ddc4d832a0f0b4c52fff973a0d44b6c99839a9d016fe4e6a1cb8f3eea96479c2",
"sha256:e3dacecfbeec9a33e932f00c6cd7996e62f53ad46fbe677577394aaa90ee419a",
"sha256:eb9fc393f3c61f9054e1ed26e6fe912c7321af2f41ff49d3f83d05bacf22cc78"
],
"index": "pypi",
"version": "==8.4.0"
},
"pipenv": {
"editable": true,
"path": "."
},
"requests": {
"hashes": [
"sha256:8e5643905bf20a308e25e4c1dd379117c09000bf8a82ebccc462cfb1b34a16b5",
"sha256:f71a09d7feba4a6b64ffd8e9d9bc60f9bf7d7e19fd0e04362acb1cfc2e3d98df"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'",
"version": "==2.27.0"
},
"six": {
"hashes": [
"sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
"sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
"version": "==1.16.0"
},
"tabulate": {
"hashes": [
"sha256:d7c013fe7abbc5e491394e10fa845f8f32fe54f8dc60c6622c6cf482d25d47e4",
"sha256:eb1d13f25760052e8931f2ef80aaf6045a6cceb47514db8beab24cded16f13a7"
],
"index": "pypi",
"version": "==0.8.9"
},
"urllib3": {
"hashes": [
"sha256:4987c65554f7a2dbf30c18fd48778ef124af6fab771a377103da0585e2336ece",
"sha256:c4fdf4019605b6e5423637e01bc9fe4daef873709a7973e195ceba0a62bbc844"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' and python_version < '4'",
"version": "==1.26.7"
},
"zipp": {
"editable": true,
"path": "."
}
},
"develop": {
"attrs": {
"hashes": [
"sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4",
"sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd"
],
"index": "pypi",
"version": "==21.4.0"
},
"certifi": {
"hashes": [
"sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872",
"sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569"
],
"version": "==2021.10.8"
},
"charset-normalizer": {
"hashes": [
"sha256:1eecaa09422db5be9e29d7fc65664e6c33bd06f9ced7838578ba40d58bdf3721",
"sha256:b0b883e8e874edfdece9c28f314e3dd5badf067342e42fb162203335ae61aa2c"
],
"markers": "python_version >= '3'",
"version": "==2.0.9"
},
"codecov": {
"hashes": [
"sha256:585dc217dc3d8185198ceb402f85d5cb5dbfa0c5f350a5abcdf9e347776a5b47",
"sha256:782a8e5352f22593cbc5427a35320b99490eb24d9dcfa2155fd99d2b75cfb635",
"sha256:a0da46bb5025426da895af90938def8ee12d37fcbcbbbc15b6dc64cf7ebc51c1"
],
"index": "pypi",
"version": "==2.1.12"
},
"coverage": {
"hashes": [
"sha256:01774a2c2c729619760320270e42cd9e797427ecfddd32c2a7b639cdc481f3c0",
"sha256:03b20e52b7d31be571c9c06b74746746d4eb82fc260e594dc662ed48145e9efd",
"sha256:0a7726f74ff63f41e95ed3a89fef002916c828bb5fcae83b505b49d81a066884",
"sha256:1219d760ccfafc03c0822ae2e06e3b1248a8e6d1a70928966bafc6838d3c9e48",
"sha256:13362889b2d46e8d9f97c421539c97c963e34031ab0cb89e8ca83a10cc71ac76",
"sha256:174cf9b4bef0db2e8244f82059a5a72bd47e1d40e71c68ab055425172b16b7d0",
"sha256:17e6c11038d4ed6e8af1407d9e89a2904d573be29d51515f14262d7f10ef0a64",
"sha256:215f8afcc02a24c2d9a10d3790b21054b58d71f4b3c6f055d4bb1b15cecce685",
"sha256:22e60a3ca5acba37d1d4a2ee66e051f5b0e1b9ac950b5b0cf4aa5366eda41d47",
"sha256:2641f803ee9f95b1f387f3e8f3bf28d83d9b69a39e9911e5bfee832bea75240d",
"sha256:276651978c94a8c5672ea60a2656e95a3cce2a3f31e9fb2d5ebd4c215d095840",
"sha256:3f7c17209eef285c86f819ff04a6d4cbee9b33ef05cbcaae4c0b4e8e06b3ec8f",
"sha256:3feac4084291642165c3a0d9eaebedf19ffa505016c4d3db15bfe235718d4971",
"sha256:49dbff64961bc9bdd2289a2bda6a3a5a331964ba5497f694e2cbd540d656dc1c",
"sha256:4e547122ca2d244f7c090fe3f4b5a5861255ff66b7ab6d98f44a0222aaf8671a",
"sha256:5829192582c0ec8ca4a2532407bc14c2f338d9878a10442f5d03804a95fac9de",
"sha256:5d6b09c972ce9200264c35a1d53d43ca55ef61836d9ec60f0d44273a31aa9f17",
"sha256:600617008aa82032ddeace2535626d1bc212dfff32b43989539deda63b3f36e4",
"sha256:619346d57c7126ae49ac95b11b0dc8e36c1dd49d148477461bb66c8cf13bb521",
"sha256:63c424e6f5b4ab1cf1e23a43b12f542b0ec2e54f99ec9f11b75382152981df57",
"sha256:6dbc1536e105adda7a6312c778f15aaabe583b0e9a0b0a324990334fd458c94b",
"sha256:6e1394d24d5938e561fbeaa0cd3d356207579c28bd1792f25a068743f2d5b282",
"sha256:86f2e78b1eff847609b1ca8050c9e1fa3bd44ce755b2ec30e70f2d3ba3844644",
"sha256:8bdfe9ff3a4ea37d17f172ac0dff1e1c383aec17a636b9b35906babc9f0f5475",
"sha256:8e2c35a4c1f269704e90888e56f794e2d9c0262fb0c1b1c8c4ee44d9b9e77b5d",
"sha256:92b8c845527eae547a2a6617d336adc56394050c3ed8a6918683646328fbb6da",
"sha256:9365ed5cce5d0cf2c10afc6add145c5037d3148585b8ae0e77cc1efdd6aa2953",
"sha256:9a29311bd6429be317c1f3fe4bc06c4c5ee45e2fa61b2a19d4d1d6111cb94af2",
"sha256:9a2b5b52be0a8626fcbffd7e689781bf8c2ac01613e77feda93d96184949a98e",
"sha256:a4bdeb0a52d1d04123b41d90a4390b096f3ef38eee35e11f0b22c2d031222c6c",
"sha256:a9c8c4283e17690ff1a7427123ffb428ad6a52ed720d550e299e8291e33184dc",
"sha256:b637c57fdb8be84e91fac60d9325a66a5981f8086c954ea2772efe28425eaf64",
"sha256:bf154ba7ee2fd613eb541c2bc03d3d9ac667080a737449d1a3fb342740eb1a74",
"sha256:c254b03032d5a06de049ce8bca8338a5185f07fb76600afff3c161e053d88617",
"sha256:c332d8f8d448ded473b97fefe4a0983265af21917d8b0cdcb8bb06b2afe632c3",
"sha256:c7912d1526299cb04c88288e148c6c87c0df600eca76efd99d84396cfe00ef1d",
"sha256:cfd9386c1d6f13b37e05a91a8583e802f8059bebfccde61a418c5808dea6bbfa",
"sha256:d5d2033d5db1d58ae2d62f095e1aefb6988af65b4b12cb8987af409587cc0739",
"sha256:dca38a21e4423f3edb821292e97cec7ad38086f84313462098568baedf4331f8",
"sha256:e2cad8093172b7d1595b4ad66f24270808658e11acf43a8f95b41276162eb5b8",
"sha256:e3db840a4dee542e37e09f30859f1612da90e1c5239a6a2498c473183a50e781",
"sha256:edcada2e24ed68f019175c2b2af2a8b481d3d084798b8c20d15d34f5c733fa58",
"sha256:f467bbb837691ab5a8ca359199d3429a11a01e6dfb3d9dcc676dc035ca93c0a9",
"sha256:f506af4f27def639ba45789fa6fde45f9a217da0be05f8910458e4557eed020c",
"sha256:f614fc9956d76d8a88a88bb41ddc12709caa755666f580af3a688899721efecd",
"sha256:f9afb5b746781fc2abce26193d1c817b7eb0e11459510fba65d2bd77fe161d9e",
"sha256:fb8b8ee99b3fffe4fd86f4c81b35a6bf7e4462cba019997af2fe679365db0c49"
],
"markers": "python_version >= '3.6'",
"version": "==6.2"
},
"coveralls": {
"hashes": [
"sha256:b32a8bb5d2df585207c119d6c01567b81fba690c9c10a753bfe27a335bfc43ea",
"sha256:f42015f31d386b351d4226389b387ae173207058832fbf5c8ec4b40e27b16026"
],
"index": "pypi",
"version": "==3.3.1"
},
"distlib": {
"hashes": [
"sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b",
"sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"
],
"version": "==0.3.4"
},
"docopt": {
"hashes": [
"sha256:49b3a825280bd66b3aa83585ef59c4a8c82f2c8a522dbe754a8bc8d08c85c491"
],
"version": "==0.6.2"
},
"filelock": {
"hashes": [
"sha256:38b4f4c989f9d06d44524df1b24bd19e167d851f19b50bf3e3559952dddc5b80",
"sha256:cf0fc6a2f8d26bd900f19bf33915ca70ba4dd8c56903eeb14e1e7a2fd7590146"
],
"markers": "python_version >= '3.7'",
"version": "==3.4.2"
},
"idna": {
"hashes": [
"sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff",
"sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"
],
"markers": "python_version >= '3'",
"version": "==3.3"
},
"iniconfig": {
"hashes": [
"sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3",
"sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"
],
"version": "==1.1.1"
},
"mypy": {
"hashes": [
"sha256:0feb82e9fa849affca7edd24713dbe809dce780ced9f3feca5ed3d80e40b777f",
"sha256:1d2296f35aae9802eeb1327058b550371ee382d71374b3e7d2804035ef0b830b",
"sha256:1e689e92cdebd87607a041585f1dc7339aa2e8a9f9bad9ba7e6ece619431b20c",
"sha256:1ea7199780c1d7940b82dbc0a4e37722b4e3851264dbba81e01abecc9052d8a7",
"sha256:221cc94dc6a801ccc2be7c0c9fd791c5e08d1fa2c5e1c12dec4eab15b2469871",
"sha256:2e9c5409e9cb81049bb03fa1009b573dea87976713e3898561567a86c4eaee01",
"sha256:45a4dc21c789cfd09b8ccafe114d6de66f0b341ad761338de717192f19397a8c",
"sha256:51426262ae4714cc7dd5439814676e0992b55bcc0f6514eccb4cf8e0678962c2",
"sha256:554873e45c1ca20f31ddf873deb67fa5d2e87b76b97db50669f0468ccded8fae",
"sha256:5feb56f8bb280468fe5fc8e6f56f48f99aa0df9eed3c507a11505ee4657b5380",
"sha256:601f46593f627f8a9b944f74fd387c9b5f4266b39abad77471947069c2fc7651",
"sha256:70b197dd8c78fc5d2daf84bd093e8466a2b2e007eedaa85e792e513a820adbf7",
"sha256:959319b9a3cafc33a8185f440a433ba520239c72e733bf91f9efd67b0a8e9b30",
"sha256:a9d8dffefba634b27d650e0de2564379a1a367e2e08d6617d8f89261a3bf63b2",
"sha256:b419e9721260161e70d054a15abbd50603c16f159860cfd0daeab647d828fc29",
"sha256:bc1a0607ea03c30225347334af66b0af12eefba018a89a88c209e02b7065ea95",
"sha256:bf4a44e03040206f7c058d1f5ba02ef2d1820720c88bc4285c7d9a4269f54173",
"sha256:db3a87376a1380f396d465bed462e76ea89f838f4c5e967d68ff6ee34b785c31",
"sha256:ed4e0ea066bb12f56b2812a15ff223c57c0a44eca817ceb96b214bb055c7051f",
"sha256:f9f665d69034b1fcfdbcd4197480d26298bbfb5d2dfe206245b6498addb34999"
],
"index": "pypi",
"version": "==0.930"
},
"mypy-extensions": {
"hashes": [
"sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d",
"sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8"
],
"version": "==0.4.3"
},
"packaging": {
"hashes": [
"sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb",
"sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"
],
"markers": "python_version >= '3.6'",
"version": "==21.3"
},
"pathspec": {
"hashes": [
"sha256:7d15c4ddb0b5c802d161efc417ec1a2558ea2653c2e8ad9c19098201dc1c993a",
"sha256:e564499435a2673d586f6b2130bb5b95f04a3ba06f81b8f895b651a3c76aabb1"
],
"version": "==0.9.0"
},
"pip": {
"hashes": [
"sha256:deaf32dcd9ab821e359cd8330786bcd077604b5c5730c0b096eda46f95c24a2d",
"sha256:fd11ba3d0fdb4c07fbc5ecbba0b1b719809420f25038f8ee3cd913d3faa3033a"
],
"markers": "python_version >= '3.6'",
"version": "==21.3.1"
},
"pipenv": {
"editable": true,
"path": "."
},
"platformdirs": {
"hashes": [
"sha256:1d7385c7db91728b83efd0ca99a5afb296cab9d0ed8313a45ed8ba17967ecfca",
"sha256:440633ddfebcc36264232365d7840a970e75e1018d15b4327d11f91909045fda"
],
"markers": "python_version >= '3.7'",
"version": "==2.4.1"
},
"pluggy": {
"hashes": [
"sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159",
"sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"
],
"markers": "python_version >= '3.6'",
"version": "==1.0.0"
},
"py": {
"hashes": [
"sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719",
"sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'",
"version": "==1.11.0"
},
"pyparsing": {
"hashes": [
"sha256:04ff808a5b90911829c55c4e26f75fa5ca8a2f5f36aa3a51f68e27033341d3e4",
"sha256:d9bdec0013ef1eb5a84ab39a3b3868911598afa494f5faa038647101504e2b81"
],
"markers": "python_version >= '3.6'",
"version": "==3.0.6"
},
"pytest": {
"hashes": [
"sha256:8fc363e0b7407a9397e660ef81e1634e4504faaeb6ad1d2416da4c38d29a0f45",
"sha256:e1af71303d633af3376130b388e028342815cff74d2f3be4aeb22f3fd94325e6"
],
"index": "pypi",
"version": "==7.0.0rc1"
},
"pytest-cov": {
"hashes": [
"sha256:578d5d15ac4a25e5f961c938b85a05b09fdaae9deef3bb6de9a6e766622ca7a6",
"sha256:e7f0f5b1617d2210a2cabc266dfe2f4c75a8d32fb89eafb7ad9d06f6d076d470"
],
"index": "pypi",
"version": "==3.0.0"
},
"pytest-dependency": {
"hashes": [
"sha256:c2a892906192663f85030a6ab91304e508e546cddfe557d692d61ec57a1d946b"
],
"index": "pypi",
"version": "==0.5.1"
},
"pyyaml": {
"hashes": [
"sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293",
"sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b",
"sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57",
"sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b",
"sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4",
"sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07",
"sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba",
"sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9",
"sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287",
"sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513",
"sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0",
"sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0",
"sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92",
"sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f",
"sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2",
"sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc",
"sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c",
"sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86",
"sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4",
"sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c",
"sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34",
"sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b",
"sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c",
"sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb",
"sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737",
"sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3",
"sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d",
"sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53",
"sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78",
"sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803",
"sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a",
"sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174",
"sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"
],
"index": "pypi",
"version": "==6.0"
},
"requests": {
"hashes": [
"sha256:8e5643905bf20a308e25e4c1dd379117c09000bf8a82ebccc462cfb1b34a16b5",
"sha256:f71a09d7feba4a6b64ffd8e9d9bc60f9bf7d7e19fd0e04362acb1cfc2e3d98df"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'",
"version": "==2.27.0"
},
"setuptools": {
"hashes": [
"sha256:5c89b1a14a67ac5f0956f1cb0aeb7d1d3f4c8ba4e4e1ab7bf1af4933f9a2f0fe",
"sha256:675fcebecb43c32eb930481abf907619137547f4336206e4d673180242e1a278"
],
"index": "pypi",
"version": "==60.2.0"
},
"six": {
"hashes": [
"sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
"sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
"version": "==1.16.0"
},
"tomli": {
"hashes": [
"sha256:b5bde28da1fed24b9bd1d4d2b8cba62300bfb4ec9a6187a957e8ddb9434c5224",
"sha256:c292c34f58502a1eb2bbb9f5bbc9a5ebc37bee10ffb8c2d6bbdfa8eb13cc14e1"
],
"markers": "python_version >= '3.7'",
"version": "==2.0.0"
},
"typing-extensions": {
"hashes": [
"sha256:4ca091dea149f945ec56afb48dae714f21e8692ef22a395223bcd328961b6a0e",
"sha256:7f001e5ac290a0c0401508864c7ec868be4e701886d5b573a9528ed3973d9d3b"
],
"markers": "python_version >= '3.6'",
"version": "==4.0.1"
},
"urllib3": {
"hashes": [
"sha256:4987c65554f7a2dbf30c18fd48778ef124af6fab771a377103da0585e2336ece",
"sha256:c4fdf4019605b6e5423637e01bc9fe4daef873709a7973e195ceba0a62bbc844"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' and python_version < '4'",
"version": "==1.26.7"
},
"virtualenv": {
"hashes": [
"sha256:339f16c4a86b44240ba7223d0f93a7887c3ca04b5f9c8129da7958447d079b09",
"sha256:d8458cf8d59d0ea495ad9b34c2599487f8a7772d796f9910858376d1600dd2dd"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'",
"version": "==20.13.0"
},
"virtualenv-clone": {
"hashes": [
"sha256:418ee935c36152f8f153c79824bb93eaf6f0f7984bae31d3f48f350b9183501a",
"sha256:44d5263bceed0bac3e1424d64f798095233b64def1c5689afa43dc3223caf5b0"
],
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
"version": "==0.5.7"
},
"wheel": {
"hashes": [
"sha256:4bdcd7d840138086126cd09254dc6195fb4fc6f01c050a1d7236f2630db1d22a",
"sha256:e9a504e793efbca1b8e0e9cb979a249cf4a0a7b5b8c9e8b65a5e39d49529c1c4"
],
"index": "pypi",
"version": "==0.37.1"
},
"yamllint": {
"hashes": [
"sha256:3934dcde484374596d6b52d8db412929a169f6d9e52e20f9ade5bf3523d9b96e"
],
"index": "pypi",
"version": "==1.26.3"
}
}
}
Just noting that while this issue report provides a potential way to reproduce the issue, it does also sound very similar to: https://github.com/pypa/pipenv/issues/4898
@jtmoon79 I am not setup well to test your example presently (or am afraid to try it) but could you re-check this behavior with the current master branch and see if its the same (there have been a couple windows fixes recently). Also if that doesn't work still can you triage it with this branch: vendor-pip-22.0.3-followup-changes
Doing so will help determine if this issue has a resolution already or require additional work.
@matteius I was unable to reproduce this Issue #4906 due to another problem running pipenv
from an in-development version.
I was blocked by a FileNotFoundError
PS> python.exe -m pipenv
...
File "C:\Users\user1\Projects\test2\.venv396\lib\site-packages\pipenv-2022.1.9.dev0-py3.9.egg\pipenv\vendor\orderedmultidict\__init__.py", line 19, in <module>
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\user1\\Projects\\test2\\.venv396\\lib\\site-packages\\pipenv-2022.1.9.dev0-py3.9.egg\\pipenv\\vendor\\orderedmultidict\\__version__.py'
I tried several permutations of python interpreter versions, virtualenvs, and the pipenv branch main
and branch vendor-pip-22.0.3-followup-changes
.
For review, I installed the in-development pipenv
by commands (using commands for branch vendor-pip-22.0.3-followup-changes
and a freshly created Python 3.9.6 virtualenv):
PS> Invoke-WebRequest "https://github.com/pypa/pipenv/archive/refs/heads/vendor-pip-22.0.3-followup-changes.zip" -out vendor-pip-22.0.3-followup-changes.zip
PS> Expand-Archive .\vendor-pip-22.0.3-followup-changes.zip
PS> cd .\vendor-pip-22.0.3-followup-changes\pipenv-vendor-pip-22.0.3-followup-changes\
PS> python.exe .\setup.py install
PS> python.exe -m pip list -vvv
...
pipenv 2022.1.9.dev0 c:\users\user1\projects\test2\.venv396\lib\site-packages\pipenv-2022.1.9.dev0-py3.9.egg
PS> cd ..
PS> mkdir a
PS> cd a
PS> python.exe -m pipenv
...
FileNotFoundError: ...
I did not find an Issue with this failure. I'll give this another try some other time.
@jtmoon79 I will investigate the setup.py install command, it was not working for me either--instead I'ev had to do python setup.py develop --user
which install it as a user package as an editable egg install. So if you modify files of the installed location, it will be picked up immediately.
However, I found something that is worth investigating with respect to current environment variables. Try setting PIPENV_MAX_DEPTH
environment variable to be 1
the help text here is Maximum number of directories to recursively search for a Pipfile.
. There is also a variable PIPENV_PIPFILE
that you can set to be the exact path to your Pipfile.
I would like to hear more of your experience with this as I am starting to get more familiar with the codebase.
This Issue #4906 did not occur in branch vendor-pip-22.0.3-followup-changes
:-)
This Issue can be Closed.
Using command setup.py develop --user
instead of setup.py install
bypassed the FileNotFound
problem mentioned above.
review of reproduction steps:
Invoke-WebRequest "https://github.com/pypa/pipenv/archive/refs/heads/vendor-pip-22.0.3-followup-changes.zip" -out vendor-pip-22.0.3-followup-changes.zip
Expand-Archive .\vendor-pip-22.0.3-followup-changes.zip
cd .\vendor-pip-22.0.3-followup-changes\pipenv-vendor-pip-22.0.3-followup-changes\
python.exe .\setup.py develop --user
cd ..
mkdir a
cd a
function RemoveNTFSPermissions($path, $object, $permission) {
$FileSystemRights = [System.Security.AccessControl.FileSystemRights]$permission
$InheritanceFlag = [System.Security.AccessControl.InheritanceFlags]"ContainerInherit, ObjectInherit"
$PropagationFlag = [System.Security.AccessControl.PropagationFlags]"None"
$AccessControlType =[System.Security.AccessControl.AccessControlType]::Allow
$Account = New-Object System.Security.Principal.NTAccount($object)
$FileSystemAccessRule = New-Object System.Security.AccessControl.FileSystemAccessRule($Account, $FileSystemRights, $InheritanceFlag, $PropagationFlag, $AccessControlType)
$DirectorySecurity = Get-ACL $path
$DirectorySecurity.RemoveAccessRuleAll($FileSystemAccessRule)
Set-ACL $path -AclObject $DirectorySecurity
}
function RemoveInheritance($path) {
$isProtected = $true
$preserveInheritance = $true
$DirectorySecurity = Get-ACL $path
$DirectorySecurity.SetAccessRuleProtection($isProtected, $preserveInheritance)
Set-ACL $path -AclObject $DirectorySecurity
}
mkdir ".\test-noaccess"
RemoveInheritance ".\test-noaccess"
RemoveNTFSPermissions ".\test-noaccess" "HOST\user1" "Modify, ChangePermissions, ExecuteFile, ListDirectory, FullControl, Read, ReadAndExecute, ReadAttributes, Traverse, Write, WriteData, WriteExtendedAttributes"
python.exe -m pipenv install
Awesome, I am glad to hear @jtmoon79 -- we can leave this open until that branch makes it to an official release. We are waiting on a couple upstream PRs for that to happen, but with a little luck could happen in April. There is likely to be another release between now and then as well that may not include this change yet.
I believe this is resolvable now -- but let me know if its still an issue on pipenv==2022.8.19
I believe this is resolvable now -- but let me know if its still an issue on
pipenv==2022.8.19
I was unable to reproduce the issue using pipenv==2022.8.19
using Python 3.9.6 on Windows. 🙂
However, I was unable to reproduce the issue using pipenv==2021.11.23
. 😕
I spent about an hour attempting to reproduce the original issue with the reported version 2021.11.23
following the instructions I provided. But I could not. So I could not certainly verify this fix.
FWIW
It's possible this was fixed by the newer versions of setuptools.