robotcode 1.3.0.dev6__py3-none-any.whl → 1.5.0__py3-none-any.whl

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/cli/__init__.py CHANGED
@@ -1,4 +1,6 @@
1
+ import json
1
2
  import logging
3
+ import logging.config
2
4
  from pathlib import Path
3
5
  from typing import Any, List, Literal, Optional
4
6
 
@@ -35,8 +37,11 @@ click.Parameter.make_metavar = my_make_metavar # type: ignore[method-assign]
35
37
 
36
38
 
37
39
  class RobotCodeFormatter(logging.Formatter):
38
- def __init__(self, *args: Any, **kwargs: Any) -> None:
39
- super().__init__(*args, **kwargs)
40
+ def __init__(self, *args: Any, defaults: Any = None, **kwargs: Any) -> None:
41
+ defaults = defaults or {}
42
+ if defaults.get("indent") is None:
43
+ defaults["indent"] = ""
44
+ super().__init__(*args, defaults=defaults, **kwargs)
40
45
 
41
46
 
42
47
  @click.group(
@@ -162,6 +167,21 @@ class RobotCodeFormatter(logging.Formatter):
162
167
  help="Enables logging of method/function calls.",
163
168
  show_envvar=True,
164
169
  )
170
+ @click.option(
171
+ "--log-config",
172
+ type=click.Path(
173
+ file_okay=True,
174
+ dir_okay=False,
175
+ readable=True,
176
+ exists=True,
177
+ path_type=str,
178
+ ),
179
+ help="Path to a logging configuration file. This must be a valid Python logging configuration file in JSON format."
180
+ " If this option is set, the other logging options are ignored.",
181
+ default=None,
182
+ show_default=True,
183
+ show_envvar=True,
184
+ )
165
185
  @click.option(
166
186
  "--default-path",
167
187
  "-dp",
@@ -220,6 +240,7 @@ def robotcode(
220
240
  log_style: Literal["%", "{", "$"],
221
241
  log_filename: Optional[str],
222
242
  log_calls: bool,
243
+ log_config: Optional[Path],
223
244
  default_path: Optional[List[str]],
224
245
  launcher_script: Optional[str] = None,
225
246
  debugpy: bool = False,
@@ -257,7 +278,21 @@ def robotcode(
257
278
  app.config.log_level = log_level
258
279
  app.config.log_calls = log_calls
259
280
 
260
- if log:
281
+ if log_config:
282
+ if log_calls:
283
+ LoggingDescriptor.set_call_tracing(True)
284
+
285
+ app.verbose(f"Loading logging configuration from '{log_config}'")
286
+ try:
287
+ with open(log_config, "r", encoding="utf-8") as f:
288
+ config = json.load(f)
289
+
290
+ logging.config.dictConfig(config)
291
+
292
+ except Exception as e:
293
+ app.error(f"Failed to load logging configuration from '{log_config}': {e}")
294
+
295
+ elif log:
261
296
  if log_calls:
262
297
  LoggingDescriptor.set_call_tracing(True)
263
298
 
@@ -269,9 +304,7 @@ def robotcode(
269
304
  )
270
305
 
271
306
  try:
272
- logging.root.handlers[0].formatter = RobotCodeFormatter(
273
- fmt=log_format, style=log_style, defaults={"indent": ""}
274
- )
307
+ logging.root.handlers[0].formatter = RobotCodeFormatter(fmt=log_format, style=log_style)
275
308
  except TypeError:
276
309
  pass
277
310
 
@@ -1 +1 @@
1
- __version__ = "1.3.0-dev.6"
1
+ __version__ = "1.5.0"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: robotcode
3
- Version: 1.3.0.dev6
3
+ Version: 1.5.0
4
4
  Summary: Command line interface for RobotCode
5
5
  Project-URL: Homepage, https://robotcode.io
6
6
  Project-URL: Donate, https://opencollective.com/robotcode
@@ -34,39 +34,39 @@ Classifier: Topic :: Text Editors :: Integrated Development Environments (IDE)
34
34
  Classifier: Topic :: Utilities
35
35
  Classifier: Typing :: Typed
36
36
  Requires-Python: >=3.8
37
- Requires-Dist: robotcode-core==1.3.0-dev.6
38
- Requires-Dist: robotcode-plugin==1.3.0-dev.6
39
- Requires-Dist: robotcode-robot==1.3.0-dev.6
37
+ Requires-Dist: robotcode-core==1.5.0
38
+ Requires-Dist: robotcode-plugin==1.5.0
39
+ Requires-Dist: robotcode-robot==1.5.0
40
40
  Provides-Extra: all
41
41
  Requires-Dist: docutils; extra == 'all'
42
42
  Requires-Dist: pyyaml>=5.4; extra == 'all'
43
43
  Requires-Dist: rich; extra == 'all'
44
- Requires-Dist: robotcode-analyze==1.3.0-dev.6; extra == 'all'
45
- Requires-Dist: robotcode-debugger==1.3.0-dev.6; extra == 'all'
46
- Requires-Dist: robotcode-language-server==1.3.0-dev.6; extra == 'all'
47
- Requires-Dist: robotcode-repl-server==1.3.0-dev.6; extra == 'all'
48
- Requires-Dist: robotcode-repl==1.3.0-dev.6; extra == 'all'
49
- Requires-Dist: robotcode-runner==1.3.0-dev.6; extra == 'all'
44
+ Requires-Dist: robotcode-analyze==1.5.0; extra == 'all'
45
+ Requires-Dist: robotcode-debugger==1.5.0; extra == 'all'
46
+ Requires-Dist: robotcode-language-server==1.5.0; extra == 'all'
47
+ Requires-Dist: robotcode-repl-server==1.5.0; extra == 'all'
48
+ Requires-Dist: robotcode-repl==1.5.0; extra == 'all'
49
+ Requires-Dist: robotcode-runner==1.5.0; extra == 'all'
50
50
  Requires-Dist: robotframework-robocop>=2.0.0; extra == 'all'
51
51
  Requires-Dist: robotframework-tidy>=2.0.0; extra == 'all'
52
52
  Provides-Extra: analyze
53
- Requires-Dist: robotcode-analyze==1.3.0-dev.6; extra == 'analyze'
53
+ Requires-Dist: robotcode-analyze==1.5.0; extra == 'analyze'
54
54
  Provides-Extra: colored
55
55
  Requires-Dist: rich; extra == 'colored'
56
56
  Provides-Extra: debugger
57
- Requires-Dist: robotcode-debugger==1.3.0-dev.6; extra == 'debugger'
57
+ Requires-Dist: robotcode-debugger==1.5.0; extra == 'debugger'
58
58
  Provides-Extra: languageserver
59
- Requires-Dist: robotcode-language-server==1.3.0-dev.6; extra == 'languageserver'
59
+ Requires-Dist: robotcode-language-server==1.5.0; extra == 'languageserver'
60
60
  Provides-Extra: lint
61
61
  Requires-Dist: robotframework-robocop>=2.0.0; extra == 'lint'
62
62
  Provides-Extra: repl
63
- Requires-Dist: robotcode-repl==1.3.0-dev.6; extra == 'repl'
63
+ Requires-Dist: robotcode-repl==1.5.0; extra == 'repl'
64
64
  Provides-Extra: replserver
65
- Requires-Dist: robotcode-repl-server==1.3.0-dev.6; extra == 'replserver'
65
+ Requires-Dist: robotcode-repl-server==1.5.0; extra == 'replserver'
66
66
  Provides-Extra: rest
67
67
  Requires-Dist: docutils; extra == 'rest'
68
68
  Provides-Extra: runner
69
- Requires-Dist: robotcode-runner==1.3.0-dev.6; extra == 'runner'
69
+ Requires-Dist: robotcode-runner==1.5.0; extra == 'runner'
70
70
  Provides-Extra: tidy
71
71
  Requires-Dist: robotframework-tidy>=2.0.0; extra == 'tidy'
72
72
  Provides-Extra: yaml
@@ -130,13 +130,44 @@ With RobotCode, you can focus on building and testing your automation workflows
130
130
 
131
131
  ## Requirements
132
132
 
133
- - Python 3.8 or newer
134
- - Robot Framework 4.1 or newer
133
+ ### Python and Robot Framework Versions
134
+ - Python 3.10 or newer
135
+ - Robot Framework 5.0 or newer
135
136
 
136
137
  ### IDE Support
137
138
 
138
- - Visual Studio Code 1.86 or newer
139
- - PyCharm 2024.3.2 or newer or IntelliJ IDEA 2024.3.2 or newer
139
+ - Visual Studio Code 1.99 or newer
140
+ - PyCharm 2025.1 or newer or IntelliJ IDEA 2025.1 or newer
141
+
142
+ ### Deprecated Python and Robot Framework Versions
143
+
144
+ **⚠️ DEPRECATION WARNING:**
145
+ Support for Python 3.8, 3.9, and Robot Framework 4.1 is deprecated and will be removed in a future release. To ensure compatibility and benefit from ongoing improvements, please upgrade to Python 3.10 or later and Robot Framework 5.0 or later.
146
+
147
+ **Python Version Requirements:**
148
+ Although Robot Framework still supports Python 3.8 and 3.9, RobotCode requires Python 3.10 or newer due to its use of more modern libraries and features. Many key tools in the ecosystem—such as robocop and the Browser library—have already dropped support for Python 3.8, which is no longer maintained. Python 3.9 will reach end-of-life on October 5, 2025.
149
+
150
+ **Robot Framework Version Requirements:**
151
+ Robot Framework 4.1 is outdated. Given the regular release cadence of Robot Framework—typically two major versions per year—maintaining support for older versions introduces significant overhead. That effort is better spent on supporting current and upcoming features.
152
+
153
+ **Compatibility and Limitations:**
154
+ RobotCode currently remains compatible with Python 3.8+ and Robot Framework 4.1+, but with important limitations:
155
+ • New features may not be available for older versions.
156
+ • Development and testing efforts are focused on newer versions.
157
+
158
+ **Why Python 3.10:**
159
+ After Python 3.9 reaches end-of-life, RobotCode will start using Python 3.10+ features that are not backward-compatible. Python 3.10 introduces several important improvements, including:
160
+ • Structural pattern matching
161
+ • More informative error messages
162
+ • Simplified type hints using the | operator
163
+ • Performance enhancements
164
+
165
+ These capabilities enable cleaner, more efficient code and improved developer experience.
166
+
167
+ **Recommendation:**
168
+ To get the most out of RobotCode, we recommend using:
169
+ • Python 3.10 or newer
170
+ • Robot Framework 5.0 or newer
140
171
 
141
172
 
142
173
  ## Getting Started
@@ -0,0 +1,12 @@
1
+ robotcode/cli/__init__.py,sha256=dQ0Hhc3BJCf07zyHINEfAYROccgsnP-jcRUYzdTmD9g,9456
2
+ robotcode/cli/__main__.py,sha256=hX3nwROMTnsYGT1KS0rXUYrslu9sFzctYdAh66Rcckw,153
3
+ robotcode/cli/__version__.py,sha256=X9pTeGHIYZtDOmfb9pnn2DEqWZMAyaPlqdFwEhsuSvk,22
4
+ robotcode/cli/py.typed,sha256=bWew9mHgMy8LqMu7RuqQXFXLBxh2CRx0dUbSx-3wE48,27
5
+ robotcode/cli/commands/__init__.py,sha256=XJHRt_YwMO2Ni2EfL2aj4jkJXMVG6NGFTpzvSVgIRnQ,92
6
+ robotcode/cli/commands/config.py,sha256=0Jmf7HDIo7IIaOMU9M_bYi7PdHAfcae6x3SW93NA3EA,10481
7
+ robotcode/cli/commands/profiles.py,sha256=5H9lvSVCMggWXf0IH54QtgDgqupEEvpcUrEsTZvZsNM,6127
8
+ robotcode-1.5.0.dist-info/METADATA,sha256=rQFPSxxHHy7E1XhcXRkKih4hMdBp6tlLy4i-N52g7GI,13729
9
+ robotcode-1.5.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
10
+ robotcode-1.5.0.dist-info/entry_points.txt,sha256=Pb4DKVVdJb5PboVl48njwk3DkKQHBJOL1A8KkpemqA8,58
11
+ robotcode-1.5.0.dist-info/licenses/LICENSE.txt,sha256=B05uMshqTA74s-0ltyHKI6yoPfJ3zYgQbvcXfDVGFf8,10280
12
+ robotcode-1.5.0.dist-info/RECORD,,
@@ -1,12 +0,0 @@
1
- robotcode/cli/__init__.py,sha256=yhTwDKI4vuM-KEj3p41if2eqdR5q3CQkirCVW0ylkuE,8405
2
- robotcode/cli/__main__.py,sha256=hX3nwROMTnsYGT1KS0rXUYrslu9sFzctYdAh66Rcckw,153
3
- robotcode/cli/__version__.py,sha256=pq2rJvPWP2QTfDdHC9skh4RFueFS5D9YFJqamAJsLNk,28
4
- robotcode/cli/py.typed,sha256=bWew9mHgMy8LqMu7RuqQXFXLBxh2CRx0dUbSx-3wE48,27
5
- robotcode/cli/commands/__init__.py,sha256=XJHRt_YwMO2Ni2EfL2aj4jkJXMVG6NGFTpzvSVgIRnQ,92
6
- robotcode/cli/commands/config.py,sha256=0Jmf7HDIo7IIaOMU9M_bYi7PdHAfcae6x3SW93NA3EA,10481
7
- robotcode/cli/commands/profiles.py,sha256=5H9lvSVCMggWXf0IH54QtgDgqupEEvpcUrEsTZvZsNM,6127
8
- robotcode-1.3.0.dev6.dist-info/METADATA,sha256=gkB9TB6Vl2rAE5hYhxMQfX5Ty5BSt26plhce70UYG1s,11888
9
- robotcode-1.3.0.dev6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
10
- robotcode-1.3.0.dev6.dist-info/entry_points.txt,sha256=Pb4DKVVdJb5PboVl48njwk3DkKQHBJOL1A8KkpemqA8,58
11
- robotcode-1.3.0.dev6.dist-info/licenses/LICENSE.txt,sha256=B05uMshqTA74s-0ltyHKI6yoPfJ3zYgQbvcXfDVGFf8,10280
12
- robotcode-1.3.0.dev6.dist-info/RECORD,,