charmbracelet / charmbracelet/vhs
Screenshot isn't always produced when it's the last command
- Dominant language
- Go
- Stars
- 20.9k
- Forks
- 480
- Avg merge
- 4d 1h
- Merged PRs (30d)
- 2
Description
**Describe the bug**
When nothing comes after a `Screenshot`, vhs seems to skip it *sometimes*.
You can see at 0:14, the `second.png` was not created.
https://github.com/user-attachments/assets/7575257b-f9cb-4527-9b7d-f213be6650a2
**Setup**
- vhs 0.8.0 from nixpkgs
- Zsh, Kitty, NixOS
**To Reproduce**
Run this multiple times:
```elixir
Type "echo some text"
Screenshot first.png
Type "echo some other text"
Screenshot second.png
# Type "end" # If you add a command after, it seems to work everytime
```
Contributor guide
Research direction
Run the provided VHS command repeatedly and confirm that the final Screenshot sometimes fails to create second.png. Trace how Screenshot commands are processed when the tape ends, then verify that the last screenshot is produced reliably across repeated runs and add regression coverage for this case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100