Skip to content

fix: speed up lifecycle transitions#9

Closed
aserper wants to merge 1 commit into
jayzeng:mainfrom
aserper:fix/reload-qmd-cache
Closed

fix: speed up lifecycle transitions#9
aserper wants to merge 1 commit into
jayzeng:mainfrom
aserper:fix/reload-qmd-cache

Conversation

@aserper

@aserper aserper commented Apr 29, 2026

Copy link
Copy Markdown
Contributor

Summary

  • cache qmd availability and collection checks for 5 minutes to avoid repeated subprocess work during reloads
  • skip exit summary generation on lifecycle transitions by default (/reload, /new, /resume, /fork)
  • add PI_MEMORY_SUMMARIZE_TRANSITIONS=1 opt-in for users who prefer summaries during those transitions
  • add a regression test for qmd status/collection caching and transition-summary config

Validation

  • npm run build
  • npm run lint
  • npx tsx test/qmd-cache.ts
  • commit hook also ran npm test: 6 passed, 0 failed, 5 skipped

Context

In local profiling, repeated qmd status and qmd collection list --json calls dominated /reload time. Caching these checks and avoiding summary/qmd-update work on lifecycle transitions keeps reload/new responsive while preserving the old transition-summary behavior behind an env var.

@jayzeng

jayzeng commented May 5, 2026

Copy link
Copy Markdown
Owner

@aserper thanks for the PR, can you resolve the merge conflict?

Signed-off-by: aserper <aserper@users.noreply.github.com>
@aserper aserper force-pushed the fix/reload-qmd-cache branch from 5ad81c1 to 0c9944e Compare May 5, 2026 02:42
@aserper

aserper commented May 5, 2026

Copy link
Copy Markdown
Contributor Author

fixed

@jayzeng

jayzeng commented May 22, 2026

Copy link
Copy Markdown
Owner

I cherry picked your changes and resolved the merge conflicts, PR here: #16

@jayzeng jayzeng closed this May 22, 2026
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.

2 participants