Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
python-poetry
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
python-poetry
Commits
f0bb4970
Unverified
Commit
f0bb4970
authored
May 28, 2018
by
Sébastien Eustace
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix init and add commands
parent
e89ad9af
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
1 deletions
+18
-1
CHANGELOG.md
+1
-0
poetry/console/commands/add.py
+3
-0
poetry/console/commands/init.py
+10
-0
poetry/repositories/pypi_repository.py
+4
-1
No files found.
CHANGELOG.md
View file @
f0bb4970
...
...
@@ -5,6 +5,7 @@
### Fixed
-
Fixed packages not found for prerelease version constraints when resolving dependencies.
-
Fixed
`init`
and
`add`
commands.
## [0.10.0] - 2018-05-28
...
...
poetry/console/commands/add.py
View file @
f0bb4970
...
...
@@ -29,6 +29,9 @@ If you do not specify a version constraint, poetry will choose a suitable one ba
'poetry.repositories.pypi_repository'
]
def
initialize
(
self
,
i
,
o
):
super
(
AddCommand
,
self
)
.
initialize
(
i
,
o
)
def
handle
(
self
):
from
poetry.installation
import
Installer
from
poetry.semver
import
parse_constraint
...
...
poetry/console/commands/init.py
View file @
f0bb4970
...
...
@@ -33,6 +33,16 @@ The <info>init</info> command creates a basic <comment>pyproject.toml</> file in
self
.
pool
=
None
def
initialize
(
self
,
i
,
o
):
from
poetry.repositories
import
Pool
from
poetry.repositories.pypi_repository
import
PyPiRepository
super
(
InitCommand
,
self
)
.
initialize
(
i
,
o
)
if
self
.
pool
is
None
:
self
.
pool
=
Pool
()
self
.
pool
.
add_repository
(
PyPiRepository
())
def
handle
(
self
):
from
poetry.layouts
import
layout
from
poetry.utils._compat
import
Path
...
...
poetry/repositories/pypi_repository.py
View file @
f0bb4970
...
...
@@ -88,7 +88,10 @@ class PyPiRepository(Repository):
"""
Find packages on the remote server.
"""
if
constraint
is
not
None
and
not
isinstance
(
constraint
,
VersionConstraint
):
if
constraint
is
None
:
constraint
=
'*'
if
not
isinstance
(
constraint
,
VersionConstraint
):
constraint
=
parse_constraint
(
constraint
)
info
=
self
.
get_package_info
(
name
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment