robotcode-robot 1.6.0__py3-none-any.whl → 1.7.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/robot/__version__.py +1 -1
- robotcode/robot/diagnostics/entities.py +2 -1
- robotcode/robot/diagnostics/errors.py +1 -0
- robotcode/robot/diagnostics/namespace.py +1 -1
- robotcode/robot/diagnostics/namespace_analyzer.py +21 -0
- {robotcode_robot-1.6.0.dist-info → robotcode_robot-1.7.0.dist-info}/METADATA +2 -2
- {robotcode_robot-1.6.0.dist-info → robotcode_robot-1.7.0.dist-info}/RECORD +9 -9
- {robotcode_robot-1.6.0.dist-info → robotcode_robot-1.7.0.dist-info}/WHEEL +0 -0
- {robotcode_robot-1.6.0.dist-info → robotcode_robot-1.7.0.dist-info}/licenses/LICENSE.txt +0 -0
robotcode/robot/__version__.py
CHANGED
@@ -1 +1 @@
|
|
1
|
-
__version__ = "1.
|
1
|
+
__version__ = "1.7.0"
|
@@ -179,7 +179,8 @@ class VariableDefinitionType(Enum):
|
|
179
179
|
@dataclass
|
180
180
|
class VariableDefinition(SourceEntity):
|
181
181
|
name: str
|
182
|
-
name_token: Optional[Token]
|
182
|
+
name_token: Optional[Token] # TODO: this is not needed anymore, but kept for compatibility
|
183
|
+
|
183
184
|
type: VariableDefinitionType = VariableDefinitionType.VARIABLE
|
184
185
|
|
185
186
|
has_value: bool = field(default=False, compare=False)
|
@@ -39,6 +39,7 @@ class Error:
|
|
39
39
|
INVALID_HEADER = "InvalidHeader"
|
40
40
|
DEPRECATED_HEADER = "DeprecatedHeader"
|
41
41
|
OVERRIDDEN_BY_COMMANDLINE = "OverriddenByCommandLine"
|
42
|
+
OVERRIDES_IMPORTED_VARIABLE = "OverridesImportedVariable"
|
42
43
|
VARIABLE_ALREADY_DEFINED = "VariableAlreadyDefined"
|
43
44
|
VARIABLE_OVERRIDDEN = "VariableOverridden"
|
44
45
|
MODEL_ERROR = "ModelError"
|
@@ -1116,8 +1116,8 @@ class Namespace:
|
|
1116
1116
|
else []
|
1117
1117
|
),
|
1118
1118
|
[] if skip_global_variables or skip_commandline_variables else self.get_command_line_variables(),
|
1119
|
-
[] if skip_global_variables else self.get_own_variables(),
|
1120
1119
|
[] if skip_global_variables else self.get_imported_variables(),
|
1120
|
+
[] if skip_global_variables else self.get_own_variables(),
|
1121
1121
|
[] if skip_global_variables else self.get_builtin_variables(),
|
1122
1122
|
)
|
1123
1123
|
)
|
@@ -234,6 +234,27 @@ class NamespaceAnalyzer(Visitor):
|
|
234
234
|
)
|
235
235
|
|
236
236
|
add_to_references = True
|
237
|
+
|
238
|
+
if existing_var is not None and existing_var.type == VariableDefinitionType.IMPORTED_VARIABLE:
|
239
|
+
self._append_diagnostics(
|
240
|
+
r,
|
241
|
+
"Overrides imported variable.",
|
242
|
+
DiagnosticSeverity.WARNING,
|
243
|
+
Error.OVERRIDES_IMPORTED_VARIABLE,
|
244
|
+
related_information=[
|
245
|
+
DiagnosticRelatedInformation(
|
246
|
+
location=Location(
|
247
|
+
uri=str(Uri.from_path(existing_var.source)),
|
248
|
+
range=existing_var.range,
|
249
|
+
),
|
250
|
+
message="Already defined here.",
|
251
|
+
)
|
252
|
+
]
|
253
|
+
if existing_var.source
|
254
|
+
else None,
|
255
|
+
)
|
256
|
+
existing_var = None
|
257
|
+
|
237
258
|
first_overidden_reference: Optional[VariableDefinition] = None
|
238
259
|
if existing_var is not None:
|
239
260
|
self._variable_references[existing_var].add(Location(self._namespace.document_uri, r))
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: robotcode-robot
|
3
|
-
Version: 1.
|
3
|
+
Version: 1.7.0
|
4
4
|
Summary: Support classes for RobotCode for handling Robot Framework projects.
|
5
5
|
Project-URL: Homepage, https://robotcode.io
|
6
6
|
Project-URL: Donate, https://opencollective.com/robotcode
|
@@ -26,7 +26,7 @@ Classifier: Topic :: Utilities
|
|
26
26
|
Classifier: Typing :: Typed
|
27
27
|
Requires-Python: >=3.8
|
28
28
|
Requires-Dist: platformdirs<4.4.0,>=3.2.0
|
29
|
-
Requires-Dist: robotcode-core==1.
|
29
|
+
Requires-Dist: robotcode-core==1.7.0
|
30
30
|
Requires-Dist: robotframework>=4.1.0
|
31
31
|
Requires-Dist: tomli>=1.1.0; python_version < '3.11'
|
32
32
|
Description-Content-Type: text/markdown
|
@@ -1,5 +1,5 @@
|
|
1
1
|
robotcode/robot/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
robotcode/robot/__version__.py,sha256=
|
2
|
+
robotcode/robot/__version__.py,sha256=lEEx5lwinUby-YNl7w-VFGUcjcibsJ9EuzgJ2W7ocrU,22
|
3
3
|
robotcode/robot/py.typed,sha256=bWew9mHgMy8LqMu7RuqQXFXLBxh2CRx0dUbSx-3wE48,27
|
4
4
|
robotcode/robot/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
5
5
|
robotcode/robot/config/loader.py,sha256=qrP810HNMDpqhXopWa0dOa0Wq_zQfVctsNYKY6sLKGI,8654
|
@@ -9,14 +9,14 @@ robotcode/robot/diagnostics/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMp
|
|
9
9
|
robotcode/robot/diagnostics/data_cache.py,sha256=duLbcKzwqlCC1tBvJY8ASYh2LcIoCSs8_NgQ8NUQ7VU,3186
|
10
10
|
robotcode/robot/diagnostics/diagnostics_modifier.py,sha256=6zJdXBd6g1QM12XJbsHd8gNNysECMnWlne3q8XNgBDo,9797
|
11
11
|
robotcode/robot/diagnostics/document_cache_helper.py,sha256=PFvK4kpDLy-ONGPuIoxZgXV5ZlZ-Or8geGNqbdCk0s8,23768
|
12
|
-
robotcode/robot/diagnostics/entities.py,sha256=
|
13
|
-
robotcode/robot/diagnostics/errors.py,sha256=
|
12
|
+
robotcode/robot/diagnostics/entities.py,sha256=8EM9IwJtgUD68PvmM5PjVwVWMF_tow2GYvMFebJgJM0,12514
|
13
|
+
robotcode/robot/diagnostics/errors.py,sha256=bUreFflbNYKWccbaq6T84VmYozJhsCTOBoMq3xNAIkY,2122
|
14
14
|
robotcode/robot/diagnostics/imports_manager.py,sha256=X7ZEMaLzplrVt_880NyxFnbKlTNKpvNHWQxZeMoaQd0,61167
|
15
15
|
robotcode/robot/diagnostics/keyword_finder.py,sha256=FHPxstUl_0gN5EmmCF0oEjqgxcRNzCDTbxZnmIIrqL8,18730
|
16
16
|
robotcode/robot/diagnostics/library_doc.py,sha256=4Eio6ujJydBFnjJwiNKvw-0FM1LqBlFckclE7bzW6BQ,100764
|
17
17
|
robotcode/robot/diagnostics/model_helper.py,sha256=RmKg1t5qsbSbW5uiehpFzJt157gDSQ1ayzXlur26AGI,31000
|
18
|
-
robotcode/robot/diagnostics/namespace.py,sha256=
|
19
|
-
robotcode/robot/diagnostics/namespace_analyzer.py,sha256=
|
18
|
+
robotcode/robot/diagnostics/namespace.py,sha256=NQseG4eG6gzBxEy2by3HbQd6DHAqflIovz0WooQHyAI,80960
|
19
|
+
robotcode/robot/diagnostics/namespace_analyzer.py,sha256=arj0PWUyqJj0y1iVD4ty_5FIZAeqkMqgPClmstgSxuE,79634
|
20
20
|
robotcode/robot/diagnostics/workspace_config.py,sha256=gyKR5z-HpnjxPAui3YujgeZqXX7RYBO_ErGVlk7vnGc,2689
|
21
21
|
robotcode/robot/utils/__init__.py,sha256=HETwRb7y8SJSehSxygixKwkUGdiTKNgS4NjXVOUrUzE,361
|
22
22
|
robotcode/robot/utils/ast.py,sha256=IdihPbvY2ERwm763mwPcDUZlS-si6AgNdF3ROqX48Pk,11417
|
@@ -26,7 +26,7 @@ robotcode/robot/utils/robot_path.py,sha256=Z-GVBOPA_xeD20bCJi4_AWaU0eQWvCym-YFty
|
|
26
26
|
robotcode/robot/utils/stubs.py,sha256=umugZYAyneFNgqRJBRMJPzm0u0B_TH8Sx_y-ykXnxpw,351
|
27
27
|
robotcode/robot/utils/variables.py,sha256=RCmBdVWtwVkB058QCBE_Bj3_28H1sXmYs0lJF9bVc0w,7644
|
28
28
|
robotcode/robot/utils/visitor.py,sha256=nP3O0qh3YYuxR6S8wYJRBFfNwIVgsgohURBlrnFkRYQ,2299
|
29
|
-
robotcode_robot-1.
|
30
|
-
robotcode_robot-1.
|
31
|
-
robotcode_robot-1.
|
32
|
-
robotcode_robot-1.
|
29
|
+
robotcode_robot-1.7.0.dist-info/METADATA,sha256=6XRink3e-yJBIimMtrRzW9axRODZLKsvHTNz3n7p1dU,2238
|
30
|
+
robotcode_robot-1.7.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
31
|
+
robotcode_robot-1.7.0.dist-info/licenses/LICENSE.txt,sha256=B05uMshqTA74s-0ltyHKI6yoPfJ3zYgQbvcXfDVGFf8,10280
|
32
|
+
robotcode_robot-1.7.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|