Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Last typed character can be dropped sometimes #497

Open
Utagai opened this issue Jul 1, 2024 · 0 comments
Open

Last typed character can be dropped sometimes #497

Utagai opened this issue Jul 1, 2024 · 0 comments

Comments

@Utagai
Copy link
Contributor

Utagai commented Jul 1, 2024

Describe the bug
Try a simple .tape file, such as:

Output output.gif

Type "hello world!"

This is a flaky behavior. It doesn't always happen.

Setup
Please complete the following information along with version numbers, if applicable.

  • OS: WSL
  • Shell: fish
  • Terminal Emulator: Microsoft Terminal
  • Terminal Multiplexer: N/A
  • vhs commit hash: 586e3d6

To Reproduce
Steps to reproduce the behavior:

  1. Use the example tape file above.
  2. Run vhs example.tape
  3. Check output .gif. If not missing character, go to step 2.
  4. Observe the missing !.

Example:

vhs | go build
vhs | ./vhs readme_demo.tape
File: readme_demo.tape
Output .gif output.gif
Type hello world!
Creating output.gif...
Host your GIF on vhs.charm.sh: vhs publish <file>.gif
vhs | git rev-parse HEAD
586e3d6dbbddee3ea074f06c7a3ce8529d84f7ca
vhs | cat readme_demo.tape
Output output.gif

Type "hello world!"

Screenshot/output.gif shown below.

Source Code

Output output.gif

Type "hello world!"

Expected behavior
The output recording should always show all the typed characters.

Screenshots
Sometimes, the last character (in this case !) is dropped. Example output:
dropped

Additional context
This is a race, so it may be very difficult to reproduce on other systems depending on CPU speed, etc. I believe you can reproduce it more easily if the recording itself is longer but I'm not 100% sure. I discovered this while working on #496.

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

No branches or pull requests

1 participant