Skip to content

Commit e77cc01

Browse files
Simplify comment
1 parent f798f2e commit e77cc01

1 file changed

Lines changed: 3 additions & 5 deletions

File tree

src/core/pathUtils.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -153,11 +153,9 @@ export async function findProjectRoot(
153153
): Promise<string> {
154154
let dirUri = uriDirname(entryUri)
155155

156-
// If the entry file's directory doesn't have __init__.py it could be a
157-
// top-level script OR a namespace package (no __init__.py) in a monorepo.
158-
// Walk up toward the workspace root to find a pyproject.toml; if found,
159-
// that directory is the Python project root. Otherwise fall back to the
160-
// entry dir as before.
156+
// No __init__.py — could be a namespace package. Walk up toward the
157+
// workspace root to find a pyproject.toml; if found, that directory is
158+
// the Python project root. Otherwise fall back to the entry dir.
161159
if (!(await fs.exists(fs.joinPath(dirUri, "__init__.py")))) {
162160
let searchDir = dirUri
163161
while (isWithinDirectory(searchDir, workspaceRootUri)) {

0 commit comments

Comments
 (0)