Skip to content

1.0.15: session resume (no args) returns the caller's own session over stdio (regression from 1.0.14) #152

Description

@escott-

Summary

On the published @contextstream/mcp-server@1.0.15 (npm latest / GitHub v1.0.15), session(action="resume") with no resume_id / session_id returns the caller's own current session when run over local stdio, after the session has done real work. The same flow on published 1.0.14 correctly returns the previous session. The 1.0.15 changelog says resume now leaves out the session init just opened, so this looks like a regression for stdio clients.

Environment

  • contextstream-mcp 1.0.15 installed from npm (npm i @contextstream/mcp-server@1.0.15), linux-x86_64, stdio transport (binary launched directly, MCP JSON-RPC over stdin/stdout)
  • Authenticated with an individual (elite) test account via CONTEXTSTREAM_API_KEY
  • Comparison binary: published 1.0.14 from npm, same machine, same account, same folder

Steps to reproduce

In one fresh stdio process, with a unique marker TAG per run:

  1. initialize + notifications/initialized
  2. init with folder_path=<project dir>
  3. context with user_message="resume self-exclusion probe <TAG>"
  4. session with action="capture", event_type="note", title="resume probe <TAG>"
  5. session with action="resume_list"
  6. session with action="resume" (no resume_id, no session_id)

Expected

Step 6 returns the previous session (the last run), not the one making the call.

Actual (1.0.15)

Step 6 returns the current session. Two runs on 2026-10-05 ~2:58pm PT:

  • Run tagged A145823: Resume (no card yet; rebuilt from transcript): session ae5629b4 ... with Recent requests: - resume self-exclusion probe A145823 (its own request)
  • Run tagged B145845: ... session d697d301 ... with Recent requests: - resume self-exclusion probe B145845 (its own request)
  • A third 1.0.15 run was consistent (returned a snapshot captured during that same run).

resume_list reports No resume cards yet (workspace). in every run.

1.0.14 comparison (same flow, interleaved runs)

  • 1.0.14 run right after run B returned session d697d301 / probe B145845, i.e. the previous session, as expected.
  • Earlier today (~11:58am PT) three 1.0.14 stdio runs of this flow also returned the previous session every time.

Notes

  • init in 1.0.15 doesn't print a session id, so a stdio caller has no id to pass as session_id to work around it.
  • PR chore(release): prepare MCP 1.0.16 #151 (1.0.16 prep) covers the stateless hosted-gateway path (init prints the id, resume notes when no id was passed). It's not clear whether it also fixes the stateful stdio path shown here, so please check this flow before 1.0.16 publishes.
  • Hunch, not verified: 1.0.15 now excludes the API-assigned id ahead of the local init id, and transcripts/snapshots for stdio sessions may be stored under an id that's no longer the one excluded.

Found during a production smoke of the published 1.0.15 package.

Activity

  1. escott- commented on Oct 6, 2026

    @escott-
    MemberAuthor

    Still reproduces on the published 1.0.16 (npm latest / GitHub v1.0.16, contextstream-mcp 1.0.16, Built 2026-10-05), linux-x86_64, stdio, same account and folder. Checked 2026-10-05 ~10:32–10:35pm PT.

    No-arg resume, same steps as above:

    • Run A223246: resume returned session e1858b61 with Recent requests: - resume self-exclusion probe A223246 (its own request).
    • Run B223308: resume returned session 9c34970a, Unresolved self-exclusion probe request B223308 (its own snapshot).

    With the id 1.0.16's init now prints (Session id: <id>. To resume the previous session, call session(action="resume", session_id="<id>")):

    • Run C223339: init printed fa8ead90-…. session(action="resume", session_id="fa8ead90-…") still returned the caller's own session, session 43132d3b, Recent requests: - resume withid probe C223339. No-arg resume in the same process returned the same thing.
    • So over stdio the id init prints doesn't match the id the run's transcript/snapshot is stored under (43132d3b…), and passing it doesn't exclude the current session. The documented workaround doesn't help stdio callers.
    • I didn't see the "no id was passed" note in the no-arg resume text over stdio, and there was no structuredContent on the resume results.

    1.0.14 control right after run C (published 1.0.14, same flow, no args): returned session 43132d3b / resume withid probe C223339, which is the previous session, as expected.

    So the stdio regression from 1.0.15 is still there in 1.0.16. Main's 3241462 (resume hint in the structured result, staged for 1.0.17 in #154) looks aimed at the hosted Claude Code path. Please check this stdio flow against the 1.0.17 build before it publishes.

  2. escott- commented on Oct 6, 2026

    @escott-
    MemberAuthor

    Still reproduces on the published 1.0.17 (npm latest / GitHub v1.0.17, tag commit 3fe78356, contextstream-mcp 1.0.17, Built 2026-10-06), linux-x86_64, stdio, installed with scripts/mcp.sh (checksum matches). Checked 2026-10-06 ~9:53–9:54am PT.

    No-arg resume (init, context, capture, resume_list, resume):

    • Run A095316: resume returned session 72603319 with Recent requests: - resume self-exclusion probe A095316 (its own request).
    • Run B095339 (new process, ~20s later): resume returned session 1ae14fc4 with - resume self-exclusion probe B095339 (its own again, not A's).

    With the id init prints:

    • Run C095402: init printed Session id: d445e2c2-…. session(action="resume", session_id="d445e2c2-…") returned session 8667eca5 / resume withid probe C095402 (the caller's own session). No-arg resume in the same process returned the same.

    There's still no structuredContent on any stdio resume result, and resume_list returns "No resume cards yet (project)." So the 1.0.17 change that moves the resume hint into the structured result doesn't change what stdio callers get back. Same results as on 1.0.15 and 1.0.16.

  3. escott- commented on Oct 7, 2026

    @escott-
    MemberAuthor

    Still reproduces over stdio on the published 1.0.18 (npm latest / GitHub v1.0.18, tag commit 3c048360, contextstream-mcp 1.0.18, Built 2026-10-07), linux-x86_64, installed with scripts/mcp.sh (checksum matches). The hosted gateway (also reporting 1.0.18) handles the same flow correctly. Checked 2026-10-07 ~10:04–10:08am PT, same account, workspace Testing, one new project folder.

    stdio, no-arg resume (init, context, capture, resume_list, resume):

    • Run A100441: resume returned session fca245ac with Recent requests: - resume self-exclusion probe A100441 (its own request).
    • Run B100504 (new process, ~20s later): resume returned session 6f7f9713 (rebuilt from snapshot), Resume self-exclusion probe B100504 (its own again, not A's).

    stdio, with the id init prints:

    • Run C100526: init printed Session id: bd830f25-…. session(action="resume", session_id="bd830f25-…") returned session f1741ee5 / resume withid probe C100526 (the caller's own session). No-arg resume in the same process returned the same.
    • Still no structuredContent on any stdio resume result.

    Hosted HTTP (https://mcp.contextstream.io/mcp?default_context_mode=fast, the headers setup --editors claude writes to .mcp.json), same steps:

    • Run H1100623: init printed 1abed299-…. resume with that id and with no args both returned session f1741ee5 / resume withid probe C100526, the previous session. structuredContent was present.
    • Run H2100701: init printed 437ec7c5-…. resume with that id and with no args both returned session 1abed299 / hosted resume probe H1100623, the previous session again.

    So on hosted the transcript is stored under the id init prints (H2 got back 1abed299, which was H1's init id) and self-exclusion works. Over stdio the stored id differs from what init prints (bd830f25 vs f1741ee5), so the guidance 1.0.18 adds to the tool text and rules ("pass the id init returned") doesn't help stdio callers. resume_list returns "No resume cards yet (project)." on both transports.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions