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

subdependencies resolution gets stuck indefinitely with this pyproject.toml #1729

Closed
1 task done
omars44 opened this issue Feb 21, 2023 · 1 comment
Closed
1 task done
Labels
🐛 bug Something isn't working

Comments

@omars44
Copy link

omars44 commented Feb 21, 2023

  • I have searched the issue tracker and believe that this is not a duplicate.

I'm not entirely sure what is the cause, but I can say just by observation that this type of dependency declaration is the culprit

dependencies = [
    'PySide6'
]

While this one works normally:

dependencies = [
    "PySide6>=6.4.2",
]

Steps taken to work-around the issue:

pdm remove PySide6
pdm add PySide6

Steps to reproduce

Using a project without a lock file with the following pyproject.toml

pdm config python.use_venv false
pdm install

pyproject.toml

[project]
name = 'example'
dynamic = ['version']
description = ''
authors = [
    {name = 'User', email = 'user@example.com'},
]
dependencies = [
    'PySide6'
]
requires-python = '>=3.9,<3.10'
license = {text = 'MIT'}

[project.optional-dependencies]
dev = [
    'mkdocs-material',
    'mkdocstrings',
    'mkdocstrings-python',
    'mkdocs-git-revision-date-plugin',
    'bump2version',
    'build'
]

[build-system]
requires = ['pdm-pep517']
build-backend = 'pdm.pep517.api'

[project.scripts]
pdm = 'pdm.core:main'

[tool.coverage.run]
branch = true
parallel = true
omit = [
  'example/__about__.py',
]

[tool.coverage.report]
exclude_lines = [
  'no cov',
  'if __name__ == .__main__.:',
  'if TYPE_CHECKING:',
]

[tool.mypy]
disallow_untyped_calls = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_subclassing_any = true
warn_no_return = true
strict_optional = true
no_implicit_optional = true
disallow_any_generics = true
disallow_any_unimported = true
warn_redundant_casts = true
warn_unused_configs = true
show_traceback = true
always_true = 'MYPYC'


[tool.pytest]
testpaths='tests/'

Actual behavior

stuck Resolving PySide6

Expected behavior

installing the dependencies and producing a lock file

Environment Information

pdm info && pdm info --env
PDM version:
  2.4.5
Python Interpreter:
  /usr/bin/python3 (3.9)
Project Root:
  /home/user/dev/python/example-cookiecutter/example
Project Packages:
  /home/user/dev/python/example-cookiecutter/example/__pypackages__/3.9
{
  "implementation_name": "cpython",
  "implementation_version": "3.9.2",
  "os_name": "posix",
  "platform_machine": "x86_64",
  "platform_release": "5.10.0-21-rt-amd64",
  "platform_system": "Linux",
  "platform_version": "#1 SMP PREEMPT_RT Debian 5.10.162-1 (2023-01-21)",
  "python_full_version": "3.9.2",
  "platform_python_implementation": "CPython",
  "python_version": "3.9",
  "sys_platform": "linux"
}
@omars44 omars44 added the 🐛 bug Something isn't working label Feb 21, 2023
@omars44 omars44 changed the title subdependecies resolution gets stuck indefinitely with this pyproject.toml subdependencies resolution gets stuck indefinitely with this pyproject.toml Feb 21, 2023
@frostming
Copy link
Collaborator

frostming commented Mar 1, 2023

I can't reproduce this using Python 3.10 on macOS. Adding -v option to show the verbose output may help identify what is blocking.

There are some weirdness in your pyproject.toml

  1. You specified dynamic = ["version"] but there is no tool.pdm.version table.
  2. You seems to copy project.scripts section from pdm but it doesn't exist in your project.

@frostming frostming closed this as not planned Won't fix, can't repro, duplicate, stale Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants