[GH-ISSUE #674] Shell hangs if recording is ended while paused. #344

Closed
opened 2026-02-25 20:33:22 +03:00 by kerem · 9 comments
Owner

Originally created by @rcorre on GitHub (Feb 15, 2025).
Original GitHub issue: https://github.com/asciinema/asciinema/issues/674

Describe the bug
If you quit the recording while paused, the shell hangs. It seems to recover eventually, but it takes a while.

To Reproduce
Steps to reproduce the behavior:

  1. bash --noprofile --norc
  2. asciinema rec /dev/null
  3. <ctrl-\>
  4. <ctrl-d>

Expected behavior
A clear and concise description of what you expected to happen.

The recording can be ended while paused.

Versions:

  • OS: Linux 6.13.2-arch1-1
  • asciinema cli: asciinema 3.0.0-rc.3

Additional context
Add any other context about the problem here.

Originally created by @rcorre on GitHub (Feb 15, 2025). Original GitHub issue: https://github.com/asciinema/asciinema/issues/674 **Describe the bug** If you quit the recording while paused, the shell hangs. It seems to recover eventually, but it takes a while. **To Reproduce** Steps to reproduce the behavior: 1. bash --noprofile --norc 2. asciinema rec /dev/null 3. `<ctrl-\>` 4. `<ctrl-d>` **Expected behavior** A clear and concise description of what you expected to happen. The recording can be ended while paused. **Versions:** - OS: Linux 6.13.2-arch1-1 - asciinema cli: asciinema 3.0.0-rc.3 **Additional context** Add any other context about the problem here.
kerem closed this issue 2026-02-25 20:33:22 +03:00
Author
Owner

@ku1ik commented on GitHub (Feb 16, 2025):

Ooh, that's a good catch! Hopefully something easy to fix.

<!-- gh-comment-id:2661313560 --> @ku1ik commented on GitHub (Feb 16, 2025): Ooh, that's a good catch! Hopefully something easy to fix.
Author
Owner

@ku1ik commented on GitHub (Feb 24, 2025):

I tried your repro steps but can't reproduce it, it works fine me. I checked on the 3.0.0-rc.3 commit and on the latest develop. Not quite sure what's going on.

<!-- gh-comment-id:2679438811 --> @ku1ik commented on GitHub (Feb 24, 2025): I tried your repro steps but can't reproduce it, it works fine me. I checked on the 3.0.0-rc.3 commit and on the latest develop. Not quite sure what's going on.
Author
Owner

@ku1ik commented on GitHub (Feb 24, 2025):

What terminal and Linux distro does this happen for you on?

<!-- gh-comment-id:2679674382 --> @ku1ik commented on GitHub (Feb 24, 2025): What terminal and Linux distro does this happen for you on?
Author
Owner

@rcorre commented on GitHub (Feb 25, 2025):

Archlinux, my terminal is foot version: 1.20.2-107-gc63202ee (Feb 10 2025, branch 'master') +pgo +ime +graphemes +toplevel-icon +system-bell -assertions

<!-- gh-comment-id:2681731334 --> @rcorre commented on GitHub (Feb 25, 2025): Archlinux, my terminal is `foot version: 1.20.2-107-gc63202ee (Feb 10 2025, branch 'master') +pgo +ime +graphemes +toplevel-icon +system-bell -assertions`
Author
Owner

@rcorre commented on GitHub (Feb 25, 2025):

Ah, I figured it out. On my desktop, it worked fine, and I noticed I was getting desktop notifications about the paused recording. My laptop didn't have a notification server installed. I installed dunst and now asciinema no longer hangs.

<!-- gh-comment-id:2681745601 --> @rcorre commented on GitHub (Feb 25, 2025): Ah, I figured it out. On my desktop, it worked fine, and I noticed I was getting desktop notifications about the paused recording. My laptop didn't have a notification server installed. I installed `dunst` and now asciinema no longer hangs.
Author
Owner

@rcorre commented on GitHub (Feb 25, 2025):

Though strangely, if I uninstall dunst on my destkop, notify-send exits immediately with an error. On my laptop, notify-send just hangs. I'm not sure what the difference is yet.

<!-- gh-comment-id:2681777725 --> @rcorre commented on GitHub (Feb 25, 2025): Though strangely, if I uninstall `dunst` on my destkop, `notify-send` exits immediately with an error. On my laptop, `notify-send` just hangs. I'm not sure what the difference is yet.
Author
Owner

@rcorre commented on GitHub (Feb 25, 2025):

Seems similar to https://bbs.archlinux.org/viewtopic.php?id=228142. My laptop had xdg-desktop-portal-kde, which was catching the notification requests and hanging.
I suppose asciinema could handle a command hanging more gracefully, but maybe it's not worth the effort given this was a misconfiguration on my part and/or a bug in a notification daemon.

<!-- gh-comment-id:2681788016 --> @rcorre commented on GitHub (Feb 25, 2025): Seems similar to https://bbs.archlinux.org/viewtopic.php?id=228142. My laptop had `xdg-desktop-portal-kde`, which was catching the notification requests and hanging. I suppose `asciinema` could handle a command hanging more gracefully, but maybe it's not worth the effort given this was a misconfiguration on my part and/or a bug in a notification daemon.
Author
Owner

@ku1ik commented on GitHub (Feb 25, 2025):

Ooh, that would explain things. Thanks for digging into this. I'll see if there's some easy way to make asciinema immune to such misconfigurations.

<!-- gh-comment-id:2681796095 --> @ku1ik commented on GitHub (Feb 25, 2025): Ooh, that would explain things. Thanks for digging into this. I'll see if there's some easy way to make asciinema immune to such misconfigurations.
Author
Owner

@ku1ik commented on GitHub (Jun 20, 2025):

This has been fixed in caf0cf3707

<!-- gh-comment-id:2992068035 --> @ku1ik commented on GitHub (Jun 20, 2025): This has been fixed in caf0cf3707fff9a840b19449914fb48f05a5b9b1
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/asciinema#344
No description provided.