Conversation
Prevents stale CSP headers after npm package updates and prepares release 0.1.5.
There was a problem hiding this comment.
Pull request overview
Promotes the previously reviewed dev changes for Keiko 0.1.5 into main, including the UI stale-process restart behavior and strengthened package-surface validation around CSP hashes.
Changes:
- Bump root + UI package versions (and related test fixtures) from
0.1.4to0.1.5. - Update
keiko startlifecycle behavior to probe/api/healthand restart a stale running UI when the reported version differs (or health is unusable). - Extend the package-surface gate to verify
dist/ui/csp-hashes.jsonmatches inline scripts present indist/ui/static/**/*.html.
Reviewed changes
Copilot reviewed 18 out of 20 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| ui/package.json | UI package version bump to 0.1.5. |
| ui/package-lock.json | UI lockfile version bump to 0.1.5. |
| package.json | Root package version bump to 0.1.5. |
| package-lock.json | Root lockfile version bump to 0.1.5. |
| src/sdk/index.ts | Single-sourced SDK version constant bumped to 0.1.5. |
| src/harness/session.ts | Harness version constant bumped to 0.1.5. |
| src/cli/lifecycle.ts | Adds health probing + stale-process restart logic keyed off SDK_VERSION. |
| scripts/check-package-surface.mjs | Adds CSP hash vs static HTML inline-script consistency check. |
| tests/cli/lifecycle.test.ts | Adds coverage for “keep running when versions match” and “restart when stale”. |
| tests/ui/read-handlers.test.ts | Updates evidence fixtures’ harnessVersion to 0.1.5. |
| tests/harness/sinks.test.ts | Updates manifest fixture harnessVersion to 0.1.5. |
| tests/harness/fingerprint.test.ts | Updates fingerprint fixture harnessVersion to 0.1.5. |
| tests/cli/verify.test.ts | Updates test package version fixture to 0.1.5. |
| tests/cli/evidence.test.ts | Updates evidence manifest fixture harnessVersion to 0.1.5. |
| tests/audit/retention.test.ts | Updates audit manifest fixture harnessVersion to 0.1.5. |
| tests/audit/report.test.ts | Updates audit manifest fixture harnessVersion to 0.1.5. |
| tests/audit/persist.test.ts | Updates audit build input fixture harnessVersion to 0.1.5. |
| tests/audit/integration.test.ts | Updates audit integration fixture harnessVersion to 0.1.5. |
| tests/audit/index-api.test.ts | Updates audit API fixture harnessVersion to 0.1.5. |
| tests/audit/build.test.ts | Updates audit build fixtures’ harnessVersion to 0.1.5. |
Files not reviewed (1)
- ui/package-lock.json: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+43
to
+46
| function readJsonArray(path) { | ||
| const parsed = JSON.parse(readFileSync(path, "utf8")); | ||
| return Array.isArray(parsed) ? parsed : []; | ||
| } |
Comment on lines
+48
to
+51
| function assertCspHashesMatchStaticHtml() { | ||
| const staticRoot = join("dist", "ui", "static"); | ||
| const htmlFiles = collectHtmlFiles(staticRoot); | ||
| const expected = extractInlineScriptHashes(htmlFiles.map((file) => readFileSync(file, "utf8"))); |
Comment on lines
+207
to
+209
| if (!response.ok) { | ||
| return { reachable: false, version: undefined }; | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Promotes the checked
devrelease fix for Keiko0.1.5tomain.Refs: n/a - release integration.
Scope
devintomainfor release0.1.5.devcommit.Product Impact
Verification
Required:
Local verification:
Select only what applies:
prepackand npm tarball update simulation.Not applicable rationale:
Review And Closure
Resolves #<issue_number>only when this PR should close the issue.Risk Notes
Release integration only. Branch
devis the reviewed source of truth for this promotion.