Goland doesn't accept stdin while debugging

When debugging with Goland on macos, my program waits for input from stdin.

When debugging with Goland on macos, my program waits for input from stdin.

I can type in the console and press enter, but the input is not passed to my program.

It is just like typing in a text editor. I can type, press enter, delete everything I just did. My program gets none of this passed to it.

I also get this behavior when debugging with dlv from the console, however, I have found discussion on how to address it in that circumstance:

https://github.com/go-delve/delve/issues/1274#issuecomment-406969034

I see a similar fix for vscode as well:

https://github.com/Microsoft/vscode-go/issues/219#issuecomment-192164367

But I could not find a solution for goland.

Go Programming Tutorial - Real World Advice for Building Go Projects - Practical Go

Go is a language designed for engineering teams. Its central themes are simplicity, readability, and maintainability. This workshop will provide best practice real world advice for teams building projects in Go covering five areas: - Idiomatic code - Package and API design - Error handling - Concurrency - Testing

Thanks for reading

If you liked this post, share it with all of your programming buddies!

Follow us on Facebook | Twitter

Further reading about Go Programming

Learn How To Code: Google's Go (golang) Programming Language

Moving from NodeJS to Go

Building a chat widget with Go and JavaScript

Building Modern Desktop Apps in Go

Why Go Is Perfect For DevOps

Go for DevOps, Go for Microservices, and what Go is Actually Good For