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

When running Starlark Debug Server, it reminds: connection error: proto: cannot parse invalid wire-format data #107

Open
wulixzCN opened this issue May 21, 2022 · 1 comment

Comments

@wulixzCN
Copy link

wulixzCN commented May 21, 2022

My configurations is : {type : starlark, request: attach, debugServer: 4711}
After running command 'build //cmd/gencopy --experimental_skylark_debug
' and 'bzl debug adapter' successfully, I try to debug following the video : https://www.youtube.com/watch?v=MAXJA8Gbtxk

it reminds: it reminds: connection error: proto: cannot parse invalid wire-format data
image

How to fix it, I have no idea ^_^

@wulixzCN
Copy link
Author

wulixzCN commented May 23, 2022

I am coding with Starlark language recently and try to use Starlark debug tools to debug Starlark program.

  1. When running Starlark Debug Server, it reminds that ‘connection err: photo: cannot parse invalid wire-format data’
    My configuration is:
    {
    "version": "0.2.0",
    "configurations": [{
    "type": "starlark",
    "request": "attach",
    "debugServer": 4711,
    "name": "Attach to a running Starlark Debug Server"
    }]
    }

Before running it. I download your “rules_proto" project and run the following two commands in two different terminal.

  1. bazel build //cmd/gencopy --experimental_skylark_debug
    Starting local Bazel server and connecting to it…

  2. bzl debug adapter --make_default_workspace_content=false --address 127.0.0.1:4711
    INFO[0000] Debug adapter listening on 127.0.0.1:4711
    INFO[0010] Accepted connection from 127.0.0.1:64541
    Trying to connect to a Starlark server at localhost:7300...
    Connected
    INFO[0091] No more data to read: EOF
    INFO[0091] Closing connection from 127.0.0.1:64541

  3. When I adjust the configuration attach to launch
    {
    "version": "0.2.0",
    "configurations": [
    {
    "type": "starlark",
    "request": "launch",
    "name": "Attach to a running Starlark Debug Server",
    "targetLabel": "//cmd/gencopy"
    // "targetLabel":"${workspaceFolder}/${command:bsv.bzl.askForDebugTargetLabel}"
    }]
    }

The debugger running without reminder, but the icon looks like that.
image

And I already set lots of breakpoints
By searching lots of documents, I cannot find out the result.

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