Skip to content
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

Poetry cannot resolve dependency from Qiskit Aer 0.6.0 #2807

Closed
3 tasks done
ikkoham opened this issue Aug 14, 2020 · 3 comments · Fixed by #2810
Closed
3 tasks done

Poetry cannot resolve dependency from Qiskit Aer 0.6.0 #2807

ikkoham opened this issue Aug 14, 2020 · 3 comments · Fixed by #2810
Labels
area/docs/faq Frequently duplicated/potential addition to FAQ kind/bug Something isn't working as expected

Comments

@ikkoham
Copy link

ikkoham commented Aug 14, 2020

  • I am on the latest Poetry version.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option).
  • OS version and name: macOS 10.15.6
  • Poetry version: 1.0.10 and prerelease

How to reproduce?

poetry add qiskit-aer==0.6.0 to the blank env.

Issue

poetry add qiskit-aer==0.5.2 can resolve the dependency and install required packages.
However, from qiskit-aer==0.6.0, the dependency cannot be resolved, so poetry installs only qiskit-aer.

Related issue: Qiskit/qiskit-aer#880

@ikkoham ikkoham added kind/bug Something isn't working as expected status/triage This issue needs to be triaged labels Aug 14, 2020
@ikkoham ikkoham changed the title Poetry cannot resolve dependency from Aer 0.6.0 Poetry cannot resolve dependency from Qiskit Aer 0.6.0 Aug 14, 2020
@ikkoham
Copy link
Author

ikkoham commented Aug 14, 2020

@abn
Copy link
Member

abn commented Aug 14, 2020

When poetry inspects this package the sdist tarball gets downloaded. This is unpacked and inspected. The PKG-INFO contains the following.

Metadata-Version: 2.1
Name: qiskit-aer
Version: 0.6.1
Summary: Qiskit Aer - High performance simulators for Qiskit
Home-page: https://github.com/Qiskit/qiskit-aer
Author: AER Development Team
Author-email: qiskit@us.ibm.com
License: Apache 2.0
Description: # Qiskit Aer
<-- SNIPPED -->
Keywords: qiskit aer simulator quantum addon backend
Platform: UNKNOWN
Classifier: Environment :: Console
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: Microsoft :: Windows
Classifier: Operating System :: MacOS
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: C++
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Topic :: Scientific/Engineering
Description-Content-Type: text/markdown

Note that this does not contain any requirement specifications (Requires-Dist: ). This causes poetry to fallback to parsing the setup.py. In qiskit-aer-0.5.2, this was easily parsed without error. However, qiskit-aer-0.6.2 contains the following that wil lcause the AST parser used to fail causing no dependencies to be detected.

PACKAGE_NAME = os.getenv('QISKIT_AER_PACKAGE_NAME', 'qiskit-aer')
...
setup(
    name=PACKAGE_NAME,
    ...
)

@abn abn added the area/docs/faq Frequently duplicated/potential addition to FAQ label Aug 14, 2020
abn added a commit to abn/poetry that referenced this issue Aug 14, 2020
This change ensures that PEP 517 fallback builds are enabled by default
for when metadata inspection and setup.{py,cfg} parsing fails. This is
required in order to ensure that package requirements are correctly
identified for packages beyond first level dependencies.

Resolves: python-poetry#2807
abn added a commit to abn/poetry that referenced this issue Aug 14, 2020
This change ensures that PEP 517 fallback builds are enabled by default
for when metadata inspection and setup.{py,cfg} parsing fails. This is
required in order to ensure that package requirements are correctly
identified for packages beyond first level dependencies.

Resolves: python-poetry#2807
abn added a commit to abn/poetry that referenced this issue Aug 14, 2020
This change ensures that PEP 517 fallback builds are enabled by default
for when metadata inspection and setup.{py,cfg} parsing fails. This is
required in order to ensure that package requirements are correctly
identified for packages beyond first level dependencies.

Resolves: python-poetry#2807
@abn abn closed this as completed in #2810 Aug 27, 2020
abn added a commit that referenced this issue Aug 27, 2020
This change ensures that PEP 517 fallback builds are enabled by default
for when metadata inspection and setup.{py,cfg} parsing fails. This is
required in order to ensure that package requirements are correctly
identified for packages beyond first level dependencies.

Resolves: #2807
@abn abn removed the status/triage This issue needs to be triaged label Sep 25, 2020
Copy link

github-actions bot commented Mar 3, 2024

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/docs/faq Frequently duplicated/potential addition to FAQ kind/bug Something isn't working as expected
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants