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

[bug] pdm cannot install on 2.20.0 #3239

Closed
1 task done
monchin opened this issue Oct 31, 2024 · 1 comment
Closed
1 task done

[bug] pdm cannot install on 2.20.0 #3239

monchin opened this issue Oct 31, 2024 · 1 comment
Labels
🐛 bug Something isn't working

Comments

@monchin
Copy link
Contributor

monchin commented Oct 31, 2024

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

Steps to reproduce

run pdm sync -v

Actual behavior

STATUS: Resolving packages from lockfile...
Traceback (most recent call last):
  File "C:\Users\c.men\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\c.men\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "C:\Users\c.men\AppData\Roaming\Python\Scripts\pdm.exe\__main__.py", line 7, in <module>
    sys.exit(main())
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\core.py", line 378, in main
    return core.main(args or sys.argv[1:])
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\core.py", line 267, in main
    raise cast(Exception, err).with_traceback(traceback) from None
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\core.py", line 262, in main
    self.handle(project, options)
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\core.py", line 194, in handle
    command.handle(project, options)
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\cli\commands\sync.py", line 44, in handle
    actions.do_sync(
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\cli\actions.py", line 284, in do_sync
    packages = list(resolve_from_lockfile(project, requirements, groups=list(selection)))
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\cli\actions.py", line 206, in resolve_from_lockfile
    resolver = project.get_resolver()(
  File "<string>", line 13, in __init__
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\resolver\resolvelib.py", line 30, in __post_init__ 
    provider = self.project.get_provider(
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\project\core.py", line 552, in get_provider        
    from pdm.resolver.providers import get_provider
  File "C:\Users\c.men\AppData\Roaming\pdm\venv\lib\site-packages\pdm\resolver\providers.py", line 49, in <module>       
    class BaseProvider(AbstractProvider[Requirement, Candidate, str]):
TypeError: 'type' object is not subscriptable

Expected behavior

install successfully

Environment Information

pdm 2.20.0, windows 10, use_uv false

It'll succeed on 4401ff5, so it seems efaccb8 got something wrong

@monchin monchin added the 🐛 bug Something isn't working label Oct 31, 2024
@frostming
Copy link
Collaborator

Update resolvelib to 1.1.0

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