coderifts 4.11.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +59 -0
- package/LICENSE +21 -0
- package/dist/cli.js +114006 -96673
- package/package.json +2 -2
- package/scripts/assert-guard-major.js +145 -63
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,64 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## Unreleased
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
- **P0 — `setup-required-check --apply` no longer reports `APPLIED` over a
|
|
7
|
+
configuration `enforce --check` rejects.** The 4.12.0 round bound the required
|
|
8
|
+
check to an issuer only on the branch where branch protection **already
|
|
9
|
+
exists**. When the protection fetch returned 404 the CREATE branch built its
|
|
10
|
+
own payload — `{ strict: false, contexts: ["CodeRifts / contract-gate"] }`,
|
|
11
|
+
the issuer-less legacy array — and the read-back reported `APPLIED` with exit
|
|
12
|
+
0, while `enforce --check` graded the same repository
|
|
13
|
+
`legacy_contexts_no_issuer_binding`. Both branches now use one payload
|
|
14
|
+
builder, so the create write carries the same `checks[]` / `app_id` binding as
|
|
15
|
+
the update write.
|
|
16
|
+
- **The read-back runs the enforcement verifier.** `APPLIED` previously meant
|
|
17
|
+
the context *name* appeared in `required_status_checks`, which is the grade
|
|
18
|
+
`enforce --check` refuses. It now means `evaluateRequiredCheck` — the same
|
|
19
|
+
function that grades enforcement — returned `VERIFIED`. `--json` gains
|
|
20
|
+
`verified_status`, `verified_reason_code` and, on failure,
|
|
21
|
+
`verified_reason`; an unverifiable apply exits 1 as `VERIFY_FAILED`.
|
|
22
|
+
- **Repository rulesets are graded, not merely named.** `RULESET_REQUIRED` used
|
|
23
|
+
to be reported for any ruleset mentioning the check context. A ruleset with no
|
|
24
|
+
`integration_id` is satisfiable by any issuer, and one with
|
|
25
|
+
`enforcement: "evaluate"` is a dry run that reports without blocking; both
|
|
26
|
+
produced a green exit 0. They are now `NOT_VERIFIED`
|
|
27
|
+
(`ruleset_no_issuer_binding` / `ruleset_evaluate_mode`) and the command
|
|
28
|
+
proceeds to offer the classic-protection apply. `--json` gains
|
|
29
|
+
`ruleset_status`, `ruleset_reason_code` and `ruleset_names_by_name_only`.
|
|
30
|
+
Rulesets that could not be read are `UNVERIFIABLE`, never "none".
|
|
31
|
+
|
|
32
|
+
### Changed
|
|
33
|
+
- **BREAKING for adopters on the STRICT template — `require-grant: 'true'`.**
|
|
34
|
+
`coderifts init --agents --strict` now writes `require-grant: 'true'` for
|
|
35
|
+
contract-gate ≥0.5.0, so the merge gate BLOCKS unless every changed governed
|
|
36
|
+
path is covered by a valid `cr.exec.v1` execution grant. Before this, the
|
|
37
|
+
guard demanded a grant in strict mode and the strict workflow demanded
|
|
38
|
+
verified monitoring, while the gate that actually blocks let a grant-less
|
|
39
|
+
change through.
|
|
40
|
+
|
|
41
|
+
**What breaks:** a repository already using the strict template starts failing
|
|
42
|
+
any pull request that changes a governed contract path
|
|
43
|
+
(openapi/graphql/grpc/asyncapi/mcp-manifest) and carries no valid grant, with
|
|
44
|
+
`grant_not_supplied`. A pull request that changes no contract artifact is
|
|
45
|
+
unaffected — the gate short-circuits earlier as `no_contract_changes`. So the
|
|
46
|
+
affected set is not "some PRs": it is every PR this gate actually evaluates.
|
|
47
|
+
|
|
48
|
+
**What you must do:** publish a grant for the change set through the
|
|
49
|
+
`CODERIFTS_EXECUTION_GRANT` repository variable the template reads, or remove
|
|
50
|
+
the three `require-grant` / `execution-grant` / `grant-operation` lines from
|
|
51
|
+
your workflow. A `cr.exec.v1` grant binds `operation ∥ target_id ∥
|
|
52
|
+
after_payload`, and `after_payload` is the after-content of the changed
|
|
53
|
+
governed files — so a variable pinned once covers exactly one diff and fails
|
|
54
|
+
every other PR as `grant_does_not_cover_path`. Treat the variable as a
|
|
55
|
+
delivery slot to populate per change set, not a set-and-forget value.
|
|
56
|
+
|
|
57
|
+
Re-running `init` does not rewrite an existing workflow file, so this reaches
|
|
58
|
+
a repository only when the file is regenerated. The default (non-strict)
|
|
59
|
+
template is unchanged and stays non-blocking; it carries the same three lines
|
|
60
|
+
commented, with a note saying why the two differ.
|
|
61
|
+
|
|
3
62
|
## 4.10.0
|
|
4
63
|
|
|
5
64
|
### Added
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 CodeRifts
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|