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
71e89c12
Unverified
Commit
71e89c12
authored
Nov 12, 2018
by
Sébastien Eustace
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Pool not raising an error when no package could be found
parent
c12d86b7
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
1 deletions
+15
-1
CHANGELOG.md
+1
-0
poetry/repositories/pool.py
+1
-1
tests/repositories/test_pool.py
+13
-0
No files found.
CHANGELOG.md
View file @
71e89c12
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
### Fixed
### Fixed
-
Fixed permission errors when adding/removing git dependencies on Windows.
-
Fixed permission errors when adding/removing git dependencies on Windows.
-
Fixed
`Pool`
not raising an exception when no package could be found.
## [0.12.7] - 2018-11-08
## [0.12.7] - 2018-11-08
...
...
poetry/repositories/pool.py
View file @
71e89c12
...
@@ -73,7 +73,7 @@ class Pool(BaseRepository):
...
@@ -73,7 +73,7 @@ class Pool(BaseRepository):
return
package
return
package
r
eturn
None
r
aise
PackageNotFound
(
"Package {} ({}) not found."
.
format
(
name
,
version
))
def
find_packages
(
def
find_packages
(
self
,
name
,
constraint
=
None
,
extras
=
None
,
allow_prereleases
=
False
self
,
name
,
constraint
=
None
,
extras
=
None
,
allow_prereleases
=
False
...
...
tests/repositories/test_pool.py
0 → 100644
View file @
71e89c12
import
pytest
from
poetry.repositories
import
Pool
from
poetry.repositories
import
Repository
from
poetry.repositories.exceptions
import
PackageNotFound
def
test_pool_raises_package_not_found_when_no_package_is_found
():
pool
=
Pool
()
pool
.
add_repository
(
Repository
())
with
pytest
.
raises
(
PackageNotFound
):
pool
.
package
(
"foo"
,
"1.0.0"
)
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