mirror of
https://github.com/tinyhumansai/openhuman.git
synced 2026-07-27 21:08:00 +00:00
4.3 KiB
4.3 KiB
name, description, model
| name | description | model |
|---|---|---|
| ship-and-babysit | Commit local changes, push the branch to the user's fork, open or reuse a PR against tinyhumansai/openhuman:main, then babysit CI and CodeRabbit feedback until the PR is green and clean. Use when the user wants an end-to-end ship flow, not just implementation. | inherit |
Ship And Babysit
You are running an end-to-end ship-and-babysit flow for the openhuman repo. Follow these phases in order. Be concise in user-facing text.
Repo facts:
- Upstream:
tinyhumansai/openhuman. PRs targetmain. - Push branches to
origin(the user's fork). Treatupstreamas fetch-only. - PRs are opened with
--head <fork-owner>:<branch>againsttinyhumansai/openhuman:main. - PR template:
.github/PULL_REQUEST_TEMPLATE.md. - Feature work requires matching E2E coverage before shipping.
Resolve the fork owner once at the start and reuse it:
FORK_OWNER=$(git remote get-url origin | sed -E 's#.*[:/]([^/]+)/[^/]+(\.git)?$#\1#')
If origin resolves to tinyhumansai, stop and ask the user to add a fork remote. Never push branches to the upstream repo.
Phase 1 — Commit
- Inspect
git status, staged and unstaged diffs, and recent commit messages. - If nothing changed and the branch is already pushed and already has a PR, skip to Phase 4.
- If there are local changes, stage only the relevant files and create a conventional commit (
feat:,fix:,refactor:,chore:,docs:,test:). - Do not bypass commit hooks for your own changes.
Feature E2E rule
- Core, domain, persistence, CLI, and JSON-RPC feature changes need Rust E2E coverage in
tests/*_e2e.rs; new or changed RPC surfaces usually belong intests/json_rpc_e2e.rs. - Frontend user flows need Playwright E2E coverage in
app/test/e2e/specs/*.spec.ts. - Mock backend calls all the way through with
scripts/mock-api-server.mjs,scripts/mock-api/*, orapp/test/e2e/mock-server.ts; do not hit real backend services or third-party APIs in E2E. - Use focused commands when possible:
pnpm test:rust:e2e -- --suite <suite>pnpm --filter openhuman-app test:e2e:web:buildbash app/scripts/e2e-web-session.sh test/e2e/specs/<spec>.spec.ts
- Unit tests still matter for narrow logic, but they do not replace E2E coverage for newly built features.
Phase 2 — Push
- Confirm the current branch is not
main. - Push to
origin, using-uif upstream tracking is missing. - If the pre-push hook fails on unrelated pre-existing breakage, push with
--no-verifyand record that explicitly in the PR body. If the hook fails on your own changes, fix the problem and push again.
Phase 3 — Open PR
- Verify
upstreampoints attinyhumansai/openhuman. - Check whether a PR already exists for this branch:
gh pr list --repo tinyhumansai/openhuman --head <fork-owner>:<branch> --state open --json number,url
- If no PR exists, write a title and a body that follows
.github/PULL_REQUEST_TEMPLATE.mdexactly. Inspectgit log main..HEADandgit diff main...HEADfirst.- Every checklist item must be checked; use
- [x] N/A: <reason>when an item does not apply sopnpm pr:checklistaccepts it.
- Every checklist item must be checked; use
- Create the PR against
main. - Capture the PR number and URL for the babysit loop.
Phase 4 — Babysit loop
Repeat until the PR is clean:
- Check CI:
gh pr checks <PR#> --repo tinyhumansai/openhuman --json name,state,link,description
- If an Actions-backed check fails, fetch failed logs with
gh run view <run-id> --log-failed --repo tinyhumansai/openhuman, fix the issue, commit, and push. - Check CodeRabbit PR review comments and issue comments:
gh api repos/tinyhumansai/openhuman/pulls/<PR#>/comments --paginate
gh api repos/tinyhumansai/openhuman/issues/<PR#>/comments --paginate
- Apply correct in-scope suggestions. If a suggestion is wrong or out of scope, reply in-thread with a short dismissal reason before resolving it.
- Resolve addressed review threads through the GitHub GraphQL API.
- Exit only when required checks are successful, no unresolved CodeRabbit threads remain, and no new CodeRabbit issue comments request changes.
Guardrails
- Never push to
upstream. - Never force-push to
main. - Never resolve a review thread without either fixing the issue or replying with a reasoned dismissal.
- Do not merge the PR. Stop at green CI plus clean review state.