Skip to content

Record asciicast v2 input and marker events#716

Draft
Copilot wants to merge 9 commits into
masterfrom
copilot/handle-asciicast-v2-events
Draft

Record asciicast v2 input and marker events#716
Copilot wants to merge 9 commits into
masterfrom
copilot/handle-asciicast-v2-events

Conversation

Copilot AI commented Jan 24, 2026

Copy link
Copy Markdown
Contributor

sshpiper only emitted asciicast v2 output events, so input and marker events from SSH sessions were lost. This PR records downstream input and marks exec commands as marker events for better fidelity with the v2 spec.

  • Asciicast event coverage
    • Capture downstream channel data as i (input) events.
    • Emit m (marker) events on exec requests with the command text.
  • Parser robustness
    • Add error handling for request parsing to avoid silent truncation.
  • Focused tests
    • Add unit tests that validate input and marker events are written into the cast files.

Example output event emitted:

[0.042,"i","ls -la\n"]

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • docs.asciinema.org
    • Triggering command: /home/REDACTED/work/_temp/ghcca-node/node/bin/node /home/REDACTED/work/_temp/ghcca-node/node/bin/node --enable-source-maps /home/REDACTED/work/_temp/copilot-developer-action-main/dist/index.js (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

This section details on the original issue you should resolve

<issue_title>feature: handle asciicast v2 input and marker event codes</issue_title>
<issue_description>sshpiper does not handle recording input or markers event types as per the asciicast > v2 event spec. All commands are logged as o / output instead of recording user input?

Is this a bug or a feature or the SSH session?

See the asciicast v2 event code spec:

https://docs.asciinema.org/manual/asciicast/v2/#supported-event-codes</issue_description>

<agent_instructions>please first verify if the request is valid</agent_instructions>

Comments on the Issue (you are @copilot in this section)

@tg123 sshpiper record the `result` from upstream only, so everything was treated as output

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 7 commits January 24, 2026 07:04
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Co-authored-by: tg123 <170430+tg123@users.noreply.github.com>
Copilot AI changed the title [WIP] Add support for asciicast v2 input and marker event codes Record asciicast v2 input and marker events Jan 24, 2026
Copilot AI requested a review from tg123 January 24, 2026 07:13
@tg123

tg123 commented Jun 8, 2026

Copy link
Copy Markdown
Owner

@copilot resolve the merge conflicts in this pull request

Copilot AI commented Jun 8, 2026

Copy link
Copy Markdown
Contributor Author

@copilot resolve the merge conflicts in this pull request

Resolved the merge conflicts with master in 2128fe3:

  • go.sum (root module): regenerated from master; go mod tidy produces no diff.
  • Semantic conflict: master added typescript.go which also declared msgChannelData = 94. Removed the duplicate from asciicast.go and reused the existing constant.
  • crypto submodule: adopted master's rebased pointer (8bc8da3e).

cmd/sshpiperd builds, vets, and passes tests (including the asciicast input/marker tests).

Copilot finished work on behalf of tg123 June 8, 2026 18:32
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.

feature: handle asciicast v2 input and marker event codes

2 participants