Skip to content

Design branch publication - #248

Merged
nishu-builder merged 1 commit into
codex/git-fetch-by-hash-20260918-911f8baefrom
codex/publish-design-20260917-911f8bae
Sep 18, 2026
Merged

nishu-builder merged 1 commit into
codex/git-fetch-by-hash-20260918-911f8baefrom
codex/publish-design-20260917-911f8bae

Conversation

@nishu-builder

@nishu-builder nishu-builder commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

Describe branch publication through POST /git/push, caos push-git and publish_source. Define the remote URL, pinned commit, destination branch and required expected head. The endpoint performs one leased create or fast-forward; source policy, import/merge/rebase and reconciliation belong to llm-step.

Clarify Git's refs/heads prefix, the absence of a force-push option, lost acknowledgements and Git's own HTTP retry. Document exact-commit publication and the current .gitignore limitation in agent source capture. PR and stack workflows are added later in #254.

Validation on EC2: Nix build passed. The salted suite passed 46/47 checks in 395s; its Clippy findings were fixed, and Clippy passed on all affected crates with --all-targets -- -D warnings. Formatting passed after those lint-only fixes. HTTPS import/push, shallow-locator/offline-cache, and focused unit checks also passed. The functional suite was not repeated for the lint-only changes.

@nishu-builder nishu-builder left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Layer 1/8. I read the whole stack against this document; the implementation PRs follow it closely, and the places where they diverge are noted on those PRs. Three things I would tighten in the text itself, since it is the contract the others cite:

  1. Step 6 lacks a "definitely rejected" outcome. The endpoint's outcomes are converged / conflict / uncertain, but a receiver can answer with a definite refusal (branch protection, read-only token, archived repo) while leaving the branch at E. Under the rules as written that is "uncertain, inspect before continuing", and inspection cannot resolve it because an unchanged branch is not evidence. The implementation in #250 inherits exactly this gap. Adding "a receiver-reported rejection is a conflict with a reason, not an uncertainty" here gives #250 a target.

  2. "Concurrent attempts use the same recorded intent" needs to say whether they may all SEND. #252 reads it as observe-only for the non-winning attempt, which produces a wrong Uncertain receipt when the winner's push then lands (details on that PR). Since the push is idempotent under the exact lease, "every attempt that holds the pinned intent may send it" is the safer reading and is what the code comment there already claims.

  3. The locator cost change is not mentioned. #249 removes --depth 1 from :@@= resolution so the client never becomes shallow, which means every locator fetch (including the cloud install's --llm-step:@@=github:…) now pulls full history. design/flake-inputs.md still describes single-commit granularity as the point of pinning a commit. Either this document or that one should own the trade-off and the alternative (shallow-fetch into a throwaway repo, copy only the tree closure).

Smaller: the "Interfaces and compatibility" section says the TUI's publication commands are removed, but #247 only removes the TUI layer; the host-side push and gh engine in caos-cli (publication.rs, source_trees::prepare_publication/publish_target, host_git::find_or_open_source_tree_pr_in) is left in place with only its tests calling it. Worth saying here whether that stays as a fallback or is meant to go.


Generated by Claude Code

@nishu-builder
nishu-builder force-pushed the codex/publish-design-20260917-911f8bae branch from cd6d15e to 9480525 Compare September 18, 2026 00:03
Comment thread design/agent-publish.md Outdated
Comment thread design/agent-publish.md Outdated
Comment thread design/agent-publish.md Outdated
Comment thread design/agent-publish.md Outdated
@nishu-builder
nishu-builder force-pushed the codex/publish-design-20260917-911f8bae branch from 9480525 to e7a2bc3 Compare September 18, 2026 00:48
@nishu-builder
nishu-builder removed this pull request from stack #255 September 18, 2026 07:50
@nishu-builder
nishu-builder added this pull request to stack #257 September 18, 2026 07:51
@nishu-builder
nishu-builder force-pushed the codex/publish-design-20260917-911f8bae branch from e7a2bc3 to 7f407e9 Compare September 18, 2026 10:52
@nishu-builder
nishu-builder removed this pull request from stack #257 September 18, 2026 10:52
@nishu-builder
nishu-builder changed the base branch from main to codex/git-fetch-by-hash-20260918-911f8bae September 18, 2026 10:52
@nishu-builder
nishu-builder added this pull request to stack #257 September 18, 2026 10:52
@nishu-builder
nishu-builder removed this pull request from stack #257 September 18, 2026 10:53
@nishu-builder
nishu-builder added this pull request to stack #261 September 18, 2026 10:53
@nishu-builder
nishu-builder force-pushed the codex/publish-design-20260917-911f8bae branch from 7f407e9 to 9c96d10 Compare September 18, 2026 19:52
@nishu-builder
nishu-builder merged commit 16f778b into main Sep 18, 2026
2 checks passed
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.

1 participant