Skip to content

fix(learn): name the scan scope in the zero-session message - #4329

Open
amandeavor wants to merge 1 commit into
rtk-ai:developfrom
amandeavor:fix/learn-zero-session-scope
Open

amandeavor wants to merge 1 commit into
rtk-ai:developfrom
amandeavor:fix/learn-zero-session-scope

Conversation

@amandeavor

Copy link
Copy Markdown
Contributor

Summary

  • Carry ScanScope in rtk learn the same way rtk discover does after fix(discover): distinguish zero-session scans #3374.
  • Share a zero_session_message helper so narrowed scopes name the filter or encoded cwd and point at rtk learn --all.
  • Keep the --all empty-scan wording (any project / no --all hint).

Fixes #4314

Test plan

  • cargo test --bin rtk zero_session (Rust 1.91) — existing discover zero-session tests plus helper coverage for the learn command name
  • cargo fmt --all && cargo clippy --all-targets && cargo test

Copilot AI lite review requested due to automatic review settings September 28, 2026 03:15

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@rtk-wshm-sync-bot

Copy link
Copy Markdown

wshm · Automated triage by AI

📊 Automated PR Analysis

🐛 Type bug-fix
🟡 Risk medium

Summary

Fixes the zero-session message for rtk learn to name the scan scope (filter or encoded cwd) and point users at rtk learn --all, reusing the same ScanScope/zero_session_message helper introduced for rtk discover. The diff also includes unrelated fixes: avoiding a doubled 'pip pip' label in pip command output/errors, and adding run duration to the pytest summary output.

Review Checklist

  • Tests present
  • Breaking change
  • Docs updated

Linked issues: #4314


Analyzed automatically by wshm · This is an automated analysis, not a human review.

@amandeavor
amandeavor force-pushed the fix/learn-zero-session-scope branch 3 times, most recently from 2dcf44a to afa650f Compare October 23, 2026 15:31
learn defaulted every empty scan to "No Claude Code sessions found in
the last N days", even when the miss was a cwd or -p filter. discover
already carries ScanScope after rtk-ai#3374; reuse that enum via a shared
zero_session_message helper and print the matching hint with
`rtk learn --all` for the two narrowed scopes.

Fixes rtk-ai#4314
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

learn: zero-session message blames the time window whatever the scope

2 participants