You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit df083ca
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+12-2Lines changed: 12 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ virtual environment. `mise tasks` lists every task. The ones you need most:
16
16
| Task | What it does |
17
17
|------|--------------|
18
18
|`mise run ci`| Everything CI runs: checks, unit tests, build |
19
-
|`mise run check`| Format check, lint, type check, proto check, conformance check |
19
+
|`mise run check`| Format check, lint, type check, proto check, vendored-file check |
20
20
|`mise run format`| Format the code |
21
21
|`mise run test`| Unit tests; `UV_PYTHON=3.11` picks the interpreter |
22
22
|`mise run build`| Build the wheel and sdist, verify them, and install them on Python 3.11 |
@@ -63,9 +63,19 @@ generated files; change the pin and run `mise run proto:gen`.
63
63
Building a wheel or sdist needs neither a core checkout nor network access because the generated bindings are committed. A change to the core pin makes the generated API changes visible in the diff.
64
64
65
65
Shared test fixtures come from core's `sdk/conformance/` and are copied into
66
-
`tests/fixtures/`. `mise run conformance:check` compares them with core at the
66
+
`tests/fixtures/`. `mise run vendored:check` compares them with core at the
67
67
pinned ref.
68
68
69
+
## Core bumps and drift
70
+
71
+
Automation watches core for new tags and opens a pull request that moves the
72
+
pin, labeled `core-bump` plus `stable` or `prerelease`. If a bump needs SDK
73
+
changes, push them to the same branch.
74
+
75
+
A nightly job checks core's `main` for breaking proto changes and RPCs the SDK
76
+
doesn't cover yet, and keeps one issue labeled `core-drift` up to date. See
77
+
[scripts/README.md](scripts/README.md) for how both work.
78
+
69
79
## Releases
70
80
71
81
SDK releases follow core releases: SDK `X.Y.Z` is built from core `vX.Y.Z`, and
The workflows under `.github/workflows/` run these scripts, most through a mise task, so each job can be run locally first. Scripts that write to GitHub take `--dry-run` and print what they would do instead.
4
+
5
+
## `core-sync/`: keeping up with core
6
+
7
+
Move the core pin (`OPENSHELL_CORE_REF` in `mise.toml`) to new core releases, and watch core `main` for changes that will break the SDK.
8
+
9
+
The workflows use a GitHub App token from the `sdk-bot` environment (secrets `SDK_BOT_CLIENT_ID` and `SDK_BOT_PRIVATE_KEY`), which only `main` can deploy to. They never use `GITHUB_TOKEN`, because pushes and PRs made with it don't trigger CI.
10
+
11
+
| File | mise task | Purpose |
12
+
|------|-----------|---------|
13
+
|`core-tags.sh [--all]`|`core:tags`| List NVIDIA/OpenShell release tags newer than the pin: every stable tag, plus the newest pre-release when it is newer than all of them. |
14
+
|`open-bump-pr.sh <tag> [--dry-run]`|`core:bump`| Open the update proposal for one core tag: branch `core/<tag>`, pin change, regenerated bindings, refreshed copies of core files, proto diff in the body, labels `core-bump` plus `stable` or `prerelease`. Closes older pre-release proposals. |
15
+
|`bump-pr-body.md`|| PR body template for `open-bump-pr.sh`. |
16
+
|`drift-check.sh --out <file>`|`core:drift`| Compare core `main` with the pin: `buf breaking`, regenerate and run the unit tests, list the RPCs the SDK doesn't call. Writes the markdown report. |
17
+
|`update-drift-issue.sh <report.md> [--dry-run]`|`core:drift-issue`| Create, update, or close the single `Core main drift` issue from a report. |
18
+
|`report-failure.sh <job> <run-url> [--dry-run]`|`core:report-failure`| Append a dated failure line to the drift issue. Called from `if: failure()` steps. |
19
+
|`drift-issue.sh`|| Shared helpers for the two drift issue scripts (sourced, not run). |
20
+
21
+
| Workflow | Runs (mise tasks) |
22
+
|----------|------|
23
+
|`core-watch.yml` (hourly) |`core:tags`, then `core:bump` per tag |
24
+
|`core-drift.yml` (nightly) |`core:drift`, then `core:drift-issue`|
25
+
26
+
Bump PRs run E2E against their own pin, because `e2e.yml` defaults to `OPENSHELL_CORE_REF` on the PR branch.
27
+
28
+
## `e2e/`: the E2E gateway
29
+
30
+
| File | Purpose |
31
+
|------|---------|
32
+
|`start-gateway.sh <core-version>`| Run the published gateway of a core version with the Docker driver for the E2E lane, and register it as `e2e`. |
33
+
|`stop-gateway.sh`| Stop it, collect its log, and remove its sandboxes. |
34
+
35
+
`e2e.yml` (reusable, called from `ci.yml`) runs `start-gateway.sh`, `mise run e2e`, then `stop-gateway.sh`.
36
+
37
+
## Build and checks
38
+
39
+
| File | mise task | Purpose |
40
+
|------|-----------|---------|
41
+
|`generate_python_proto.py`|`proto:gen`| Generate `src/openshell/_proto` from `proto/`. |
42
+
|`verify-python-wheel.py`|`build`| Check the wheel's contents and version. |
43
+
|`vendored-core-files.txt`|`vendored:check`| Files copied from core. `vendored:check` compares them with core at the pin; `core-sync/open-bump-pr.sh` refreshes them. |
44
+
|`fetch-core.sh <ref> <dir> <path>...`|`vendored:check`| Copy files from core at a ref. |
0 commit comments