You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
using Pkg
Pkg.instantiate()
using Sockets
using DebugAdapter
using Logging
functionstart_debugger()
try
server_port =parse(Int, ARGS[1])
server = Sockets.listen(server_port)
println("Listening on port $server_port")
conn = Sockets.accept(server)
println("Client connected")
debugsession = DebugAdapter.DebugSession(conn)
run(debugsession)
close(conn)
catch e
println("Error: ", e)
endendstart_debugger()
And when Run/Debug is occurred, I execute this file like this:
julia ...\server.jl 58550
The Julia DAP server can be intianlized and give me some DAP response but when configuration done is occured I have the following error:
ERROR: MethodError: no method matching Union{Nothing, DebugAdapter.ConfigurationDoneArguments}(::Dict{String, Any})
Here the full DAP traces:
julia ...\server.jl 58550
Listening on port 58550
Client connected
[Trace - 11:17:39] Sending request 'initialize - (1)'.
Params: {
"clientID": "lsp4ij.debug",
"clientName": "IntelliJ IDEA 2024.3",
"adapterID": "julia",
"linesStartAt1": true,
"columnsStartAt1": true,
"pathFormat": "path",
"supportsVariableType": true,
"supportsVariablePaging": false,
"supportsStartDebuggingRequest": true
}
[Trace - 11:17:42] Received response 'initialize - (1)' in 3292ms.
Result: {
"supportsConfigurationDoneRequest": true,
"supportsFunctionBreakpoints": true,
"supportsConditionalBreakpoints": true,
"supportsHitConditionalBreakpoints": false,
"supportsEvaluateForHovers": true,
"exceptionBreakpointFilters": [
{
"filter": "error",
"label": "Uncaught Exceptions",
"default": true
},
{
"filter": "throw",
"label": "All Exceptions",
"default": false
}
],
"supportsStepBack": false,
"supportsSetVariable": true,
"supportsRestartFrame": true,
"supportsStepInTargetsRequest": true,
"supportsCompletionsRequest": false,
"additionalModuleColumns": [],
"supportedChecksumAlgorithms": [],
"supportsExceptionInfoRequest": true,
"supportsLogPoints": false,
"supportsTerminateRequest": true,
"supportsDataBreakpoints": false
}
[Trace - 11:17:42] Sending request 'launch - (2)'.
Params: {
"projectDir": "C:\\Users\\azerr\\Downloads\\TestSwift2\\swift-executable",
"request": "launch",
"exitAfterTaskReturns": false,
"stopOnEntry": true,
"debugAutoInterpretAllModules": false,
"noDebug": true,
"name": "Launch Julia file",
"program": "C:\\Users\\azerr\\Downloads\\TestSwift2\\swift-executable\\test2.jl",
"type": "julia"
}
[Trace - 11:17:43] Received notification 'initialized'
Params: null
[Trace - 11:17:43] Sending request 'configurationDone - (3)'.
Params: {}
ERROR: MethodError: no method matching Union{Nothing, DebugAdapter.ConfigurationDoneArguments}(::Dict{String, Any})
The type `Union{Nothing, DebugAdapter.ConfigurationDoneArguments}` exists, but no method is defined for this combination of argument types when trying to construct it.
Stacktrace:
[1] dispatch_msg(x::DebugAdapter.DAPRPC.DAPEndpoint{TCPSocket, TCPSocket}, dispatcher::DebugAdapter.DAPRPC.MsgDispatcher, msg::Dict{String, Any})
@ DebugAdapter.DAPRPC C:\Users\azerr\.julia\packages\DebugAdapter\Dbvzw\src\DAPRPC\typed.jl:78
[2] (::DebugAdapter.var"#132#161"{Dict{String, Any}, Nothing, DebugAdapter.DAPRPC.MsgDispatcher, DebugAdapter.DAPRPC.DAPEndpoint{TCPSocket, TCPSocket}})()
@ DebugAdapter C:\Users\azerr\.julia\packages\DebugAdapter\Dbvzw\src\packagedef.jl:98
Many thanks for your help!
The text was updated successfully, but these errors were encountered:
To be honnest with you, I dont know julia. I have implemented dap client on intellij and I am trying with some dap servers like vscode js, swift, go which are working pretty well
As I have seen several people could be interested with julia debugging in IntelliJ, I have tried it.
My question, is how test your PR?
And why other dap client like nvim, email, vscode have not this problem?
You can use the version of DebugAdapter from that branch by running pkg> add DebugAdapter#fix-type-bug in the pkg manager REPL, that should switch it over from the released version of DebugAdapater to the one where I (hopefully) fixed that bug.
And why other dap client like nvim, email, vscode have not this problem?
Yeah, that is a good question, I'm actually a bit confused about that as well...
I'm trying to consume Julia DAP server inside IntelliJ with https://github.com/redhat-developer/lsp4ij/blob/main/docs/dap/DAP.md
I have created a julia file like this:
And when Run/Debug is occurred, I execute this file like this:
julia ...\server.jl 58550
The Julia DAP server can be intianlized and give me some DAP response but when configuration done is occured I have the following error:
ERROR: MethodError: no method matching Union{Nothing, DebugAdapter.ConfigurationDoneArguments}(::Dict{String, Any})
Here the full DAP traces:
Many thanks for your help!
The text was updated successfully, but these errors were encountered: