Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/security-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
with:
scan-args: |
--format=json
--output=old-results.json
--output-file=old-results.json
--maven-registry=https://maven-central.storage-download.googleapis.com/maven2
--no-resolve
--allow-no-lockfiles
Expand All @@ -99,7 +99,7 @@ jobs:
with:
scan-args: |
--format=json
--output=old-results.json
--output-file=old-results.json
--no-resolve
--allow-no-lockfiles
-r
Expand All @@ -120,7 +120,7 @@ jobs:
with:
scan-args: |
--format=json
--output=new-results.json
--output-file=new-results.json
--maven-registry=https://maven-central.storage-download.googleapis.com/maven2
--no-resolve
--allow-no-lockfiles
Expand All @@ -138,7 +138,7 @@ jobs:
with:
scan-args: |
--format=json
--output=new-results.json
--output-file=new-results.json
--no-resolve
--allow-no-lockfiles
-r
Expand Down Expand Up @@ -191,7 +191,7 @@ jobs:
uses: google/osv-scanner-action/osv-reporter-action@8dc09193bb540e09b23da07ad7e30bd33bf87018 # v2.3.8
with:
scan-args: |
--output=results.sarif
--output-files=sarif:results.sarif
--old=old-results.json
--new=new-results.json
--gh-annotations=true
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ Semantic Versioning where the repository publishes a release.

### Fixed

- Fixed the central OSV v2.3.8 security gate and reporter to use the supported
`--output-file` option, preserving the required base/head result documents
instead of failing the gate at its output-presence check.
- Refused PR Review Merge Scheduler head mutations, `update-branch` and the last-push approval head restamp, whenever the resolved mutation credential is the workflow `GITHUB_TOKEN`. GitHub starts no workflow run for events created with that credential, so the moved head collected no current-head required checks and the PR stayed permanently `BLOCKED` with a `github-actions[bot]` merge commit that no later scheduler run could repair, because the branch was no longer behind. The scheduler now waits with `head_mutation_credential_upgrade` guidance naming `PR_REVIEW_MERGE_TOKEN`, `OPENCODE_APPROVE_TOKEN`, and the OpenCode app token exchange.
- Parsed `opencode.jsonc` as JSONC (stripping `//` and `/* */` comments outside string literals) in the reasoning-effort guard and its contract tests, instead of raw `json.loads`, which rejected the file the moment it carried its first explanatory comment (added for the `contextual-orchestrator` provider block) with `Expecting property name enclosed in double quotes`. Comment markers inside string values, such as the `$schema` URL, are left untouched.
- Download the pinned `uv` 0.12.1 exporter from the official GitHub Releases URL instead of `releases.astral.sh`, which now returns HTTP 403 and blocks org-wide OpenCode `coverage-evidence`. The SHA-256 pin is unchanged. The opener may follow one hop onto `release-assets.githubusercontent.com` or `objects.githubusercontent.com` and still rejects every other host, userinfo, non-HTTPS scheme, and nondefault port (ContextualWisdomLab/.github#1109).
Expand Down
1 change: 1 addition & 0 deletions organization_commercial_readiness_fixtures.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ def __init__(
repositories: list[dict[str, Any]],
snapshots: dict[str, list[RepositorySnapshot | Exception]],
) -> None:
"""Configure deterministic repository snapshots and dispatch records."""
self.repositories = repositories
self.snapshots = snapshots
self.dispatched_repairs: list[tuple[str, str]] = []
Expand Down
3 changes: 2 additions & 1 deletion scripts/ci/organization_commercial_readiness_loop.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ class GitHubClient:
"""Use the GitHub CLI as an authenticated, bounded REST transport."""

def __init__(self, token: str, *, timeout_seconds: int = 60) -> None:
"""Initialize the client with one bounded GitHub credential."""
if not token:
raise GitHubError("GH_TOKEN is required for organization coordination")
self._token = token
Expand Down Expand Up @@ -853,4 +854,4 @@ def main(


if __name__ == "__main__": # pragma: no cover - exercised through main()
raise SystemExit(main())
raise SystemExit(main())
4 changes: 2 additions & 2 deletions scripts/ci/test_strix_quick_gate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1506,8 +1506,8 @@ assert_pr_review_merge_scheduler_uses_github_actions_bot_token() {
assert_file_contains "$workflow_file" "github.event_name == 'pull_request_target' && format('pr-{0}', github.event.pull_request.number)" "scheduler scopes pull_request_target concurrency to the active PR"
assert_file_contains "$workflow_file" "github.event_name == 'workflow_run' && github.event.workflow_run.pull_requests[0].number && format('pr-{0}', github.event.workflow_run.pull_requests[0].number)" "scheduler scopes workflow_run concurrency to the completed review PR"
assert_file_contains "$workflow_file" "github.event_name == 'schedule' && format('schedule-{0}', github.event.schedule)" "scheduler isolates the 15-minute organization sweep from the separate 30-minute scheduled scan"
assert_file_contains "$workflow_file" "github.event_name == 'repository_dispatch' && github.run_id" "scheduler keeps manual queue scans isolated per run"
assert_file_contains "$workflow_file" "cancel-in-progress: \${{ github.event_name == 'pull_request_target' || github.event_name == 'pull_request_review' || github.event_name == 'repository_dispatch' }}" "scheduler cancels stale PR/review/manual queue scans instead of accumulating merge/update attempts"
assert_file_contains "$workflow_file" "github.event_name == 'repository_dispatch' && format('repo-dispatch-{0}', github.repository)" "scheduler isolates manual queue scans by repository without accumulating run-specific groups"
assert_file_contains "$workflow_file" "cancel-in-progress: \${{ github.event_name == 'pull_request_target' || github.event_name == 'pull_request_review' || github.event_name == 'repository_dispatch' ||" "scheduler cancels stale PR/review/manual queue scans instead of accumulating merge/update attempts"
assert_file_contains "$workflow_file" "timeout-minutes: 60" "organization sweep has enough headroom to finish the complete repository walk"
assert_file_contains "$workflow_file" "ORG_SWEEP_TRIGGER_REVIEWS: \${{ github.event_name == 'schedule' ||" "scheduled organization sweeps retry missing current-head OpenCode reviews"
assert_file_contains "$workflow_file" "ORG_SWEEP_ENABLE_AUTO_MERGE: \${{ github.event_name == 'schedule' ||" "scheduled organization sweeps merge approved current heads"
Expand Down
14 changes: 10 additions & 4 deletions tests/test_required_workflow_queue_contract.py
Original file line number Diff line number Diff line change
Expand Up @@ -908,8 +908,12 @@ def test_security_scan_allows_repositories_without_supported_lockfiles() -> None
workflow = workflow_text("security-scan.yml")

assert workflow.count("--allow-no-lockfiles") == 4
assert "--output=old-results.json" in workflow
assert "--output=new-results.json" in workflow
assert "--output-file=old-results.json" in workflow
assert "--output-file=new-results.json" in workflow
assert "--output-files=sarif:results.sarif" in workflow
assert "--output-file=results.sarif" not in workflow
assert "--output=old-results.json" not in workflow
assert "--output=new-results.json" not in workflow
assert "test -s old-results.json" in workflow
assert "test -s new-results.json" in workflow

Expand Down Expand Up @@ -983,8 +987,10 @@ def test_osv_scan_logs_and_retries_without_transitive_resolution_on_resolver_fai
"Retry head OSV without transitive resolution\n if: steps.osv_head.outcome == 'failure'\n continue-on-error: true"
in workflow
)
assert "--output=old-results.json" in workflow
assert "--output=new-results.json" in workflow
assert "--output-file=old-results.json" in workflow
assert "--output-file=new-results.json" in workflow
assert "--output=old-results.json" not in workflow
assert "--output=new-results.json" not in workflow
assert "Print OSV findings being compared" in workflow
assert "OSV {label} scan produced {len(findings)} finding(s)" in workflow

Expand Down
Loading