Repository navigation
Write no hosted Cargo pin that a rules_rust hub would fail on - #2192
Mikola Lysenko (mikolalysenko) wants to merge 4 commits into
Conversation
The real-Bazel Cargo flows run on a hub that names the project's cargo
config (`cargo_config = "//:.cargo/config.toml"`). The hub of the
rules_rust README names none:
crate.from_cargo(
name = "crates",
cargo_lockfile = "//:Cargo.lock",
manifests = ["//:Cargo.toml"],
)
cargo-bazel links what stands beside each manifest such a hub names into
a directory of its own and writes a root manifest of its own there. It
then removes every cargo config it finds there and puts back only the
file the hub names (`symlink_roots`, `write_root_manifest` and
`setup_cargo_config` in crate_universe/src/splicing/splicer.rs,
rules_rust 0.56.0 and 0.75.0). Hosted mode names a registry of its own
on the dependency in Cargo.toml and defines it in `.cargo/config.toml`,
so on this hub the cargo that cargo-bazel runs has never heard of that
registry.
`cargo::hosted_from_cargo_without_config` holds what the release does
there: the build passes on the upstream crate; `scan --mode hosted
--yes` exits 0, reports the crate applied and rewrites
`.cargo/config.toml`, `Cargo.lock` and `Cargo.toml`; and the next `bazel
build //:consumer` fails in the hub with cargo's
registry index was not found in any configuration: `socket-patch-<uuid>`
It passes on Bazel 9.3.2 (rules_rust 0.75.0) and 7.7.2 (rules_rust
0.56.0) with the product code as it is. The next commit changes the
product and these expectations.
The flow is the fixture of the other two with one per-test edit: the
`cargo_config` line is taken out of the era's MODULE.bazel, and the
checkout has no cargo config. The hermetic test of the fixture holds
that every era's hub is the README's but for that line.
The crate under test still comes from the loopback stand-in and from no
other host. The README says how a hub without a config reaches a private
registry: with `CARGO_BAZEL_ISOLATED=false` it runs its cargo with the
cargo home of the machine, and the test's cargo home names the mirror in
its `config.toml`. cargo-bazel itself reads no cargo config the hub does
not name. For a crate the lock takes from crates.io it goes by what the
cargo home keeps of that index: `config.json` for the download URL, and
with rules_rust 0.56.0 the crate's cached file of the index as well. A
cargo behind a mirror fetches neither, so the test writes both into its
cargo home, as a home holds them whose cargo fetched the crate from
crates.io itself. `cargo_env` takes the isolation switch as an argument
for that; the two existing flows pass `true`, as before.
bazel-cargo.yml: the header names the third flow. A leg still holds two
workspace copies at a time (`--test-threads=2`).
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A crate_universe hub of rules_rust runs cargo over the Cargo.toml files
and the Cargo.lock it names, in a directory of its own, with one cargo
config: the file the hub names as `cargo_config`, and none when it
names none (the previous commit has the source). Hosted mode names a
registry of its own on the dependency in Cargo.toml and defines it in
the project's `.cargo/config.toml`. On the hub of the rules_rust README,
which names no `cargo_config`, `scan --mode hosted` exited 0 and
reported the crate applied, and the next `bazel build` failed:
registry index was not found in any configuration: `socket-patch-<uuid>`
A command that exits 0 must not leave a build broken. Hosted mode now
writes no pin for a crate while such a hub is in the way.
What changes
In a Bazel workspace (`bazel::bazel_root`: a workspace file in the
project's directory or above it, up to the root of its git checkout),
`scan --mode hosted` and `get --mode hosted` read the workspace files
for the calls that make a crate_universe hub:
- the `from_cargo` tags of the `crate` extension of rules_rust in
MODULE.bazel and the files it includes, under either file the ruleset
defines the extension in (`//crate_universe:extensions.bzl`, and
`extension.bzl`, which hands it on; rules_rust 0.56.0 and 0.75.0);
- `crates_repository(...)` calls of the WORKSPACE file, when the module
files make no such tag and the checkout names no Bazel 9.0.0 or later,
which never reads that file.
A hub concerns the project when a label of its `cargo_lockfile` or its
`manifests` is the project's Cargo.lock, its Cargo.toml or the manifest
of a workspace member. `@<name>//` is the checkout under the root
module's name, and in a WORKSPACE file under the name that
`workspace(name = ...)` gives the main repository
(`WorkspaceGlobals.workspace`, Bazel 7.7.2 and 8.8.2). The hub is in the
way unless its `cargo_config` is one string, the label of the config the
rewriter writes (`.cargo/config.toml`, or the project's legacy
`.cargo/config`).
For a crate the rewriter would otherwise pin, nothing is written. The
crate is `skipped` (`redirect_unconfirmed`), status and exit code are
those of every other crate hosted mode leaves out (0), and one warning
per crate, `redirect_cargo_bazel_config_unread`, names the hub by file
and line and the two ways on:
<crate>@<version>: the rules_rust hub at MODULE.bazel:10 reads the
Cargo files of this project, and it names no `cargo_config`. [...]
dependency skipped (nothing rewritten). Commit .cargo/config.toml
(where the project has none, create it with a comment line in it:
`rollback` deletes a config it leaves empty, and a hub that names a
missing file fails), give the hub `cargo_config =
"//:.cargo/config.toml"`, the label of that file as one string, and
run this command again; or use `--mode vendored`, which commits the
patched crate and needs no registry
The file comes first in it. A hub that is given the attribute alone
fails on the missing file (`Failed to splice workspace crates`; measured
once on Bazel 9.3.2, held by no test), and a config that a scan created
is deleted by the `rollback` that empties it; a comment line keeps it.
Where the reason is a use of the extension that may hide a hub, the hub
that is seen may name the config already, and there may be no other. The
warning then names that line and no attribute:
<crate>@<version>: MODULE.bazel:17: `crate` is used other than to
call a tag, so a rules_rust hub that socket-patch cannot read may
take the Cargo files of this project. [...] Write that line as the
call of a tag (`crate.from_cargo(...)`) or as `use_repo(...)` and
run this command again: it then pins the crate, or names the hub
that is in the way; or use `--mode vendored`, [...]
The rewriter's own refusals answer first and keep their codes. A pin
that is in place already stays what it was: applied, with nothing to
write and no warning. A vendored crate that the scan would take over
stays vendored and patched (`redirect_takeover_kept_vendored`).
The model is `redirect_cargo_directory_source`: the same place in
`rewrite_cargo_with`, the same exit code and the same shape of text. The
check sits where the three plans of a crate are complete, so that it
withholds only what would be written. The engine reads the workspace
with each read of the candidate files, for a run with a cargo candidate
on disk, and hands the reason to the rewriter under a synthetic key
among those files, as it does for the hubs of rules_jvm_external.
Where the reading is not certain
A broken build weighs more than a patch that waits for one line of the
user's, so wherever a hub, or a use of the extension through a name
bound to it, is seen, a reading that is not certain withholds the pin,
and the warning says what could not be read:
- a `cargo_lockfile` or `manifests` that is not written out as a string
or a list of strings (a constant, a concatenation, an attribute left
to `**`): the hub may read the project's files;
- a `cargo_config` that is not written out as one string is not taken
for the right file, a list of one label included;
- a call that is not a statement of its own counts: it may run;
- a use of the extension that may hide a call (`Tags::doubts`) counts;
- a WORKSPACE call counts as above. Bazel 7 reads that file and Bazel 8
when it is told to, so a WORKSPACE file that a move to Bzlmod left
behind can withhold a pin on Bazel 8 where the module files make no
hub. The warning names the call. Where `workspace(name = ...)` is not
written out as a string, any `@name//` label of that file is taken
for the checkout.
Where no hub is seen to concern the project, nothing is read further,
said or written: in no Bazel workspace, in a workspace without such a
hub, for a hub that names the config, for a hub whose labels are all
written out and name other files, and for the tag of the same name of
another ruleset. A doubt of the reader about the workspace files in
general (`Workspace::doubts`) withholds nothing where no hub is seen:
it would take hosted mode from every Cargo project beside a Bazel
workspace that has nothing to do with rules_rust.
Tests
- bazel::cargo: eleven unit tests over workspace files: the README hub
and its warning, each spelling of the right config, a wrong or
unreadable config, which files concern which project, hubs whose
files are not written out, every call that counts, tags of other
extensions, a hidden call and its own way on, workspaces without a
hub, the WORKSPACE file per Bazel release and under the names it
gives the checkout, and the read from a checkout on disk.
- The rewriter: one test. Each of the three files alone is enough to
withhold (no lock, a config that lost the registry, a config that
defines it already). The engine: one test, the lock and each manifest
handed over.
- e2e_bazel_build, without a Bazel: the binary in checkouts of the
fixture's Cargo files. On the README hub `scan`, its dry run and `get`
write nothing and a person reads why; a line that may hide a hub
withholds beside a hub that names the config, and the warning names
the line; with the file and the attribute the same scan pins, and
`rollback` gives the checkout back. Where no hub reads the project
(six shapes) the envelope and the three files are those of a checkout
without a Bazel workspace, byte for byte. A vendored crate stays
vendored.
- e2e_bazel_build on real Bazel: `cargo::hosted_from_cargo_without_config`
now holds that the scan withholds, that the same build still prints
the unpatched marker and changes no file, and then both ways the
warning names, on the hub of the README: `scan --mode vendored` and
the build prints the patched marker, and `vendor --revert` gives the
checkout back; with the committed config and the one attribute the
hosted scan applies and the build prints the patched marker, from the
patch host. Bazel 9.3.2 and 8.8.2 (rules_rust 0.75.0) and 7.7.2
(rules_rust 0.56.0), macOS arm64: 124 s, 58 s and 110 s for this
flow, 217 s, 174 s and 188 s for the three Cargo flows of a leg, two
at a time. Held against a binary of the parent commit, the flow fails
where it asks that the scan applied nothing.
One held gap: `rollback` deletes a cargo config it leaves empty, and a
hub that names a missing file fails. The warning says to create such a
file with a comment line in it, and the hermetic test holds the deletion
so that the advice goes when that is fixed.
Not covered
In the first four a hub without the config fails as before.
- A hub that another Bazel module declares; a `crates_repository` in a
`.bzl` file that the WORKSPACE file loads, or called under another
name.
- Where no hub is seen: a tag called on `use_extension(...)` itself,
with no name bound to it; a MODULE.bazel that cannot be read (a link
that leads out of the Bazel root, a file past the reader's bounds);
and what else the workspace files hide from every reading.
- Flags and rc files: none is read, in the checkout or outside it.
`--noenable_bzlmod` has Bazel read the WORKSPACE file in place of
module files that make a hub.
- A Bazel root above a project that is in no git checkout: only the
project's own directory is looked at for a workspace file there.
- The in-memory hosted engine, which is handed a project's files and
reads no Bazel file.
- `crate.from_specs` hubs and `crates_vendor` targets.
- A hub with a cargo-bazel lock (`lockfile`) asks for a repin after any
change of Cargo.lock, a pin included. That is unchanged.
- A pin an earlier release wrote on such a hub stays and stays reported
as applied; that build is failing already.
docs/ecosystems.md has the section "Bazel workspaces: Cargo", and
CLI_CONTRACT.md the code. scripts/loc-budget.json: the bazel group's cap
follows the code, 2486 to 2618.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Two files conflicted, each in one long line that both sides had added to: - CLI_CONTRACT.md, the hosted paragraph: main's sentences on the patch mirror and on pixi projects are kept, and this branch's pointer to `redirect_cargo_bazel_config_unread` is put back in its place. - docs/ecosystems.md, the support table: main's new pixi row is kept, and the Cargo row keeps this branch's sentence on Bazel workspaces. `patch/redirect/mod.rs` and `hosted/engine.rs` merged without a conflict. The `bazel` line budget is unchanged by main (2618 of 2618). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A review of the withhold found five cases where a pin could still be written that a rules_rust hub fails on, or where the warning sent the user the wrong way. Each has a unit row that fails on the code as it was. - A `crates_repository` of the `WORKSPACE` file was looked at only when the module files made no `crate.from_cargo` hub at all. Bazel 7 reads both, so a workspace whose module hub is over another project's files and whose `WORKSPACE` hub reads this one got the pin. The file now counts when no hub of the module files concerns the project. - The rule was known by its own name alone. A `load` that gives it another (`load(..., crates = "crates_repository")`) is now followed. - A hub that names the right config was passed although the file held nothing. The pin is written into it, a later `rollback` deletes the file it leaves empty, and the hub then fails on the missing file: a build that passed before the scan. Such a hub is now in the way, and the warning asks for a comment line. A file that is not there yet is still created by the pin, as before. - The warning gave the label of the config in the project's directory (`//svc/app:.cargo/config.toml`). Where the hub names the project's files from another package (`//:svc/app/Cargo.toml`), that directory is no package and the label names nothing. The label is now written in the package of the hub's own labels. - Under a `workspace(name = ...)` that is not written out, any `@name//` label was taken for the checkout, also as `cargo_config`. That widens what a hub may read, which is safe, and what names the project's config, which is not: another repository's config passed. It now applies to the lock and the manifests only. The engine also had a third copy of the rule for which cargo config the rewriter writes. It now calls the rewriter's own, `cargo_config_key`. The hermetic test that held the `rollback` gap now holds both halves: a config that holds nothing gets no pin, and a config that the pin creates is still deleted by `rollback`. The `bazel` line budget follows the code, 2618 to 2665. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
PR SummaryMedium Risk Overview New logic in Tests and CI: E2E Reviewed by Cursor Bugbot for commit 64c75e9. Configure here. |
In a Bazel workspace,
scan --mode hostedandget --mode hostedno longer pin a crate while a rules_rust crate_universe hub reads the project's Cargo files without its cargo config: the crate is skipped with the new warningredirect_cargo_bazel_config_unreadinstead of leavingbazel buildbroken.Based on main, in two commits, a merge of main and one commit of review fixes. The first commit is tests only and records what main does today; the second is the change, with the expectations of the first changed to match.
Decisions for the maintainer
cargo_configthat is not one string, a call that is not a statement of its own), the crate is skipped with a warning that names the line. The price is a missed patch with an explanation; the alternative is to write as before whenever the reading is not certain, which leaves those builds to break.WORKSPACEfile left behind by a move to Bzlmod can withhold a pin. Acrates_repositorycall in aWORKSPACEfile counts when nofrom_cargohub of the module files concerns the project and the checkout does not name Bazel 9.0.0 or later. On Bazel 8, or where no release is named, Bazel may not read that file at all, and the pin is withheld all the same. The warning names the call.WORKSPACEspelling is read, not measured. That aWORKSPACEhub fails on a pin, also under labels that use the workspace's own name, is read from the ruleset and from how Bazel names the main repository. The flows on real Bazel are Bzlmod only.WORKSPACEreading, the second remedy text for a line that may hide a hub, the one-string check ofcargo_config, and 49 code lines for the five review fixes below.MODULE.bazelthat cannot be read included. The alternative protects against a hub hidden behind an unreadable construct and takes hosted mode from unrelated Cargo projects beside any such workspace. A middle is possible and not built: withhold only where the root module depends on rules_rust and a module file cannot be read.rollbackfix first. A user who gives the hub the attribute and creates no file gets a patched build, because the scan creates the config; a laterrollbackexits 0, deletes that config and the build fails, as it did before the scan. The warning puts the file first. A config that is there and holds nothing is now held back with its own warning, because there the build passed before the scan. The alternative is to land a fix that keeps the cargo config a hub names throughrollback, and to drop both.redirect_cargo_bazel_config_unread.What the code does today
A crate_universe hub of rules_rust (
crate.from_cargoinMODULE.bazel,crates_repositoryin aWORKSPACEfile) runs cargo over theCargo.tomlfiles and theCargo.lockit names, in a directory of its own. Its tool, cargo-bazel, links what stands beside each manifest into that directory, writes a root manifest of its own there, removes every cargo config it finds there and puts back one: the file the hub names ascargo_config, and none when the hub names none (symlink_roots,write_root_manifestandsetup_cargo_configincrate_universe/src/splicing/splicer.rs, rules_rust 0.56.0 and 0.75.0).Hosted mode names a registry of its own on the dependency in
Cargo.tomland defines it in the project's.cargo/config.toml. The hub of the rules_rust README names nocargo_config:On that hub
socket-patch scan --mode hosted --yesexits 0, reports the crate applied and rewrites.cargo/config.toml,Cargo.lockandCargo.toml. The nextbazel buildfails in the hub:The first commit holds exactly that on real Bazel (9.3.2 with rules_rust 0.75.0 and 7.7.2 with 0.56.0), with the product code as it is.
What changes
For a run with a Cargo candidate, in a Bazel workspace (a
MODULE.bazel,REPO.bazel,WORKSPACEorWORKSPACE.bazelin the project's directory or above it, up to the root of its git checkout), hosted mode reads the workspace files for the calls that make a crate_universe hub:from_cargotags of thecrateextension of rules_rust inMODULE.bazeland the files it includes (//crate_universe:extensions.bzl, andextension.bzl, which hands the same extension on);crates_repository(...)calls of theWORKSPACEfile, also under the name aloadof that file gives the rule, when no such tag concerns the project and the checkout names no Bazel 9.0.0 or later, which never reads that file. Bazel 7 reads that file beside the module files.A hub concerns the project when a label of its
cargo_lockfileor itsmanifestsis the project'sCargo.lock, itsCargo.tomlor the manifest of a workspace member.@<name>//is the checkout under the root module's name, and in aWORKSPACEfile under the name itsworkspace(name = ...)gives the main repository. The hub is in the way unless itscargo_configis one string, the label of the config the rewriter writes (.cargo/config.toml, or the project's legacy.cargo/config), and also while that file is there and holds nothing: arollbackof the pin would delete it, and the hub fails on a missing file.For a crate the rewriter would otherwise pin, nothing is written. The crate is
skipped(redirect_unconfirmed), the exit code is 0 and the statussuccess, as for every other crate hosted mode leaves out, and one warning per crate says why and names the two ways on:The label in the warning is written in the package of the hub's own labels: for a hub that names
//:svc/app/Cargo.tomlit is//:svc/app/.cargo/config.toml.Where the reason is a line that may hide a hub, the hub that is seen may name the config already and there may be no other, so the warning names that line and no attribute:
redirect_takeover_kept_vendored).redirect_cargo_directory_source: the same function, the same exit code, the same shape of text.Nothing changes outside a Bazel workspace, and nothing for a project that no hub is seen to read: a workspace without such a hub, a hub that names the config, a hub whose labels are all written out and name other files (another directory, another repository), the tag of the same name of another ruleset. Measured against a binary of the base in pairs of identical checkouts, as JSON, as a person and as a dry run: 27 of 27 pairs, over nine such shapes, have the same exit code, the same stdout and stderr and the same files, byte for byte.
Where the reading is not certain
A broken build weighs more than a patch that waits for one line, so wherever a hub, or a use of the extension through a name bound to it, is seen, a reading that is not certain withholds the pin, and the warning says what could not be read:
cargo_lockfileormanifeststhat is not written out as a string or a list of strings (a constant, a concatenation, an attribute left to**): the hub may read the project's files;cargo_configthat is not written out as one string is not taken for the right file, a list of one label included;WORKSPACEcall counts as described above. Bazel 7 reads that file and Bazel 8 when it is told to, so aWORKSPACEfile that a move to Bzlmod left behind can withhold a pin where the module files make no hub. The warning names the call. Whereworkspace(name = ...)is not written out as a string, any@name//label of a lock or a manifest in that file is taken for the checkout, and none is as acargo_config.Where no hub is seen at all, nothing is withheld, also when something else in the workspace files cannot be read. Withholding there would take hosted mode from every Cargo project beside a Bazel workspace that has nothing to do with rules_rust.
Contents
Two commits.
cargo::hosted_from_cargo_without_config, which records the break (tests +141 / -9, workflow header +11 / -8 comment lines).bazel/cargo.rs178,patch/redirect/mod.rs13,hosted/engine.rs11,bazel/mod.rs1srctests/e2e_bazel_build/cargo.rsdocs/ecosystems.md,CLI_CONTRACT.md)bazel-cargo.ymlscripts/loc-budget.json: the cap of thebazelgroup follows the code, 2486 to 2665.The engine reads the workspace with each read of the candidate files and hands the reason to the cargo rewriter under a synthetic key among those files, as it does for the hubs of rules_jvm_external. The check sits where the three plans of a crate are complete, so it withholds only what would be written.
What it proves, and where
bazel-compatibility.ymlruns a leg; on 9.3.2 again after the merge of main and after the review fixes. The flow on the README hub: the build prints the unpatched marker; the scan withholds, changes no file and a person reads why; the same build prints the same marker, changes no file and passes with--lockfile_mode=error. Then both ways the warning names. Vendored mode on that hub: the build prints the patched marker, andvendor --revertwith the next build gives every file back. The config committed and the one attribute on the hub: the same hosted scan applies and the build prints the patched marker, from the patch host. 124 s, 58 s and 110 s for this flow; 217 s, 174 s and 188 s for the three Cargo flows of a leg. The two existing flows pass unchanged.e2e_bazel_build, the built binary in checkouts of the fixture's Cargo files): on the README hubscan, its dry run andgetwrite nothing; a line that may hide a hub withholds beside a hub that names the config, and the warning names the line; with the file and the attribute the same scan pins androllbackgives the checkout back; in six shapes where no hub reads the project the envelope and the three files are those of a checkout in no Bazel workspace; a vendored crate stays vendored.WORKSPACEfile per Bazel release, beside a module hub of another project, under a loaded name of the rule and under the names it gives the checkout), one for the rewriter (each of the three files alone is enough to withhold), one for the engine (the lock and each manifest handed over).WORKSPACEname, the one-string config, and four on what is withheld and handed over, three of which the first set of tests had let through). Each is caught by a unit test.The flow keeps to the loopback stand-in. A hub without
cargo_configcannot be handed a mirror through it, so the flow does what the rules_rust README says for a private registry:CARGO_BAZEL_ISOLATED=false, and the mirror is named in the cargo home of the test. cargo-bazel itself looks up a crates.io crate in what that cargo home keeps of the crates.io index, so the test writes those two files there, as a cargo home holds them that has fetched the crate from crates.io.Not covered
In the first four a hub without the config fails as before.
crates_repositoryinside a.bzlfile that theWORKSPACEfile loads, or called under a name that noloadof that file gives it.use_extension(...)itself, with no name bound to it; aMODULE.bazelthat cannot be read (a link that leads out of the Bazel root, a file past the reader's bounds); and what else the workspace files hide from every reading.--noenable_bzlmodhas Bazel read theWORKSPACEfile in place of module files that make a hub.crate.from_specshubs andcrates_vendortargets.lockfile) asks for a repin after any change ofCargo.lock. Unchanged.socket-patch vexattests a hosted pin from the three files and does not look at the hub.WORKSPACEhubs and rules_rs have unit and hermetic tests only, no flow on real Bazel: that aWORKSPACEhub fails on a pin is read from the ruleset and from how Bazel names the main repository, not measured. Linux and Windows were not run locally; the workflow's Linux legs run on this pull request.rollbackdeletes a cargo config it leaves empty, and a hub that names a missing file fails (Failed to splice workspace crates; measured once on Bazel 9.3.2, held by no test). A config that is there and holds nothing gets no pin for that reason. A hub that names a file which is not there yet still gets the pin, which creates the file, and a laterrollbackdeletes it again: that build failed before the scan too. The warning says to create the file with a comment line in it, and a hermetic test holds the deletion so that the advice is dropped when that is fixed.config,registry,build) that are also names of packages, so in a run that withholds a crate and fails the takeover of such a package for another reason, that package's event can carry this code. The matcher is the takeover's own and treats every warning that way.Code review
A review of this pull request gave ten findings. Each was checked against the code; five were fixed in one commit, with a unit row for each that fails on the code as it was (three shown by running the rows first, two by a mutation of the fix), and the engine's copy of a rule was replaced by the rewriter's own.
Fixed:
WORKSPACEhub beside another project's module hub got the pin. TheWORKSPACEfile was looked at only when the module files made nocrate.from_cargohub at all, and Bazel 7 reads both. It now counts when no module hub concerns the project.load(..., crates = "crates_repository")). Theloadis now followed.rollbackdeleted the file and left the hub failing, where the build passed before the scan. Such a hub is now in the way, and the warning asks for a comment line.workspace(name = ...)that is not written out: the leniency for what a hub may read was also applied to what names the project's config.cargo_config_key; the in-memory stage keeps its own, which reads another type.Not fixed, and why:
config,registryorbuild. It is the last entry of Not covered: the matcher treats every warning that way, and the fix belongs there.🤖 Generated with Claude Code