Skip to content

Commit

Permalink
fix: pdm translator fails to resolve dependency if no spec given
Browse files Browse the repository at this point in the history
  • Loading branch information
betaboon committed Dec 7, 2023
1 parent 69cb68a commit 33441f8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pycross/private/tools/pdm_translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@ def satisfies(self, req: Requirement) -> bool:
# Extras are case-insensitive. The left side is already lower-cased.
if not self.extras.issuperset(set(r.lower() for r in req.extras)):
return False
if not req.specifier:
return True
return req.specifier.contains(self.version)

def to_lock_package(self) -> Package:
Expand Down

0 comments on commit 33441f8

Please sign in to comment.