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

KeyError instead of AssertionError #69

Closed
pawamoy opened this issue Sep 1, 2021 · 1 comment
Closed

KeyError instead of AssertionError #69

pawamoy opened this issue Sep 1, 2021 · 1 comment

Comments

@pawamoy
Copy link

pawamoy commented Sep 1, 2021

PDM uses installer internally. When installing torch 1.5.1+cpu, I get this error:

Install torch 1.5.1+cpu failed
Error occurs: 
Traceback (most recent call last):
  File "/usr/lib64/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.8/site-packages/pdm/installers/synchronizers.py", line 190, in install_candidate
    self.manager.install(can)
  File "/usr/local/lib/python3.8/site-packages/pdm/installers/manager.py", line 31, in install
    installer(candidate.build(), self.environment, candidate.direct_url())
  File "/usr/local/lib/python3.8/site-packages/pdm/installers/installers.py", line 74, in install_wheel
    _install_wheel(
  File "/usr/local/lib/python3.8/site-packages/pdm/installers/installers.py", line 173, in _install_wheel
    for record_elements, stream in source.get_contents():
  File "/usr/local/lib/python3.8/site-packages/installer/sources.py", line 165, in get_contents
    record = record_mapping.pop(item.filename)
KeyError: 'caffe2/'

I think you simply forgot the default argument of pop. I'll open a PR.

See pdm-project/pdm#636

@pradyunsg
Copy link
Member

Fixed in #72.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants