claude-code-sessions 0.16.4__tar.gz → 0.16.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/PKG-INFO +17 -1
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/README.md +16 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/PKG-INFO +17 -1
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/SOURCES.txt +1 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.py +46 -13
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions_gui.py +574 -120
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_converge.py +26 -0
- claude_code_sessions-0.16.5/tests/test_gui_destination.py +486 -0
- claude_code_sessions-0.16.5/tests/test_gui_env_rebuild.py +377 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_retitle.py +32 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_sync.py +218 -0
- claude_code_sessions-0.16.4/tests/test_gui_destination.py +0 -249
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/LICENSE +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/dependency_links.txt +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/entry_points.txt +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/top_level.txt +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/pyproject.toml +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/setup.cfg +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_alignment.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_anonymize.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_cli.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_commands.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_containment.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_data_root.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_discovery.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_duplicate_transcripts.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_encoding.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_engine.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_golden.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_gui_models.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_helpers.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_journal.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_journal_reroot.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_plan_move.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_recover.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_rows.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_scaffold.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_transcripts.py +0 -0
- {claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/tests/test_undo.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: claude-code-sessions
|
|
3
|
-
Version: 0.16.
|
|
3
|
+
Version: 0.16.5
|
|
4
4
|
Summary: Unofficial tool for Claude Code sessions on disk: make a session visible under your other Claude account on the same machine, or move one between project folders. Command line or GUI. Journaled, reversible, fails closed.
|
|
5
5
|
Author: Craig Stoller
|
|
6
6
|
License: MIT
|
|
@@ -1042,6 +1042,22 @@ window into `journaled`/`completed`/`rolled_back`.
|
|
|
1042
1042
|
destination" keeps the saved value until another is picked, so a cancelled pick loses
|
|
1043
1043
|
nothing, and no plan goes into a different store without a pick. A saved store whose account
|
|
1044
1044
|
is now signed in is named as such, and the candidate holding the saved ids is marked.
|
|
1045
|
+
- **0.16.5 finishes the window's side of the data move, and lets a store path use either
|
|
1046
|
+
slash.** On Windows, `sync --to` and the store-scope `--live` of `sync`, `repoint`, `new-row`
|
|
1047
|
+
and `retitle` compared a store path with its separators as typed, so a path spelled with `/`,
|
|
1048
|
+
which is what Git Bash hands Python for `/c/Users/...`, matched nothing, and a Tab-completed
|
|
1049
|
+
folder's trailing `/` never matched either. Both now fold separators beside the exact test,
|
|
1050
|
+
and a trailing separator may match a store path's end. A `--live` value made only of
|
|
1051
|
+
separators is refused like a blank one; on Windows `--live \` used to certify a sole
|
|
1052
|
+
candidate. In the window, a saved sync destination from before the move is now re-rooted
|
|
1053
|
+
through the same package pairs the journal uses. It is the same store, moved whole by the
|
|
1054
|
+
app, so the window plans into it without asking and saves the new path only after an Apply
|
|
1055
|
+
into it succeeds; 0.16.4 set such a destination aside and asked. The window also builds its
|
|
1056
|
+
view of the stores afresh at every read and before every engine call that writes or plans a
|
|
1057
|
+
write, where it used to build it once when opened. A move made while the window was open had
|
|
1058
|
+
left every route refusing until a restart, or, when the app copied its data instead of moving
|
|
1059
|
+
it, left the window writing into the old copy. A press whose store layout changed since its
|
|
1060
|
+
plan now stops and replans before its next write.
|
|
1045
1061
|
- Platform rows above move from "unverified" to "verified" as contributors confirm the store
|
|
1046
1062
|
paths and behavior on their own machines.
|
|
1047
1063
|
|
|
@@ -1012,6 +1012,22 @@ window into `journaled`/`completed`/`rolled_back`.
|
|
|
1012
1012
|
destination" keeps the saved value until another is picked, so a cancelled pick loses
|
|
1013
1013
|
nothing, and no plan goes into a different store without a pick. A saved store whose account
|
|
1014
1014
|
is now signed in is named as such, and the candidate holding the saved ids is marked.
|
|
1015
|
+
- **0.16.5 finishes the window's side of the data move, and lets a store path use either
|
|
1016
|
+
slash.** On Windows, `sync --to` and the store-scope `--live` of `sync`, `repoint`, `new-row`
|
|
1017
|
+
and `retitle` compared a store path with its separators as typed, so a path spelled with `/`,
|
|
1018
|
+
which is what Git Bash hands Python for `/c/Users/...`, matched nothing, and a Tab-completed
|
|
1019
|
+
folder's trailing `/` never matched either. Both now fold separators beside the exact test,
|
|
1020
|
+
and a trailing separator may match a store path's end. A `--live` value made only of
|
|
1021
|
+
separators is refused like a blank one; on Windows `--live \` used to certify a sole
|
|
1022
|
+
candidate. In the window, a saved sync destination from before the move is now re-rooted
|
|
1023
|
+
through the same package pairs the journal uses. It is the same store, moved whole by the
|
|
1024
|
+
app, so the window plans into it without asking and saves the new path only after an Apply
|
|
1025
|
+
into it succeeds; 0.16.4 set such a destination aside and asked. The window also builds its
|
|
1026
|
+
view of the stores afresh at every read and before every engine call that writes or plans a
|
|
1027
|
+
write, where it used to build it once when opened. A move made while the window was open had
|
|
1028
|
+
left every route refusing until a restart, or, when the app copied its data instead of moving
|
|
1029
|
+
it, left the window writing into the old copy. A press whose store layout changed since its
|
|
1030
|
+
plan now stops and replans before its next write.
|
|
1015
1031
|
- Platform rows above move from "unverified" to "verified" as contributors confirm the store
|
|
1016
1032
|
paths and behavior on their own machines.
|
|
1017
1033
|
|
{claude_code_sessions-0.16.4 → claude_code_sessions-0.16.5}/claude_code_sessions.egg-info/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: claude-code-sessions
|
|
3
|
-
Version: 0.16.
|
|
3
|
+
Version: 0.16.5
|
|
4
4
|
Summary: Unofficial tool for Claude Code sessions on disk: make a session visible under your other Claude account on the same machine, or move one between project folders. Command line or GUI. Journaled, reversible, fails closed.
|
|
5
5
|
Author: Craig Stoller
|
|
6
6
|
License: MIT
|
|
@@ -1042,6 +1042,22 @@ window into `journaled`/`completed`/`rolled_back`.
|
|
|
1042
1042
|
destination" keeps the saved value until another is picked, so a cancelled pick loses
|
|
1043
1043
|
nothing, and no plan goes into a different store without a pick. A saved store whose account
|
|
1044
1044
|
is now signed in is named as such, and the candidate holding the saved ids is marked.
|
|
1045
|
+
- **0.16.5 finishes the window's side of the data move, and lets a store path use either
|
|
1046
|
+
slash.** On Windows, `sync --to` and the store-scope `--live` of `sync`, `repoint`, `new-row`
|
|
1047
|
+
and `retitle` compared a store path with its separators as typed, so a path spelled with `/`,
|
|
1048
|
+
which is what Git Bash hands Python for `/c/Users/...`, matched nothing, and a Tab-completed
|
|
1049
|
+
folder's trailing `/` never matched either. Both now fold separators beside the exact test,
|
|
1050
|
+
and a trailing separator may match a store path's end. A `--live` value made only of
|
|
1051
|
+
separators is refused like a blank one; on Windows `--live \` used to certify a sole
|
|
1052
|
+
candidate. In the window, a saved sync destination from before the move is now re-rooted
|
|
1053
|
+
through the same package pairs the journal uses. It is the same store, moved whole by the
|
|
1054
|
+
app, so the window plans into it without asking and saves the new path only after an Apply
|
|
1055
|
+
into it succeeds; 0.16.4 set such a destination aside and asked. The window also builds its
|
|
1056
|
+
view of the stores afresh at every read and before every engine call that writes or plans a
|
|
1057
|
+
write, where it used to build it once when opened. A move made while the window was open had
|
|
1058
|
+
left every route refusing until a restart, or, when the app copied its data instead of moving
|
|
1059
|
+
it, left the window writing into the old copy. A press whose store layout changed since its
|
|
1060
|
+
plan now stops and replans before its next write.
|
|
1045
1061
|
- Platform rows above move from "unverified" to "verified" as contributors confirm the store
|
|
1046
1062
|
paths and behavior on their own machines.
|
|
1047
1063
|
|
|
@@ -22,7 +22,7 @@ import sys
|
|
|
22
22
|
# only answer worth printing. A hardcoded duplicate in pyproject could disagree
|
|
23
23
|
# with the module after a partial bump, and the disagreement would surface as a
|
|
24
24
|
# user reporting a bug against a version they were not running.
|
|
25
|
-
__version__ = "0.16.
|
|
25
|
+
__version__ = "0.16.5"
|
|
26
26
|
|
|
27
27
|
SCHEME_CURRENT = r"[^A-Za-z0-9]" # app >= ~2026-07-12: underscores also become '-'
|
|
28
28
|
SCHEME_LEGACY = r"[^A-Za-z0-9_]" # before: underscores survived
|
|
@@ -6121,10 +6121,44 @@ def _principal_matches(query, pair, uuid, email, own_dirs):
|
|
|
6121
6121
|
want = _path_match_key(query)
|
|
6122
6122
|
hay = " ".join([uuid, email or ""]
|
|
6123
6123
|
+ [o for _a, o, _p in own_dirs]
|
|
6124
|
-
+ [
|
|
6124
|
+
+ [_path_hay(p, query) for _a, _o, p in own_dirs]).lower()
|
|
6125
6125
|
return want in hay
|
|
6126
6126
|
|
|
6127
6127
|
|
|
6128
|
+
def _path_hay(path, query):
|
|
6129
|
+
"""PATH as a substring test sees it: folded by _path_match_key, then one
|
|
6130
|
+
'/' appended, so a QUERY ending in a separator - the way a Tab-completed
|
|
6131
|
+
folder does, and Git Bash hands one over as 'C:/.../org/' - can match the
|
|
6132
|
+
path's own end, which never carries one. Nothing is stripped from the
|
|
6133
|
+
query: 'Vendor/' must still stop short of 'Vendor-Data'.
|
|
6134
|
+
|
|
6135
|
+
The '/' is withheld when QUERY without its trailing separators is the
|
|
6136
|
+
printed account form. '0003/<org id>/' would otherwise match at the end
|
|
6137
|
+
of a path whose account id merely ENDS in 0003 - the mid-uuid match
|
|
6138
|
+
_pair_query exists to refuse.
|
|
6139
|
+
"""
|
|
6140
|
+
key = _path_match_key(path)
|
|
6141
|
+
if _pair_query(query.rstrip("/\\")) is None:
|
|
6142
|
+
key += "/"
|
|
6143
|
+
return key
|
|
6144
|
+
|
|
6145
|
+
|
|
6146
|
+
def _store_matches(query, c):
|
|
6147
|
+
"""Whether QUERY - a --to or store-scope --live value that is not the
|
|
6148
|
+
printed account form - names the store of Account C.
|
|
6149
|
+
|
|
6150
|
+
Today's test, unchanged: a substring of C's joined account, org, email
|
|
6151
|
+
and path text. Beside it, never in place of it, the path field alone with
|
|
6152
|
+
both sides through _path_match_key, so a store path spelled with the
|
|
6153
|
+
other separator matches too. Being an OR, it can only add stores: a value
|
|
6154
|
+
that named one store still names it, or now matches more and gets the
|
|
6155
|
+
ambiguity refusal that lists them - never a different store, quietly.
|
|
6156
|
+
"""
|
|
6157
|
+
return (query.lower() in (c.account_uuid + " " + c.org_uuid + " " +
|
|
6158
|
+
c.email + " " + c.path).lower()
|
|
6159
|
+
or _path_match_key(query) in _path_hay(c.path, query))
|
|
6160
|
+
|
|
6161
|
+
|
|
6128
6162
|
def _principal_listing(principals):
|
|
6129
6163
|
"""The candidate listing grouped per ACCOUNT, for account-scope --live
|
|
6130
6164
|
refusals: each account's header line (email where known, then id), its
|
|
@@ -6255,13 +6289,16 @@ def _resolve_live_assertion(env, live, dirs, account_scope=False):
|
|
|
6255
6289
|
with one addition: an empty or whitespace-only value is refused
|
|
6256
6290
|
outright - substring containment would make it match every candidate,
|
|
6257
6291
|
which on a one-candidate machine is exactly the bare force flag this
|
|
6258
|
-
design refuses to be.
|
|
6292
|
+
design refuses to be. A value made only of separators is that value in
|
|
6293
|
+
another form: every store path holds one, so '\\' certified a sole
|
|
6294
|
+
candidate on Windows before paths were folded, and '/' would after.
|
|
6259
6295
|
"""
|
|
6260
|
-
if not live.strip():
|
|
6296
|
+
if not live.replace("/", "").replace("\\", "").strip():
|
|
6261
6297
|
raise Refusal(
|
|
6262
6298
|
"--live must name the account - an id, org, store-path or email "
|
|
6263
|
-
"substring. An empty value
|
|
6264
|
-
"bare override this flag refuses
|
|
6299
|
+
"substring. An empty value, or one made only of separators, would "
|
|
6300
|
+
"match every candidate, which is the bare override this flag refuses "
|
|
6301
|
+
"to be.")
|
|
6265
6302
|
dis = _identity_disagreement(env)
|
|
6266
6303
|
if dis is None:
|
|
6267
6304
|
res = live_account(env)
|
|
@@ -6327,9 +6364,7 @@ def _resolve_live_assertion(env, live, dirs, account_scope=False):
|
|
|
6327
6364
|
matched = [c for c in cands
|
|
6328
6365
|
if _pair_matches(pair, c.account_uuid, c.org_uuid)]
|
|
6329
6366
|
else:
|
|
6330
|
-
matched = [c for c in cands if live
|
|
6331
|
-
(c.account_uuid + " " + c.org_uuid + " " + c.email + " " +
|
|
6332
|
-
c.path).lower()]
|
|
6367
|
+
matched = [c for c in cands if _store_matches(live, c)]
|
|
6333
6368
|
if len(matched) > 1:
|
|
6334
6369
|
listing = _candidate_listing((c.account_uuid, c.org_uuid, c.path)
|
|
6335
6370
|
for c in matched)
|
|
@@ -6448,9 +6483,7 @@ def resolve_sync_endpoints(env, to=None, live=None):
|
|
|
6448
6483
|
matched = [c for c in others
|
|
6449
6484
|
if _pair_matches(pair, c.account_uuid, c.org_uuid)]
|
|
6450
6485
|
else:
|
|
6451
|
-
matched = [c for c in others if to
|
|
6452
|
-
(c.account_uuid + " " + c.org_uuid + " " + c.email +
|
|
6453
|
-
" " + c.path).lower()]
|
|
6486
|
+
matched = [c for c in others if _store_matches(to, c)]
|
|
6454
6487
|
if not matched:
|
|
6455
6488
|
raise Refusal("--to {0!r} matched no other account store".format(to))
|
|
6456
6489
|
if len(matched) > 1:
|
|
@@ -9833,7 +9866,7 @@ def _repoint_store(env, flags, what="repoint"):
|
|
|
9833
9866
|
hits = [(a, o, p) for a, o, p in dirs
|
|
9834
9867
|
if want in a.lower() or want in o.lower()
|
|
9835
9868
|
or want in (_email_of(env, a, live) or "").lower()
|
|
9836
|
-
or want_path in
|
|
9869
|
+
or want_path in _path_hay(p, flags.store)]
|
|
9837
9870
|
if not hits:
|
|
9838
9871
|
raise Refusal("--store {0!r} matched no store on this machine:\n{1}"
|
|
9839
9872
|
.format(flags.store, _candidate_listing(dirs)))
|