Skip to content

update implicit root docs#1869

Merged
Gankra merged 3 commits intomainfrom
gankra/rootdoc
Dec 13, 2025
Merged

update implicit root docs#1869
Gankra merged 3 commits intomainfrom
gankra/rootdoc

Conversation

@Gankra
Copy link
Contributor

@Gankra Gankra commented Dec 12, 2025

As of astral-sh/ruff#21817, ./tests are no longer implicitly included.

Copy link
Member

@AlexWaygood AlexWaygood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

docs/reference/configuration.md is generated and needs to be updated over in the Ruff repo (see failing CI)

@carljm carljm closed this Dec 12, 2025
@carljm
Copy link
Contributor

carljm commented Dec 12, 2025

Oh sorry, didn't realize this also changes a non-generated file.

@carljm carljm reopened this Dec 12, 2025
@Gankra Gankra enabled auto-merge (squash) December 13, 2025 03:51
Comment on lines +30 to +31
Note that a `./python` folder is automatically added to the project `root` if it exists,
and is not itself a package (i.e. does not contain an `__init__.py` file or an
Copy link
Contributor

@carljm carljm Dec 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we discuss this down here, separately from the mention of ./src above? Isn't the treatment of ./python the same as the treatment of ./src? (I realize that choice predates this PR.)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm other variants of this doc seemed to suggest there were two mutually exclusive "layout modes" we detected, but the ./python addition was applicable to both.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think that is the case...

Comment on lines 7 to 8
By default, ty searches for first-party modules in the project's root directory or the `src`
directory, if present.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
By default, ty searches for first-party modules in the project's root directory and in `src` and `python`
subdirectories, if the latter are present and are not packages (don't contain an `__init__.py` or `__init__.pyi` file).

@AlexWaygood AlexWaygood dismissed their stale review December 13, 2025 19:53

changes were made

@Gankra Gankra merged commit b5854c5 into main Dec 13, 2025
12 checks passed
@Gankra Gankra deleted the gankra/rootdoc branch December 13, 2025 19:53
@Gankra
Copy link
Contributor Author

Gankra commented Dec 13, 2025

Oh ha, I had auto-merge set from before Carl had comments, and Alex dismissing his review unblocked it, whoops!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments