Skip to content

fix: support legacy Cursor CSV exports#16

Merged
Miss-you merged 1 commit into
mainfrom
you-9-cursor-csv-normalization
Mar 16, 2026
Merged

fix: support legacy Cursor CSV exports#16
Miss-you merged 1 commit into
mainfrom
you-9-cursor-csv-normalization

Conversation

@Miss-you

Copy link
Copy Markdown
Owner

Summary

  • make the Cursor parser accept legacy dashboard CSV exports that omit the Kind column while keeping the existing token-field mapping intact
  • add parser coverage for blank token cells, RFC3339 timestamp variants, invalid-file fallback, and deterministic multi-file ordering
  • keep Cursor normalization scoped to OpenSpec tasks 1.1 to 1.3 for YOU-9

Validation

  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache go test ./provider/cursor -count=1
  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache make fmt
  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache make vet
  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache make test
  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache make build
  • ./bin/codetok daily --all --cursor-dir /Users/apple/Documents/Github/symphony-workspaces/YOU-9/e2e/testdata/cursor --claude-dir <empty-dir> --codex-dir <empty-dir> --kimi-dir <empty-dir>
  • env GOCACHE=/tmp/codetok-gocache GOMODCACHE=/tmp/codetok-gomodcache make lint (repo Makefile skipped because golangci-lint is not installed in this environment)

Notes

  • review subagent invocation was attempted per ticket guidance, but the subagent session was interrupted before returning findings; the final local diff review found no concrete issues in the minimal parser change set.

Copilot AI review requested due to automatic review settings March 16, 2026 04:06

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.

Pull request overview

This PR updates the Cursor CSV usage parser to accept legacy exports that omit the Kind column, while expanding test coverage for additional parsing edge-cases and deterministic session ordering across multiple files.

Changes:

  • Relax Cursor CSV header validation by no longer requiring the Kind column.
  • Add parser tests for legacy exports (no Kind), blank token cells, RFC3339 timestamp variants, and deterministic multi-file collection with invalid-file skipping.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
provider/cursor/parser.go Makes Kind optional by removing it from the required header set.
provider/cursor/parser_test.go Adds coverage for legacy exports, token blank handling, timestamp formats, and deterministic ordering while skipping invalid CSVs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Miss-you
Miss-you merged commit 7f31222 into main Mar 16, 2026
11 checks passed
@Miss-you
Miss-you deleted the you-9-cursor-csv-normalization branch March 16, 2026 06:14
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