Repository navigation
docs(rules): sync the code-comments copy with its canonical block - #378
Merged
Merged
Conversation
The block carries a marker saying it is synced from claude-workflow/docs/code-comments.md, and it had stopped being. The canonical file gained the `shortcut:` convention in sydevs/claude-workflow#231 and none of the four copies followed, so this repo's always-loaded rule neither tells an agent to write a `shortcut:` marker nor lists one among the comments never to delete — while implement-ticket's ladder writes them and comment-protect.json's K5 protects them. `src/components/organisms/Mapbox/markers.ts:191` already carries one. Two refinements of rules already here come from the same file: a comment must stand on its own with its link cut, and the razor now names what to cut. comment-rule-sync.mjs reported this as SOURCE DRIFT and exits 0 across all four copies with this change. The carve-outs below the marker are untouched. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Mg9rjW3DwBN3M1yYVD4M8T
Contributor
Author
|
🤖 no session running Written by the sydevs dispatcher. Sessions never edit this comment. |
sydevs-bot
marked this pull request as ready for review
November 9, 2026 08:24
sydevs-bot
enabled auto-merge
November 9, 2026 08:24
Contributor
Author
|
Adversarial review skipped: 1 file(s), 23 changed line(s), under 🤖 sydevs dispatcher |
This was referenced Nov 9, 2026
Ardnived
approved these changes
Nov 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
claude-workflow/docs/code-comments.mdinto this repo's copy, which had fallen behind it.shortcut:convention — how to write one, and that one is never to be deleted.One of four identical PRs, one per repo that carries a copy. Found by the
audit-contractssweep (2026-11-09).Preview
Markdown only, in
docs/rules/— nothing deploys and neither Cloudflare preview shows anything this PR did.Contract impact
docs/rules/code-comments.mdis a copy of a cross-repo contract, not a document this repo owns.claude-workflow/docs/code-comments.mdis the source;workflow/lib/comment-rule-sync.mjsis what compares them. The three sibling PRs carry the byte-identical block:sydevs/SahajCloudsydevs/WeMeditateWebsydevs/SahajAtlasWordpressThey can merge in any order. The sync check passes only once all four are in, because it requires the four copies to agree with each other as well as with the source.
Test results
.claude/skills/pr-prep/check.sh— lint, typecheck, 1965 unit tests in 165 files, 92snode workflow/lib/comment-rule-sync.mjsin the five-repo workspace — 4 ok, exits 0 (it reportedSOURCE DRIFTbefore)Manual verification
Notes for reviewer
claude-workflow#231added theshortcut:rule to the canonical file and tocomment-protect.json, and no copy was updated. So all four copies currently agree with each other and disagree with their source, which is whycomment-rule-sync.mjsnames itSOURCE DRIFTrather thanDRIFTED.## The rulesection rather than only theshortcut:lines, so the marker's promise ("synced from … Edit there, not here") is true again and the next drift is one diff. That pulled in two wording refinements of rules already present. Taking only theshortcut:pair is a defensible smaller change.maineither; the new prose is hand-wrapped to the file's own ~100-column width.Detail
The live exposure in this repo is one marker,
src/components/organisms/Mapbox/markers.ts:191.src/styles/host-reset.test.ts:16matches the string but is prose ("not a shortcut:"), not a marker. So the cost of the drift here is mostly forward-looking: an agent steering by this file has not been told the convention exists, andaudit-code's comments angle reads this file as the rule.comment-fingerprint.mjscounts protected comments before and after a sweep, so a marker deleted in a bulk comment pass would still be caught mechanically. That narrows the blast radius of the drift; it does not fix the rule.Generated by Claude Code