No mechanism sets the git AUTHOR field to the acting agent — MOSAIC_GIT_IDENTITY is credential-selection only, so agent commits land under a real person's name
#986
There is no mechanism in the toolchain that sets the git author field to the acting agent. Agent-written commits land with whatever user.name / user.email the host happens to have configured — in practice, a real person's name on commits that person did not write.
MOSAIC_GIT_IDENTITY is widely assumed to cover this. It does not. It is a credential-selection variable — it chooses which token authenticates the push — and it is not wired to the author field at all.
Found by mos-dt, which traced the mechanism before it would have reported a peer as ignoring a coordinator instruction that named this variable as the fix. That instruction was wrong, and this issue exists because the control it named cannot produce the outcome it was named for.
Verified
Occurrences of MOSAIC_GIT_IDENTITY in the toolchain:
git-credential-mosaic — zero references to user.name, user.email, GIT_AUTHOR, GIT_COMMITTER.
The only author-field hits anywhere in that set are fixture setup inside a test (git init, then config a throwaway identity).
Observed consequence
On mosaicstack/stack#983 (the #973 batch), all six commits carry the intended Written-by: pepper (sb-it-1-dt) trailer and a git author field naming a person who did not author them. The authoring agent did nothing wrong — there is no supported way for it to do otherwise.
Why it matters beyond cosmetics
Blame and archaeology.git log --author, git blame, and every downstream tool report the wrong actor. The trailer is only visible to someone who reads the full commit body.
It quietly misattributes work to a named human. That is worse than an anonymous or generic identity, because it is specific and it is wrong.
It interacts with gate 16. Where per-agent credentials are not distributed, the commit author, the PR opener, and the reviewer can all collapse onto one account — and the author field, being the most visible of the three, is the one most likely to be read as provenance.
A control named for an outcome it cannot produce is not a weak control — it is an absent one. (mos-dt)
Expected
One of:
A per-agent commit wrapper that sets -c user.name / -c user.email from the resolved agent identity, so authorship lands on the field everything already reads.
Or, if the author field is deliberately left to the host: say so in the README next to MOSAIC_GIT_IDENTITY, so nobody else rules that the variable fixes it. Documented-and-deliberate is a legitimate answer; silently-assumed is not.
Until then, the Written-by: trailer is what actually carries authorship, and it should be described that way rather than as a supplement to a field that is expected to be correct.
Related
#980 — issue-create.sh API fallback creates issues under a different identity than the caller named. Same family: identity not landing where the caller believes it lands.
## Summary
There is **no mechanism in the toolchain that sets the git author field to the acting agent.** Agent-written commits land with whatever `user.name` / `user.email` the host happens to have configured — in practice, a **real person's name on commits that person did not write**.
`MOSAIC_GIT_IDENTITY` is widely assumed to cover this. **It does not.** It is a *credential-selection* variable — it chooses which token authenticates the push — and it is not wired to the author field at all.
Found by **mos-dt**, which traced the mechanism *before* it would have reported a peer as ignoring a coordinator instruction that named this variable as the fix. That instruction was wrong, and this issue exists because the control it named cannot produce the outcome it was named for.
## Verified
Occurrences of `MOSAIC_GIT_IDENTITY` in the toolchain:
```
packages/mosaic/framework/tools/git/git-credential-mosaic
packages/mosaic/framework/tools/git/detect-platform.sh
packages/mosaic/framework/tools/git/README.md
packages/mosaic/framework/tools/git/test-git-credential-mosaic.sh
packages/mosaic/framework/tools/git/test-gitea-token-identity.sh
```
- `git-credential-mosaic` — **zero** references to `user.name`, `user.email`, `GIT_AUTHOR`, `GIT_COMMITTER`.
- The only author-field hits anywhere in that set are **fixture setup inside a test** (`git init`, then config a throwaway identity).
## Observed consequence
On `mosaicstack/stack#983` (the #973 batch), all six commits carry the intended `Written-by: pepper (sb-it-1-dt)` trailer **and** a git author field naming a person who did not author them. The authoring agent did nothing wrong — there is no supported way for it to do otherwise.
## Why it matters beyond cosmetics
- **Blame and archaeology.** `git log --author`, `git blame`, and every downstream tool report the wrong actor. The trailer is only visible to someone who reads the full commit body.
- **It quietly misattributes work to a named human.** That is worse than an anonymous or generic identity, because it is specific and it is wrong.
- **It interacts with gate 16.** Where per-agent credentials are not distributed, the commit author, the PR opener, and the reviewer can all collapse onto one account — and the author field, being the most visible of the three, is the one most likely to be read as provenance.
> **A control named for an outcome it cannot produce is not a weak control — it is an absent one.** (mos-dt)
## Expected
One of:
1. A **per-agent commit wrapper** that sets `-c user.name` / `-c user.email` from the resolved agent identity, so authorship lands on the field everything already reads.
2. Or, if the author field is deliberately left to the host: **say so in the README next to `MOSAIC_GIT_IDENTITY`**, so nobody else rules that the variable fixes it. Documented-and-deliberate is a legitimate answer; silently-assumed is not.
Until then, the `Written-by:` trailer is what actually carries authorship, and it should be described that way rather than as a supplement to a field that is expected to be correct.
## Related
- `#980` — `issue-create.sh` API fallback creates issues under a different identity than the caller named. Same family: **identity not landing where the caller believes it lands.**
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
There is no mechanism in the toolchain that sets the git author field to the acting agent. Agent-written commits land with whatever
user.name/user.emailthe host happens to have configured — in practice, a real person's name on commits that person did not write.MOSAIC_GIT_IDENTITYis widely assumed to cover this. It does not. It is a credential-selection variable — it chooses which token authenticates the push — and it is not wired to the author field at all.Found by mos-dt, which traced the mechanism before it would have reported a peer as ignoring a coordinator instruction that named this variable as the fix. That instruction was wrong, and this issue exists because the control it named cannot produce the outcome it was named for.
Verified
Occurrences of
MOSAIC_GIT_IDENTITYin the toolchain:git-credential-mosaic— zero references touser.name,user.email,GIT_AUTHOR,GIT_COMMITTER.git init, then config a throwaway identity).Observed consequence
On
mosaicstack/stack#983(the #973 batch), all six commits carry the intendedWritten-by: pepper (sb-it-1-dt)trailer and a git author field naming a person who did not author them. The authoring agent did nothing wrong — there is no supported way for it to do otherwise.Why it matters beyond cosmetics
git log --author,git blame, and every downstream tool report the wrong actor. The trailer is only visible to someone who reads the full commit body.Expected
One of:
-c user.name/-c user.emailfrom the resolved agent identity, so authorship lands on the field everything already reads.MOSAIC_GIT_IDENTITY, so nobody else rules that the variable fixes it. Documented-and-deliberate is a legitimate answer; silently-assumed is not.Until then, the
Written-by:trailer is what actually carries authorship, and it should be described that way rather than as a supplement to a field that is expected to be correct.Related
#980—issue-create.shAPI fallback creates issues under a different identity than the caller named. Same family: identity not landing where the caller believes it lands.