-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Work around requirementslib AttributeError #334
Open
Thynix
wants to merge
2
commits into
clips:develop
Choose a base branch
from
Thynix:fix-attributeerror
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
See pypa/pipenv#5167 (comment) This could lead to failures like $ pipenv install Pipfile.lock (6c5d3c) out of date, updating to (dd7943)... Locking [packages] dependencies... ⠸ Resolving dependencies... Traceback (most recent call last): File "/usr/lib/python3/dist-packages/pipenv/resolver.py", line 845, in <module> main() File "/usr/lib/python3/dist-packages/pipenv/resolver.py", line 831, in main _main( File "/usr/lib/python3/dist-packages/pipenv/resolver.py", line 811, in _main resolve_packages( File "/usr/lib/python3/dist-packages/pipenv/resolver.py", line 759, in resolve_packages results, resolver = resolve( ^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/resolver.py", line 738, in resolve return resolve_deps( ^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/resolver.py", line 1100, in resolve_deps results, hashes, markers_lookup, resolver, skipped = actually_resolve_deps( ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/resolver.py", line 888, in actually_resolve_deps resolver = Resolver.create( ^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/resolver.py", line 458, in create constraints, skipped, index_lookup, markers_lookup = resolver.get_metadata( ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/resolver.py", line 246, in get_metadata constraint_update, lockfile_update = self.get_deps_from_req( ^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/resolver.py", line 325, in get_deps_from_req req_list, lockfile = get_vcs_deps(reqs=[req]) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/dependencies.py", line 125, in get_vcs_deps with temp_path(), locked_repository(requirement) as repo: File "/usr/lib/python3.11/contextlib.py", line 137, in __enter__ return next(self.gen) ^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/utils/dependencies.py", line 375, in locked_repository with requirement.req.locked_vcs_repo(src_dir=src_dir) as repo: File "/usr/lib/python3.11/contextlib.py", line 137, in __enter__ return next(self.gen) ^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/requirements.py", line 2203, in locked_vcs_repo self._parsed_line.vcsrepo = vcsrepo ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/requirements.py", line 903, in vcsrepo setupinfo = SetupInfo.create( ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 1564, in create created.get_initial_info() File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 1393, in get_initial_info parsed.update(self.parse_setup_py()) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 1118, in parse_setup_py parsed = ast_parse_setup_py(self.setup_py.as_posix()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 839, in ast_parse_setup_py return SetupReader.read_setup_py(Path(path), raising) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 180, in read_setup_py "install_requires": caller(cls._find_install_requires, setup_call, body), ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 172, in caller return func(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 335, in _find_install_requires return [el.s for el in value.elts] ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/pipenv/vendor/requirementslib/models/setup_info.py", line 335, in <listcomp> return [el.s for el in value.elts] ^^^^ AttributeError: 'IfExp' object has no attribute 's'
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
(This also fixes bumping
setup.py
version but not the module's__version__
, intended for squashing.)See pypa/pipenv#5167 (comment)
This could lead to failures like