Skip to content

feat: add trust workflow and async deep-audit - #6

Open
devjusty wants to merge 2 commits into
mainfrom
feature/trust-deep-pr
Open

feat: add trust workflow and async deep-audit#6
devjusty wants to merge 2 commits into
mainfrom
feature/trust-deep-pr

Conversation

@devjusty

Copy link
Copy Markdown
Owner

Summary

  • add canonical trust envelope and warning endpoints, plus consistency evaluation and warning status updates
  • add async deep-audit job lifecycle APIs and migrate sitemap scan hook to queue-and-poll behavior
  • add Domains workspace UI for trust status, warning remediation, deep-audit initiation, and scan-triggered trust sync

Verification

  • pnpm --filter frontend test
  • pnpm --filter wp-json-discovery-server test

@devjusty

Copy link
Copy Markdown
Owner Author

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 066d5cb75b

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".


const envelopeId = envelopeResponse?.envelope?.envelopeId;
if (envelopeId) {
const knownCatalogNamespaces = data.plugins.matched.flatMap(({ namespaces }) => namespaces ?? []);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Include core namespaces when evaluating trust mismatches

evaluateTrustEnvelope compares findings.namespaces against catalog.namespaces, but this call only passes namespaces from matched plugins. Since data.namespaces includes core namespaces like wp/v2 and oembed/1.0, normal scans will emit SCAN_CATALOG_MISMATCH warnings even when nothing is wrong, causing trust status to stay in a warning state and generating noisy remediation work.

Useful? React with 👍 / 👎.

Comment thread server/src/index.js
Comment on lines +653 to +656
await updateDeepAuditJobState(jobId, {
status: 'running',
startedAt: new Date().toISOString(),
});

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Guard deep-audit state transition with error handling

The initial updateDeepAuditJobState(...running...) runs before the try/catch, so a transient DB failure here rejects out of the timer callback and is never converted to a terminal job state. In that case the job can remain queued forever, and clients polling for completed/failed/capped will keep waiting indefinitely.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant