Skip to content

perf(index): integrate post-#721 catch-up delta into #707 - #733

Merged
ScriptedAlchemy merged 25 commits into
codex/tracedecay-total-redesign-plan-reopenedfrom
codex/integrate-post721-707-20260826-a1
Aug 26, 2026
Merged

perf(index): integrate post-#721 catch-up delta into #707#733
ScriptedAlchemy merged 25 commits into
codex/tracedecay-total-redesign-plan-reopenedfrom
codex/integrate-post721-707-20260826-a1

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Summary

Concurrent with the #728-into-#707 integration. Re-fetch/remerge #707 after that PR lands if the histories diverge.

Test plan

  • format, compile of tracedecay + graph/runtime/usecase/code-index packages, commit-graph and patch-equivalence audits (Codex)
  • behavioral filters: scheduler / session-runtime / graph-db / runtime-core / usecases / code-index (--all-features, isolated target)
  • CI on this PR

@changeset-bot

changeset-bot Bot commented Aug 26, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 3b1baae

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ScriptedAlchemy

Copy link
Copy Markdown
Owner Author

Published from Codex worktree /tmp/tracedecay-integrate-post721-707-a1 at merge 3b1baaee82 so the post-#721 catch-up delta is reviewable. Concurrent with #732; Git merge-tree of the two heads is clean. Re-fetch #707 after #732 lands if you want a single follow-up merge commit.

@ScriptedAlchemy

Copy link
Copy Markdown
Owner Author

Retriggering pull_request CI; reopening immediately.

@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: 3b1baaee82

ℹ️ 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".

Comment on lines +313 to +317
let sessions = match ProjectSessionRetirementOwnerV1::from_ready(sessions) {
Ok(sessions) => sessions,
Err(sessions) => {
let reason = sessions.graph_unavailable_reason();
owners.sessions = Some(sessions);

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 Retire sessions even when graph attachment failed

When the background relation-graph open settles to Detached—for example, after the corrupt .grafeo case added in this commit—from_ready returns the owner here, and this branch reinserts it and returns an error. Project eviction and remote deletion both call retire_project_session_relation_graph, but the completed open task will never change this detached state, so every retry fails and the relational database can never be retired; handle detached owners with a database-only retirement path as the memory-graph code does.

AGENTS.md reference: AGENTS.md:L156-L158

Useful? React with 👍 / 👎.

Comment on lines +2731 to +2733
self.project_owners
.wait_for_session_graph(project_id)
.await?;

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 Cancel graph startup before waiting for capacity retirement

If session relation-graph startup is slow or stuck, this unbounded wait blocks retire_project_session_relation_graph; the project-capacity reuse path awaits that retirement before admitting another project. The startup task is already retained with cancellation authority and a stored task key, so retirement should cancel/join it instead of waiting indefinitely for background graph work to settle.

AGENTS.md reference: AGENTS.md:L156-L158

Useful? React with 👍 / 👎.

Comment on lines +1224 to +1228
.tool_activity_publish_running
.compare_exchange(false, true, Ordering::AcqRel, Ordering::Acquire)
.is_err()
{
return;

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 Preserve activity events while a publish is in flight

Whenever one detached activity write is still running—especially while the session-store writer is busy—every concurrent tool call hits this failed compare-exchange and returns without recording or accumulating its unit. A burst can therefore be persisted as a single call, permanently undercounting dashboard activity and usage data; retain a pending count or coalesce those calls into the next published pulse rather than dropping them.

Useful? React with 👍 / 👎.

@ScriptedAlchemy

Copy link
Copy Markdown
Owner Author

Behind-the-scenes remake is ready; not merged, and your /tmp/tracedecay-integrate-post721-707-a1 tree was not touched.

cursor/remake-post721-after-728 @ bedd28e4ca is a conflict-free merge of current #707 (f191a79b27, includes landed #728 + search-eval clippy borrow + host-admission test-helpers gate) onto this PR’s 3b1baaee82.

That also clears this PR’s Clippy fail (unnecessary_to_owned in tracedecay-search-eval-direct.rs). Adopt when you want:

git fetch origin cursor/remake-post721-after-728
git merge --ff-only origin/cursor/remake-post721-after-728

or merge the branch into this head. I will not land #733.

@ScriptedAlchemy
ScriptedAlchemy merged commit cb2d3dc into codex/tracedecay-total-redesign-plan-reopened Aug 26, 2026
1 check passed
ScriptedAlchemy added a commit that referenced this pull request Aug 28, 2026
Nest Unbound|Unavailable or-patterns, collapse the nested hint/witness
and session-drain ifs, and box the large Attached graph-owner payload
so clippy::all matches what #733 CI already failed on.
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