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

🐞 Failed run erases the cursor in a terminal #7160

Open
esafak opened this issue Apr 22, 2024 · 5 comments
Open

🐞 Failed run erases the cursor in a terminal #7160

esafak opened this issue Apr 22, 2024 · 5 comments

Comments

@esafak
Copy link
Contributor

esafak commented Apr 22, 2024

What is the issue?

I ran my CI script dagger run npx tsx ci.mts and it made my block cursor disappear.

Dagger version

dagger v0.11.0 (registry.dagger.io/engine) darwin/arm64

Steps to reproduce

dagger run npx tsx ci.mts with some Docker stuff that fails.

Log output

✘ Container.stderr: String! 47.2s
! failed to compute cache key: write /var/lib/dagger/runc-overlayfs/snapshots/snapshots/36/fs/usr/lib/aarch64-linux-gnu/libx265.so

        date: [ 'Mon, 22 Apr 2024 23:03:22 GMT' ],
        connection: [ 'close' ]
      }
    }
  }
}

Node.js v18.20.2
exit status 1
@cchanley2003
Copy link

cchanley2003 commented May 2, 2024

So I have seen this on zsh on Ubuntu. Also it does something where stdin for future commands doesn't work. For instance if I have a failed dagger run and then I attempt to run a sudo command in the same terminal I can't type in my password. Or if a command requests confirmation that doesn't work. I haven't found a way to fix it other then close the terminal and start fresh.

The dagger command does replace the cursor, but stdin is still broken.

@mimizone
Copy link

mimizone commented May 8, 2024

it's easy to reproduce by just not starting Docker on macOS.

The same happens in a bash terminal. Using iTerm or Terminal.
Not only the cursor disappears in this case. But also the newline is messed up. Pressing just enter on the prompt line doesn't create a new line and just keeps adding the prompt again and again.
And there is no text echo, no text shows up when typing or copy pasting anything.
It also doesn't react to CTRL+C etc...

One way to get the cursor back is to open vi and exit.
On zsh everything is back to normal with that, but not the CTRL+C issue.
But on bash it doesn't solve any of the issues above.

@d3287t328
Copy link

I have seen this in bash on ubuntu. It seems to only happen when running a task fails due to a bug in the pipeline code.

@levlaz levlaz changed the title 🐞 Failed run erases the cursor on Fish with MacOs 🐞 Failed run erases the cursor in a terminal May 8, 2024
@levlaz
Copy link
Contributor

levlaz commented May 8, 2024

I also saw this yesterday in bash on ubuntu via a windows client - seems its not specific to OS or shell to me. I updated the title of this issue to make that part a bit more clear.

@wingyplus
Copy link
Contributor

wingyplus commented May 10, 2024

More info, the PowerShell is not broken. With reproducing code (Elixir):

Mix.install([:dagger])

dag = Dagger.connect!()

{:ok, _} = dag
|> Dagger.Client.container()
|> Dagger.Container.from("alpine")
|> Dagger.Container.with_exec(~w"exit 1")
|> Dagger.Container.stdout()

Dagger.close(dag)

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

6 participants