Commit 0e6a9a23 by Sébastien Eustace

Fix handling of wildcard dependencies when packaging/publishing

parent e7cb3443
# Change Log
[Unreleased]
## [Unreleased]
### Added
......@@ -28,6 +28,7 @@ commands in project subdirectories.
- Fixed handling of extras when resolving dependencies.
- Fixed `self:update` command for some installation.
- Fixed handling of extras when building projects.
- Fixed handling of wildcard dependencies wen packaging/publishing.
## [0.8.6] - 2018-04-30
......
......@@ -132,7 +132,7 @@ class Dependency(object):
requirement += ' ({})'.format(','.join(
[str(c).replace(' ', '') for c in self.constraint.constraints]
))
else:
elif str(self.constraint) != '*':
requirement += ' ({})'.format(str(self.constraint).replace(' ', ''))
# Markers
......
......@@ -70,6 +70,13 @@ def test_to_pep_508():
'or (python_version >= "3.6.0.0" and python_version < "4.0.0.0")'
def test_to_pep_508_wilcard():
dependency = Dependency('Django', '*')
result = dependency.to_pep_508()
assert result == 'Django'
def test_to_pep_508_in_extras():
dependency = Dependency('Django', '^1.23')
dependency.in_extras.append('foo')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment