Skip to content

docs(may-agent): 20-rust-runtime-scaffold — crate structure, traits, prior art#18

Open
Fearvox wants to merge 7 commits into
mainfrom
sleep-iter-13-rust-scaffold
Open

docs(may-agent): 20-rust-runtime-scaffold — crate structure, traits, prior art#18
Fearvox wants to merge 7 commits into
mainfrom
sleep-iter-13-rust-scaffold

Conversation

@Fearvox
Copy link
Copy Markdown
Owner

@Fearvox Fearvox commented May 13, 2026

Summary

  • 305 lines, 9 sections, full crate map (5 crates in workspace)
  • 4 async traits: AgentHandle, ToolDispatcher, Sandbox, MemoryClient
  • Prior art analysis: Tauri (desktop shell), tokio (async runtime), Burn (ML), candle (inference)
  • Build pipeline commands + risk assessment matrix (5 risks)
  • Sprint 1 file creation list (6 files)

Test plan

  • All Rust trait signatures are valid syntax
  • Crate map matches 10-architecture.md component diagram
  • Prior art references resolve to real repos

🤖 Generated with Claude Code

Fearvox and others added 7 commits May 13, 2026 01:25
…lack mirror sync

Adds two issue templates under .github/ISSUE_TEMPLATE/ for long-lived,
auditable mirrors of in-flight upstream PRs:

- pr_tracker.yml: general PR mirror (scope, evidence, decision log, closure)
- security_tracker.yml: high-priority variant (CWE, severity, reachability,
  verification, disclosure hygiene)

Both carry a `pr-mirror` label so the Linear evermind-dash project and the
Slack #bots channel can subscribe by label. Bilingual EN + 中文.
…tream

Runs every 6 hours via cron + manual workflow_dispatch.
- Rebases fork main onto upstream/main (preserves fork-only commits like
  the issue templates)
- Force-pushes with --force-with-lease for safety
- Opens a tracking issue on conflict instead of failing silently

Uses default GITHUB_TOKEN — no PAT needed since we only push to fork.
Triggers on issues.opened and issues.labeled. When pr-mirror label is
present, creates a corresponding Linear issue in the EverMind-Dash
project via Linear GraphQL API. Comments back on GitHub with the
EVE-id link.

Idempotency: skips if a '🔗 Linear:' marker comment already exists.
Priority: 'urgent' label -> Linear urgent (1); otherwise medium (3).
On API failure: applies 'sync-failed' label for triage.

Requires (configured separately):
  Secret:   LINEAR_API_KEY    (Linear Personal API key, lin_api_*)
  Vars:     LINEAR_TEAM_ID    (EverMind team UUID)
            LINEAR_PROJECT_ID (EverMind-Dash project UUID)
…nnel

Update the disclosure-hygiene checkbox to reference #p-evermind-dash
(the actual Slack channel linked to the EverMind-Dash Linear project)
instead of the placeholder #bots.
…ents

Two compounding fixes to avoid creating multiple Linear issues from a
single GitHub issue creation:

1. concurrency group keyed on issue.number with cancel-in-progress=false
   serializes runs per issue. Second run will see the first run's
   comment and skip via existing idempotency check.

2. Tighten 'labeled' event filter to only fire when the added label is
   pr-mirror itself, not any other label. Eliminates the four extra
   runs that gh issue create --label A --label B ... triggers (one
   issues.opened + four issues.labeled = 5 events for a 4-label create).

Reproduction: gh issue create with 4 labels including pr-mirror was
firing the workflow 5 times concurrently. Idempotency check has a
~5s race window before the first run posts its bot comment, so 2-3
runs created duplicate Linear issues before the rest skipped.

Verified via Issue #4 sync producing both EVE-3 and EVE-4.
Adds the fork overnight patrol workflow, Linear-aware tracking issue creation, and docs guard support for coming-soon use-case placeholders. Verified with local script checks and passing Docs CI.
…prior art

305 lines, 9 sections. Full crate map (5 crates). 4 async traits:
AgentHandle, ToolDispatcher, Sandbox, MemoryClient. Prior art analysis:
Tauri (desktop), tokio (async), Burn (ML), candle (inference). Bash
pipeline commands.
Risk assessment matrix (5 risks).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@Fearvox Fearvox added pr-mirror Long-lived mirror of an upstream PR for Linear/Slack tracking tracking Issue tracks a long-lived workflow labels May 13, 2026
@Fearvox Fearvox marked this pull request as ready for review May 20, 2026 13:14
Copilot AI review requested due to automatic review settings May 20, 2026 13:14
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

VERDICT: FLAG
VERDICT_SUMMARY: Adds fork-maintenance automation (overnight watch + upstream sync) and new tracking templates/docs.
Main risk is automation idempotency/interop with Linear markers and missing alerting on non-rebase failures.
Next action: align Linear marker conventions + ensure sync-upstream opens an issue (or otherwise signals) on push/other failures.
EVIDENCE:
- .github/scripts/overnight-watch.mjs:222-225,283-286 uses "Linear:" marker/check instead of repo convention "🔗 Linear:" used by .github/workflows/linear-sync.yml:33-43,119-124.
- .github/workflows/sync-upstream.yml:46-52 only files an issue on rebase conflict; push failures (e.g., force-with-lease rejection) won’t create a tracking issue.

Documentation/planning update for a Rust runtime scaffold plus new GitHub automation and templates to keep the fork auditable (overnight watch, upstream sync, Linear mirroring, tracker templates). Also adjusts docs CI to tolerate “Coming soon” use-case cards.

Changes:

  • Add overnight fork watch workflow + Node script, plus supporting documentation.
  • Add scheduled fork sync-from-upstream workflow and Linear sync workflow for mirrored tracking issues.
  • Add PR/security tracking issue templates; tweak docs workflow banner-link validation.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
docs/fork-playground/overnight-watch.md Documents the overnight watch behavior, labels, and manual run instructions.
.planning/may-agent/20-rust-runtime-scaffold.md Draft design doc for a future Rust runtime workspace/crate layout and core async traits.
.github/workflows/sync-upstream.yml Scheduled/manual upstream rebase-and-push sync for the fork.
.github/workflows/overnight-watch.yml Scheduled/manual workflow runner for the overnight watch script.
.github/workflows/linear-sync.yml Mirrors pr-mirror GitHub issues into Linear with an idempotency marker comment.
.github/workflows/docs.yml Skips banner-link validation for “Coming soon” use-case cells.
.github/scripts/overnight-watch.mjs Implements drift/workflow/PR monitoring and creates/updates a tracking issue + optional Linear mirror.
.github/ISSUE_TEMPLATE/security_tracker.yml Adds a security mirror/tracker issue form with evidence + closure criteria.
.github/ISSUE_TEMPLATE/pr_tracker.yml Adds a PR mirror/tracker issue form with evidence + closure criteria.

Comment on lines +222 to +225
function issueHasLinearMarker(issueNumber) {
const comments = ghJson(`/repos/${repoSlug}/issues/${issueNumber}/comments?per_page=100`);
return comments.some((comment) => comment.body.includes("Linear:"));
}
Comment on lines +283 to +286
const linearIssue = data.data.issueCreate.issue;
const marker = `Linear: [${linearIssue.identifier}](${linearIssue.url})\n\n_Auto-created by overnight-watch._`;
run("gh", ["issue", "comment", String(issueNumber), "--repo", repoSlug, "--body", marker]);
}
Comment on lines +46 to +52
- name: Push to fork main
if: steps.rebase.outputs.conflict == 'false'
run: git push origin main --force-with-lease

- name: Open issue on conflict
if: failure() && steps.rebase.outputs.conflict == 'true'
uses: actions/github-script@v7
Comment on lines +58 to +60
title: `[sync] Rebase conflict syncing fork from upstream (${new Date().toISOString().slice(0,10)})`,
body: `Auto-sync from \`upstream/main\` failed due to rebase conflicts.\n\nRun id: ${context.runId}\nWorkflow: ${context.workflow}\n\nResolve manually:\n\n\`\`\`\ncd ~/EverOS && git fetch upstream && git rebase upstream/main\n# resolve conflicts, then:\ngit push origin main --force-with-lease\n\`\`\``,
labels: ['tracking']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-mirror Long-lived mirror of an upstream PR for Linear/Slack tracking tracking Issue tracks a long-lived workflow

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants