-
Notifications
You must be signed in to change notification settings - Fork 13.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bootstrap: correctly handle doc paths within submodules #135096
Conversation
Not super happy with how this macro still looks (it's still a bit convoluted), but at least the invocation-site is a bit nicer to use, I suppose. There's also some pre-existing issues, such as:
|
@onur-ozkan do you think we should fix-forward (i.e. this PR) or revert #134967 then try to reland that? |
I think we can fix it right away. I need couple minutes to review this. |
@rustbot author |
038a9f8
to
3e8ead1
Compare
Changes since last review:
Tested this locally again by unregistering @rustbot ready |
3e8ead1
to
399e69e
Compare
This comment has been minimized.
This comment has been minimized.
399e69e
to
4406f42
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, feel free to r=me once CI goes green
PR CI is 🍏 |
@bors p=1 (contributor roadblock, feel free to include in rollup) |
@bors p=6 (scheduling this before the next-in-line rollup) |
book!
macro and correctly handle doc paths within submodules
☀️ Test successful - checks-actions |
Finished benchmarking commit (ead4a8f): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)Results (secondary 0.8%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (secondary 2.8%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 762.575s -> 762.69s (0.02%) |
Fixes #135041 by passing the correct submodule path when requiring submodules. This PR changes
is_path_in_submodule
tosubmodule_path_of
.submodule_path_of
returns the path of the containing submodule when given a path nested inside a submodule we handle, andNone
otherwise.I tested this manually locally by unregistering the
src/tools/cargo
submodule, then running./x doc src/tools/cargo/src/doc
. This command fails on master withsince the require submodule fails as
src/tools/cargo/src/doc
is not a known submodule. Now we use the submodule path if such a nested-in-submodule-path is passed, and thus running this command with cargo submodule unregistered still succeeds:r? @onur-ozkan