DeepSeek-Reasonix
DeepSeek-Reasonix copied to clipboard
fix(desktop): keep project history topics out of blank reuse
Summary
- Fix #5097 by checking the target desktop session directory before reusing an indexed blank project topic.
- Keep project topics that already have saved sessions from being reset/reused as
新的会话when another new session is created. - Add regression coverage for the project-topic/session case that previously reproduced the sidebar history corruption.
Verification
cd desktop && go test . -run 'TestEnsureBlankTab|TestNewSessionNoopsWhenCurrentTabIsBlank' -count=1git diff --checkgofmt -l desktop/tabs.go desktop/app_session_dedup_test.gogo vet ./...cd desktop && go vet ./...go test ./...cd desktop && go test ./...
Cache impact
Cache-impact: none. This is limited to desktop sidebar topic/session reuse and does not change provider-visible prompts, memory prefix, tool schemas, tool ordering, request serialization, compaction, or MCP/tool registration.
Cache-guard: cd desktop && go test . -run 'TestEnsureBlankTab|TestNewSessionNoopsWhenCurrentTabIsBlank' -count=1
System-prompt-review: N/A
Fixes #5097