MCPcopy Create free account
hub / github.com/fabioz/PyDev.Debugger / InitializeRequest

Class InitializeRequest

_pydevd_bundle/_debug_adapter/pydevd_schema.py:2234–2295  ·  view source on GitHub ↗

The `initialize` request is sent as the first request from the client to the debug adapter in order to configure it with client capabilities and to retrieve capabilities from the debug adapter. Until the debug adapter has responded with an `initialize` response, the client must not sen

Source from the content-addressed store, hash-verified

2232@register_request("initialize")
2233@register
2234class InitializeRequest(BaseSchema):
2235 """
2236 The `initialize` request is sent as the first request from the client to the debug adapter in order
2237 to configure it with client capabilities and to retrieve capabilities from the debug adapter.
2238
2239 Until the debug adapter has responded with an `initialize` response, the client must not send any
2240 additional requests or events to the debug adapter.
2241
2242 In addition the debug adapter is not allowed to send any requests or events to the client until it
2243 has responded with an `initialize` response.
2244
2245 The `initialize` request may only be sent once.
2246
2247 Note: automatically generated code. Do not edit manually.
2248 """
2249
2250 __props__ = {
2251 "seq": {
2252 "type": "integer",
2253 "description": "Sequence number of the message (also known as message ID). The `seq` for the first message sent by a client or debug adapter is 1, and for each subsequent message is 1 greater than the previous message sent by that actor. `seq` can be used to order requests, responses, and events, and to associate requests with their corresponding responses. For protocol messages of type `request` the sequence number can be used to cancel the request.",
2254 },
2255 "type": {"type": "string", "enum": ["request"]},
2256 "command": {"type": "string", "enum": ["initialize"]},
2257 "arguments": {"type": "InitializeRequestArguments"},
2258 }
2259 __refs__ = set(["arguments"])
2260
2261 __slots__ = list(__props__.keys()) + ["kwargs"]
2262
2263 def __init__(self, arguments, seq=-1, update_ids_from_dap=False, **kwargs): # noqa (update_ids_from_dap may be unused)
2264 """
2265 :param string type:
2266 :param string command:
2267 :param InitializeRequestArguments arguments:
2268 :param integer seq: Sequence number of the message (also known as message ID). The `seq` for the first message sent by a client or debug adapter is 1, and for each subsequent message is 1 greater than the previous message sent by that actor. `seq` can be used to order requests, responses, and events, and to associate requests with their corresponding responses. For protocol messages of type `request` the sequence number can be used to cancel the request.
2269 """
2270 self.type = "request"
2271 self.command = "initialize"
2272 if arguments is None:
2273 self.arguments = InitializeRequestArguments()
2274 else:
2275 self.arguments = (
2276 InitializeRequestArguments(update_ids_from_dap=update_ids_from_dap, **arguments)
2277 if arguments.__class__ != InitializeRequestArguments
2278 else arguments
2279 )
2280 self.seq = seq
2281 self.kwargs = kwargs
2282
2283 def to_dict(self, update_ids_to_dap=False): # noqa (update_ids_to_dap may be unused)
2284 type = self.type # noqa (assign to builtin)
2285 command = self.command
2286 arguments = self.arguments
2287 seq = self.seq
2288 dct = {
2289 "type": type,
2290 "command": command,
2291 "arguments": arguments.to_dict(update_ids_to_dap=update_ids_to_dap),

Callers 1

write_initializeMethod · 0.90

Calls 1

keysMethod · 0.80

Tested by 1

write_initializeMethod · 0.72