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
7db3e072
Unverified
Commit
7db3e072
authored
May 17, 2022
by
David Hotham
Committed by
GitHub
May 17, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tolerate `poetry init` in `/` (#5612)
parent
ea335b56
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletions
+8
-1
src/poetry/layouts/layout.py
+8
-1
No files found.
src/poetry/layouts/layout.py
View file @
7db3e072
...
@@ -90,7 +90,14 @@ class Layout:
...
@@ -90,7 +90,14 @@ class Layout:
def
get_package_include
(
self
)
->
InlineTable
|
None
:
def
get_package_include
(
self
)
->
InlineTable
|
None
:
package
=
inline_table
()
package
=
inline_table
()
include
=
self
.
_package_path_relative
.
parts
[
0
]
# If a project is created in the root directory (this is reasonable inside a
# docker container, eg <https://github.com/python-poetry/poetry/issues/5103>)
# then parts will be empty.
parts
=
self
.
_package_path_relative
.
parts
if
not
parts
:
return
None
include
=
parts
[
0
]
package
.
append
(
"include"
,
include
)
# type: ignore[no-untyped-call]
package
.
append
(
"include"
,
include
)
# type: ignore[no-untyped-call]
if
self
.
basedir
!=
Path
():
if
self
.
basedir
!=
Path
():
...
...
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