Skip to content

Run wsget cli non-interactively (w/o /dev/tty) #148

Description

@srkaj

Hi! Thanks for making wsget!

Is it possible to run wsget non-interactively, without access to /dev/tty? I'm trying to use it for testing a websocket server in CI (github actions), but it keeps failing with this message:

  25lUse Enter to input request and send it, Ctrl+C to exit
  25hError: keyboard input failed: open /dev/tty: no such device or address

I have tried running both with a --request parameter and with a script.yaml looking like this:

- send {"my":"payload"}
- wait 10
- exit

If it is not currently possible, could a CLI argument be added to turn of the interactive parts? Or maybe disable them by default when a --request argument is given?

I have looked through this github repo for any (undocumented) way to turn it off, but haven't found it (though I'm no expert in the golang ecosystem). What I did find is some tests in wsget that deliberately ignores this error, so I guess they don't really test anything when running in github CI. So I guess the feature I'm requesting would be useful there too.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions