Skip to content

Let Host-Scoped secrets_sync Buckets Hold the Same Home-Relative Title - #4250

Merged
ptr727 merged 4 commits into
developfrom
feature/host-buckets-4249
Nov 17, 2026
Merged

ptr727 merged 4 commits into
developfrom
feature/host-buckets-4249

Conversation

@ptr727

@ptr727 ptr727 commented Nov 17, 2026

Copy link
Copy Markdown
Owner

Closes #4249

A bucket named host-<name> is host-scoped in scripts/secrets_sync.py.

  • A push to a host-* bucket skips the other host-* buckets in the shared-title check. Each host can keep its own copy of a file with the same path on every host.
  • A title in a bucket not named host-* still collides with every bucket, host buckets included, in both directions. This holds for push and for pull and status selection.
  • pull refuses two host-* buckets in one run, naming both.
  • status does not report a title held by several host buckets as a conflict.
  • scripts/README.md states the rule. The restore scripts pass buckets straight to pull, so they need no change.

Tests: five new cases in tests/test_secrets_sync.py (push across two host buckets, host/shared collision in each direction, pull refusal of two host buckets, host/shared collision in a pull, status with several host buckets). The secrets_sync file went from 156 to 161 tests, and the full suite ran 4474 tests OK (4469 before).

Local strict review: two passes recorded. The first found one stale README sentence about archiving before a move, fixed in the second commit. The second pass found nothing.

🤖 Generated with Claude Code

ptr727 and others added 2 commits November 16, 2026 19:22
A bucket named host-<name> is host-scoped. A push to one skips the other
host-* buckets in the shared-title check, a title in a non-host bucket still
collides with every bucket in both directions, and pull refuses two host-*
buckets in one run, naming both.

Closes #4249

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Copilot AI lite review requested due to automatic review settings November 17, 2026 03:33
@ptr727

ptr727 commented Nov 17, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head 861c14cc2b8df663f58369650113c3e0095fd2be, the content this pull request carries at that commit against develop, and it recorded 0 findings.

@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

An active moderate issue remains because an empty host name in BUCKET can bypass shared-title collision checks and the pull restriction.

1 open issue
What changed in this PR

This pull request updates secrets_sync so host-scoped buckets can share home-relative titles while preserving collision protection against shared buckets.

Changes:

  • Adds host-aware title collision checks for push, pull, and status selection.
  • Refuses pulls that select multiple host-scoped buckets.
  • Adds regression coverage and documents the host-scoped bucket rules.
  • Identifies that the empty host- bucket name is incorrectly treated as host-scoped.
File Description
tests/​test_secrets_sync.py Adds regression tests covering host-bucket sharing, host/shared collisions, multi-host pull refusal, and status behavior.
scripts/​secrets_sync.py Implements host-scoped title collision rules and prevents pulls from selecting multiple host buckets.
scripts/​README.md Documents host-scoped bucket naming, collision semantics, and selection restrictions.

Review effort: Lite

Comment thread scripts/secrets_sync.py Resolved
@codecov

codecov Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.05%. Comparing base (b38e084) to head (b720bbd).
⚠️ Report is 234 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #4250      +/-   ##
===========================================
- Coverage    81.60%   78.05%   -3.56%     
===========================================
  Files           26       42      +16     
  Lines         9070    15398    +6328     
===========================================
+ Hits          7402    12019    +4617     
- Misses        1668     3379    +1711     
Flag Coverage Δ
python-3.13 78.05% <100.00%> (-3.56%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ptr727

ptr727 commented Nov 17, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@ptr727

ptr727 commented Nov 17, 2026

Copy link
Copy Markdown
Owner Author

/review

@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@ptr727

ptr727 commented Nov 17, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head b720bbd56608cf98a61bace9ce5a8a8d15996c68, the content this pull request carries at that commit against develop, and it recorded 0 findings.

@ptr727
ptr727 merged commit ef1c121 into develop Nov 17, 2026
13 checks passed
@ptr727
ptr727 deleted the feature/host-buckets-4249 branch November 17, 2026 14:21
ptr727 added a commit that referenced this pull request Nov 17, 2026
…trap Secret Restore (#4255)

## Summary

Promotes `develop` to `main`. It carries nine changes:

- [#4247](#4247): retires
the `CLAUDE.md` pointer file, the second half of #4074. The hub's copy
and its `spec/files.json` entry are gone, and a `retire` gap records
why. The audit now reports a retired path the hub no longer tracks. A
copy matching a past hub revision is reported for deletion, and any
other copy is reported for the maintainer. It merged on the maintainer's
go-ahead after reading its diff, which touches
`host-setup/agent-safety/README.md`.
- [#4256](#4256): that
match compares line endings alone, so a retired copy differing in an
action pin or a `needs:` list goes to the maintainer. It answers a
Copilot finding on this promotion.
- [#4260](#4260): the
audit run stamp names the commits it read. HEAD carries `-dirty` where
the read paths differ from it, and `main <sha>` is added where the
fetched `main` differs.
- [#4259](#4259):
`pr-review-conduct` states the `pr_review.py` spelling rule once for
every call a fleet skill prints. Under a restricted uv cache, a merge or
a branch delete is reported to the maintainer as a blocked write.
- [#4261](#4261):
`validate-task.yml` takes a `test-matrix-file` input, read through the
same validation as `test-matrix`.
- [#4257](#4257): the
pre-commit snippet says to exclude `hub_fetch_run.py` from a
repository's own ruff with `force-exclude = true`. The short-form
`AUDIT.md` snippet drops its two hub-audit authority sentences.
- [#4246](#4246):
`bootstrap.sh --secrets` and `bootstrap.ps1 -Secrets` restore named
secret buckets, on their own or as a step of a `--host` or `--dev`
stand-up.
- [#4250](#4250): `host-*`
buckets in `scripts/secrets_sync.py` may each hold the same
home-relative title.
- [#4258](#4258): a dry
run with no 1Password account is refused rather than enrolling one, and
the root-refused secrets tests skip on a root runner. It answers two
CodeRabbit findings on this promotion.

Hosts already carry the load-both setting the retirement relies on, from
the 2.0.1483 kit.

Closes #4074
Closes #4236
Closes #4238
Closes #4239
Closes #4242
Closes #4243
Closes #4248
Closes #4249

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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.

2 participants