robotcode-debugger 0.66.1__tar.gz → 0.68.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/PKG-INFO +3 -3
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/pyproject.toml +2 -2
- robotcode_debugger-0.68.0/src/robotcode/debugger/__version__.py +1 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/cli.py +1 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/dap_types.py +1 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/debugger.py +16 -4
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/client.py +1 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/server.py +1 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/protocol.py +2 -2
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/run.py +2 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/server.py +1 -1
- robotcode_debugger-0.66.1/src/robotcode/debugger/__version__.py +0 -1
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/.gitignore +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/LICENSE.txt +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/README.md +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/__init__.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/hooks.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/__init__.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/cli.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/run.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/listeners.py +0 -0
- {robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/py.typed +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: robotcode-debugger
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.68.0
|
|
4
4
|
Summary: RobotCode Debugger for Robot Framework
|
|
5
5
|
Project-URL: Homepage, https://robotcode.io
|
|
6
6
|
Project-URL: Donate, https://github.com/sponsors/d-biehl
|
|
@@ -25,8 +25,8 @@ Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
|
25
25
|
Classifier: Topic :: Utilities
|
|
26
26
|
Classifier: Typing :: Typed
|
|
27
27
|
Requires-Python: >=3.8
|
|
28
|
-
Requires-Dist: robotcode-jsonrpc2==0.
|
|
29
|
-
Requires-Dist: robotcode-runner==0.
|
|
28
|
+
Requires-Dist: robotcode-jsonrpc2==0.68.0
|
|
29
|
+
Requires-Dist: robotcode-runner==0.68.0
|
|
30
30
|
Requires-Dist: robotframework>=4.1.0
|
|
31
31
|
Provides-Extra: debugpy
|
|
32
32
|
Requires-Dist: debugpy; extra == 'debugpy'
|
|
@@ -28,8 +28,8 @@ classifiers = [
|
|
|
28
28
|
dynamic = ["version"]
|
|
29
29
|
dependencies = [
|
|
30
30
|
"robotframework>=4.1.0",
|
|
31
|
-
"robotcode-jsonrpc2==0.
|
|
32
|
-
"robotcode-runner==0.
|
|
31
|
+
"robotcode-jsonrpc2==0.68.0",
|
|
32
|
+
"robotcode-runner==0.68.0",
|
|
33
33
|
]
|
|
34
34
|
|
|
35
35
|
[project.optional-dependencies]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.68.0"
|
|
@@ -11,7 +11,6 @@ from robotcode.plugin.click_helper.types import (
|
|
|
11
11
|
)
|
|
12
12
|
|
|
13
13
|
from .__version__ import __version__
|
|
14
|
-
from .run import run_debugger
|
|
15
14
|
|
|
16
15
|
DEBUGGER_DEFAULT_PORT = 6612
|
|
17
16
|
DEBUGPY_DEFAULT_PORT = 5678
|
|
@@ -136,6 +135,7 @@ def debug(
|
|
|
136
135
|
robot_options_and_args: Tuple[str, ...],
|
|
137
136
|
) -> None:
|
|
138
137
|
"""Starts a Robot Framework debug session and waits for incomming connections."""
|
|
138
|
+
from .run import run_debugger
|
|
139
139
|
|
|
140
140
|
mode, port, bind, pipe_name = resolve_server_options(
|
|
141
141
|
ctx, app, mode, port, bind, pipe_name, tcp, None, None, None, pipe_server
|
|
@@ -4,7 +4,7 @@ from dataclasses import dataclass, field
|
|
|
4
4
|
from enum import Enum
|
|
5
5
|
from typing import Any, Dict, Iterator, List, Literal, Optional, Union
|
|
6
6
|
|
|
7
|
-
from robotcode.core.dataclasses import to_camel_case, to_snake_case
|
|
7
|
+
from robotcode.core.utils.dataclasses import to_camel_case, to_snake_case
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
@dataclass
|
|
@@ -36,11 +36,10 @@ from robot.api.parsing import get_model
|
|
|
36
36
|
from robot.errors import VariableError
|
|
37
37
|
from robot.output import LOGGER
|
|
38
38
|
from robot.running import EXECUTION_CONTEXTS, Keyword, TestCase, TestSuite
|
|
39
|
-
from robot.running.userkeyword import UserKeywordHandler
|
|
40
39
|
from robot.utils import NormalizedDict
|
|
41
40
|
from robot.variables import evaluate_expression
|
|
42
41
|
from robotcode.core.event import event
|
|
43
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
42
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
44
43
|
from robotcode.robot.utils import get_robot_version
|
|
45
44
|
|
|
46
45
|
from .dap_types import (
|
|
@@ -72,6 +71,11 @@ from .dap_types import (
|
|
|
72
71
|
VariablePresentationHint,
|
|
73
72
|
)
|
|
74
73
|
|
|
74
|
+
if get_robot_version() >= (7, 0):
|
|
75
|
+
from robot.running.invalidkeyword import InvalidKeywordRunner as UserKeywordHandler
|
|
76
|
+
else:
|
|
77
|
+
from robot.running.userkeyword import UserKeywordHandler
|
|
78
|
+
|
|
75
79
|
if get_robot_version() >= (6, 1):
|
|
76
80
|
|
|
77
81
|
def internal_evaluate_expression(expression: str, variable_store: Any) -> Any:
|
|
@@ -298,6 +302,7 @@ class Debugger:
|
|
|
298
302
|
self.output_messages: bool = False
|
|
299
303
|
self.output_log: bool = False
|
|
300
304
|
self.output_timestamps: bool = False
|
|
305
|
+
self.colored_output: bool = True
|
|
301
306
|
self.group_output: bool = False
|
|
302
307
|
self.hit_counts: Dict[HitCountEntry, int] = {}
|
|
303
308
|
self.last_fail_message: Optional[str] = None
|
|
@@ -1195,9 +1200,16 @@ class Debugger:
|
|
|
1195
1200
|
)
|
|
1196
1201
|
|
|
1197
1202
|
def _build_output(self, level: str, msg: str, timestamp: str) -> str:
|
|
1203
|
+
if self.colored_output:
|
|
1204
|
+
return (
|
|
1205
|
+
(f"\u001b[38;5;243m{timestamp.split(' ', 1)[1]}\u001b[0m " if self.output_timestamps else "")
|
|
1206
|
+
+ (f"[ {self.MESSAGE_COLORS.get(level, '')}{level}\u001b[0m ] " if level != "INFO" else "")
|
|
1207
|
+
+ f"{msg}\n"
|
|
1208
|
+
)
|
|
1209
|
+
|
|
1198
1210
|
return (
|
|
1199
|
-
(f"
|
|
1200
|
-
+ (f"[ {
|
|
1211
|
+
(f"{timestamp.split(' ', 1)[1]} " if self.output_timestamps else "")
|
|
1212
|
+
+ (f"[ {level} ] " if level != "INFO" else "")
|
|
1201
1213
|
+ f"{msg}\n"
|
|
1202
1214
|
)
|
|
1203
1215
|
|
{robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/client.py
RENAMED
|
@@ -4,8 +4,8 @@ import asyncio
|
|
|
4
4
|
from typing import Any, Optional, Sequence
|
|
5
5
|
|
|
6
6
|
from robotcode.core.event import event
|
|
7
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
8
7
|
from robotcode.core.types import TcpParams
|
|
8
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
9
9
|
|
|
10
10
|
from ..dap_types import Event
|
|
11
11
|
from ..protocol import DebugAdapterProtocol
|
{robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/server.py
RENAMED
|
@@ -7,8 +7,8 @@ import sys
|
|
|
7
7
|
from pathlib import Path
|
|
8
8
|
from typing import Any, Dict, List, Literal, Optional
|
|
9
9
|
|
|
10
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
11
10
|
from robotcode.core.types import ServerMode, TcpParams
|
|
11
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
12
12
|
from robotcode.jsonrpc2.protocol import rpc_method
|
|
13
13
|
from robotcode.jsonrpc2.server import JsonRPCServer
|
|
14
14
|
from robotcode.robot.utils import get_robot_version
|
|
@@ -21,9 +21,9 @@ from typing import (
|
|
|
21
21
|
Union,
|
|
22
22
|
)
|
|
23
23
|
|
|
24
|
-
from robotcode.core.dataclasses import as_dict, as_json, from_dict
|
|
25
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
24
|
+
from robotcode.core.utils.dataclasses import as_dict, as_json, from_dict
|
|
26
25
|
from robotcode.core.utils.inspect import ensure_coroutine
|
|
26
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
27
27
|
from robotcode.jsonrpc2.protocol import JsonRPCException, JsonRPCProtocolBase, SendedRequestEntry
|
|
28
28
|
|
|
29
29
|
from .dap_types import (
|
|
@@ -18,13 +18,13 @@ from robotcode.core.async_tools import (
|
|
|
18
18
|
run_coroutine_from_thread_async,
|
|
19
19
|
run_coroutine_in_thread,
|
|
20
20
|
)
|
|
21
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
22
21
|
from robotcode.core.types import ServerMode, TcpParams
|
|
23
22
|
from robotcode.core.utils.debugpy import (
|
|
24
23
|
enable_debugpy,
|
|
25
24
|
is_debugpy_installed,
|
|
26
25
|
wait_for_debugpy_connected,
|
|
27
26
|
)
|
|
27
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
28
28
|
from robotcode.core.utils.net import find_free_port
|
|
29
29
|
from robotcode.plugin import Application
|
|
30
30
|
|
|
@@ -197,6 +197,7 @@ async def run_debugger(
|
|
|
197
197
|
Debugger.instance().output_log = output_log
|
|
198
198
|
Debugger.instance().group_output = group_output
|
|
199
199
|
Debugger.instance().output_timestamps = output_timestamps
|
|
200
|
+
Debugger.instance().colored_output = app.colored
|
|
200
201
|
Debugger.instance().debug = debug
|
|
201
202
|
Debugger.instance().set_main_thread(threading.current_thread())
|
|
202
203
|
Debugger.instance().server_loop = server.loop
|
|
@@ -3,8 +3,8 @@ import os
|
|
|
3
3
|
from typing import Any, Callable, Dict, List, Literal, Optional, Union
|
|
4
4
|
|
|
5
5
|
from robotcode.core import async_tools
|
|
6
|
-
from robotcode.core.logging import LoggingDescriptor
|
|
7
6
|
from robotcode.core.types import ServerMode, TcpParams
|
|
7
|
+
from robotcode.core.utils.logging import LoggingDescriptor
|
|
8
8
|
from robotcode.jsonrpc2.protocol import rpc_method
|
|
9
9
|
from robotcode.jsonrpc2.server import JsonRPCServer
|
|
10
10
|
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.66.1"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/__init__.py
RENAMED
|
File without changes
|
{robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/cli.py
RENAMED
|
File without changes
|
{robotcode_debugger-0.66.1 → robotcode_debugger-0.68.0}/src/robotcode/debugger/launcher/run.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|