Skip to content

fix(session): ignore non-object JSON records - #72

Merged
he-yufeng merged 1 commit into
mainfrom
fix/skip-invalid-session-records
Nov 22, 2026
Merged

he-yufeng merged 1 commit into
mainfrom
fix/skip-invalid-session-records

Conversation

@he-yufeng

Copy link
Copy Markdown
Owner

Closes #71.

A file can parse as JSON without being a session record. Check that the top level is an object before either the catalog or the resume path reads its fields. Valid objects and the storage format are unchanged. Nothing is removed from disk.

Five new cases fail on the 0.14.0 source and pass with the guard. The complete local suite is 373 passed, with the live smoke test skipped. Ruff passes. I also built the wheel and installed it in an empty environment: --list-sessions still displays the valid entry beside [], and the installed session loader returns None for the invalid record. No provider was contacted. This PR does not publish a new wheel to PyPI.

@he-yufeng
he-yufeng merged commit 1a3150a into main Nov 22, 2026
14 checks passed
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.

One non-object JSON record makes the session catalog exit

1 participant