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

helpful error message when the debuggee is incompatible with the host OS/arch #2058

Closed
hyangah opened this issue May 21, 2020 · 2 comments
Closed

Comments

@hyangah
Copy link
Contributor

hyangah commented May 21, 2020

This is a feature request (based on microsoft/vscode-go#2696.

If the program to debug is not executable on the current GOHOSTOS/GOHOSTARCH
so dlv cannot launch, I'd like to see more helpful message than the current message.

  1. What version of Delve are you using (dlv version)? 1.4.0

  2. What version of Go are you using? (go version)? go1.14.x

  3. What operating system and processor architecture are you using? darwin/amd64

  4. What did you do?
    Basically, GOOS=linux dlv debug on mac OS. Accidentally cross-compiled. :-)
    Similar issue when dlv exec when the target binary isn't executable.

  5. What did you expect to see?
    An error message indicating the target binary is not executable.
    For example, go run command outputs exec format error.
    Attempt to run such incompatible binaries directly outputs cannot execute binary file.

  6. What did you see instead?
    could not launch process: stub exited while waiting for connection: exit status 0
    which is vague.
    Or, is this (incompatible or corrupted executable) the only case dlv would fail to launch the process with the error message? (If so, maybe rephrase the error message?)

@derekparker
Copy link
Member

Have you tried with Delve built from master? I sent in a patch to fix this issue a month ago: #1979.

Closing for now, we can reopen if this is still an issue.

@hyangah
Copy link
Contributor Author

hyangah commented May 21, 2020

Yes, it works! Thanks!
When will be the new version release? We were with v1.4.0 quite some time.

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

2 participants