robotcode-robot 2.9.0.dev197__py3-none-any.whl → 2.9.0.dev214__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/document_cache_helper.py +2 -1
- robotcode/robot/diagnostics/imports_manager.py +2 -2
- robotcode/robot/document_formats.py +0 -19
- robotcode/robot/language_definitions.py +39 -0
- {robotcode_robot-2.9.0.dev197.dist-info → robotcode_robot-2.9.0.dev214.dist-info}/METADATA +2 -2
- {robotcode_robot-2.9.0.dev197.dist-info → robotcode_robot-2.9.0.dev214.dist-info}/RECORD +8 -7
- {robotcode_robot-2.9.0.dev197.dist-info → robotcode_robot-2.9.0.dev214.dist-info}/WHEEL +0 -0
robotcode/robot/__version__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "2.9.0-dev.
|
|
1
|
+
__version__ = "2.9.0-dev.214"
|
|
@@ -35,7 +35,8 @@ from robotcode.robot.diagnostics.diagnostics_modifier import (
|
|
|
35
35
|
)
|
|
36
36
|
|
|
37
37
|
from ..config.model import RobotBaseProfile
|
|
38
|
-
from ..document_formats import
|
|
38
|
+
from ..document_formats import is_markdown_file
|
|
39
|
+
from ..language_definitions import MARKDOWN_LANGUAGE_ID
|
|
39
40
|
from ..utils import RF_VERSION
|
|
40
41
|
from ..utils.markdown_blocks import RobotBlock, find_robot_blocks, read_markdown_data
|
|
41
42
|
from ..utils.stubs import Languages
|
|
@@ -56,7 +56,7 @@ from robotcode.core.utils.path import (
|
|
|
56
56
|
)
|
|
57
57
|
|
|
58
58
|
from ..__version__ import __version__
|
|
59
|
-
from ..
|
|
59
|
+
from ..language_definitions import ROBOT_LANGUAGE_IDS
|
|
60
60
|
from ..utils import RF_VERSION
|
|
61
61
|
from ..utils.robot_path import find_file_ex
|
|
62
62
|
from ..utils.stubs import Languages
|
|
@@ -1273,7 +1273,7 @@ class ImportsManager:
|
|
|
1273
1273
|
# unresolved imports (file didn't exist yet) get invalidated and re-analyzed.
|
|
1274
1274
|
self.imports_changed(self, uri)
|
|
1275
1275
|
|
|
1276
|
-
@language_id(
|
|
1276
|
+
@language_id(*ROBOT_LANGUAGE_IDS)
|
|
1277
1277
|
def _on_possible_resource_document_modified(self, sender: Any, document: TextDocument) -> None:
|
|
1278
1278
|
run_as_task(self.__on_possible_resource_document_modified, sender, document)
|
|
1279
1279
|
|
|
@@ -4,7 +4,6 @@ from pathlib import Path
|
|
|
4
4
|
from typing import Callable, Dict, List, Optional, Tuple, Union
|
|
5
5
|
|
|
6
6
|
from robot.running.builder import TestSuiteBuilder
|
|
7
|
-
from robotcode.core.language import LanguageDefinition
|
|
8
7
|
from robotcode.core.utils.dataclasses import CamelSnakeMixin
|
|
9
8
|
|
|
10
9
|
from .config.model import RobotBaseProfile, StringExpression
|
|
@@ -33,9 +32,6 @@ def _robot_framework_formats() -> Tuple[Tuple[str, ...], Dict[str, str]]:
|
|
|
33
32
|
|
|
34
33
|
DEFAULT_EXTENSIONS, _FORMAT_OF_EXTENSION = _robot_framework_formats()
|
|
35
34
|
|
|
36
|
-
# the language of the Markdown files Robot Framework parses; no editor sends it, the server detects it by file name
|
|
37
|
-
MARKDOWN_LANGUAGE_ID = "robotframework-markdown"
|
|
38
|
-
|
|
39
35
|
|
|
40
36
|
@dataclass(frozen=True)
|
|
41
37
|
class DocumentFormat(CamelSnakeMixin):
|
|
@@ -106,21 +102,6 @@ def parse_include_condition(profile: RobotBaseProfile, root: Path) -> Optional[C
|
|
|
106
102
|
return condition
|
|
107
103
|
|
|
108
104
|
|
|
109
|
-
def markdown_language_definition(profile: RobotBaseProfile, root: Path) -> Optional[LanguageDefinition]:
|
|
110
|
-
"""The language of the Markdown files Robot Framework parses with the profile in the project `root`; `None` when
|
|
111
|
-
no Markdown extension is active."""
|
|
112
|
-
extensions = [f".{e}" for e in markdown_extensions(profile)]
|
|
113
|
-
if not extensions:
|
|
114
|
-
return None
|
|
115
|
-
|
|
116
|
-
return LanguageDefinition(
|
|
117
|
-
id=MARKDOWN_LANGUAGE_ID,
|
|
118
|
-
extensions=extensions,
|
|
119
|
-
extensions_ignore_case=True,
|
|
120
|
-
file_condition=parse_include_condition(profile, root),
|
|
121
|
-
)
|
|
122
|
-
|
|
123
|
-
|
|
124
105
|
def is_markdown_file(path: Path) -> bool:
|
|
125
106
|
"""Whether Robot Framework reads the file with its Markdown parser, from its code blocks.
|
|
126
107
|
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"""The languages RobotCode serves: their ids and their language definitions."""
|
|
2
|
+
|
|
3
|
+
from pathlib import Path
|
|
4
|
+
from typing import Final, Optional
|
|
5
|
+
|
|
6
|
+
from robotcode.core.language import LanguageDefinition
|
|
7
|
+
|
|
8
|
+
from .config.model import RobotBaseProfile
|
|
9
|
+
from .document_formats import markdown_extensions, parse_include_condition
|
|
10
|
+
|
|
11
|
+
ROBOTFRAMEWORK_LANGUAGE_ID = "robotframework"
|
|
12
|
+
|
|
13
|
+
ROBOTFRAMEWORK_LANGUAGE = LanguageDefinition(
|
|
14
|
+
id=ROBOTFRAMEWORK_LANGUAGE_ID,
|
|
15
|
+
extensions=[".robot", ".resource"],
|
|
16
|
+
extensions_ignore_case=True,
|
|
17
|
+
aliases=["Robot Framework", "robotframework"],
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
# the language of the Markdown files Robot Framework parses; no editor sends it, the server detects it by file name
|
|
21
|
+
MARKDOWN_LANGUAGE_ID = "robotframework-markdown"
|
|
22
|
+
|
|
23
|
+
# the languages whose documents hold Robot Framework data
|
|
24
|
+
ROBOT_LANGUAGE_IDS: Final = (ROBOTFRAMEWORK_LANGUAGE_ID, MARKDOWN_LANGUAGE_ID)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def markdown_language_definition(profile: RobotBaseProfile, root: Path) -> Optional[LanguageDefinition]:
|
|
28
|
+
"""The language of the Markdown files Robot Framework parses with the profile in the project `root`; `None` when
|
|
29
|
+
no Markdown extension is active."""
|
|
30
|
+
extensions = [f".{e}" for e in markdown_extensions(profile)]
|
|
31
|
+
if not extensions:
|
|
32
|
+
return None
|
|
33
|
+
|
|
34
|
+
return LanguageDefinition(
|
|
35
|
+
id=MARKDOWN_LANGUAGE_ID,
|
|
36
|
+
extensions=extensions,
|
|
37
|
+
extensions_ignore_case=True,
|
|
38
|
+
file_condition=parse_include_condition(profile, root),
|
|
39
|
+
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: robotcode-robot
|
|
3
|
-
Version: 2.9.0-dev.
|
|
3
|
+
Version: 2.9.0-dev.214
|
|
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
|
|
@@ -27,7 +27,7 @@ Classifier: Topic :: Utilities
|
|
|
27
27
|
Classifier: Typing :: Typed
|
|
28
28
|
Requires-Python: >=3.10
|
|
29
29
|
Requires-Dist: platformdirs>=4.3
|
|
30
|
-
Requires-Dist: robotcode-core==2.9.0-dev.
|
|
30
|
+
Requires-Dist: robotcode-core==2.9.0-dev.214
|
|
31
31
|
Requires-Dist: robotframework>=5.0.0
|
|
32
32
|
Requires-Dist: tomli>=1.1.0; python_version < '3.11'
|
|
33
33
|
Description-Content-Type: text/markdown
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
robotcode/robot/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
robotcode/robot/__version__.py,sha256=
|
|
3
|
-
robotcode/robot/document_formats.py,sha256=
|
|
2
|
+
robotcode/robot/__version__.py,sha256=uSd_IGr6ERx2haC8I41GwovkJcLQLJkFPK2nCwdiFEc,30
|
|
3
|
+
robotcode/robot/document_formats.py,sha256=65dsIzcPkpnNd-WyhkSVSQbHdx6rI7kMq--8AvdDmuM,4842
|
|
4
|
+
robotcode/robot/language_definitions.py,sha256=actqkDp12a11whu2TfKZU3xGk7Hk29HYLDTfeKZ1kqE,1449
|
|
4
5
|
robotcode/robot/py.typed,sha256=bWew9mHgMy8LqMu7RuqQXFXLBxh2CRx0dUbSx-3wE48,27
|
|
5
6
|
robotcode/robot/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
6
7
|
robotcode/robot/config/loader.py,sha256=HLbkZem8JiBuy9Q5naghZddAuMPOn8Tk6UBgN2T3Uyc,9073
|
|
@@ -11,11 +12,11 @@ robotcode/robot/diagnostics/analyzer_result.py,sha256=5pHW5Yf3C3rmaDvmM7tP0y_qwq
|
|
|
11
12
|
robotcode/robot/diagnostics/data_cache.py,sha256=Yi52oQTUBFgcPK0UF3lDAj4mRFqoD_VOtrAUyRWXnrQ,18200
|
|
12
13
|
robotcode/robot/diagnostics/diagnostic_rules.py,sha256=7b4vbGTEuxCef8AHTshV4XAJe75aR4-lJ5QEDyuZtcE,3558
|
|
13
14
|
robotcode/robot/diagnostics/diagnostics_modifier.py,sha256=MftxJlUEDsn9ZiOsBDApXC2N-4OjXHSZj1Y9PXXlSAg,11742
|
|
14
|
-
robotcode/robot/diagnostics/document_cache_helper.py,sha256=
|
|
15
|
+
robotcode/robot/diagnostics/document_cache_helper.py,sha256=GBpXlVqPTtLz6IpnZN6IJdkhIZorVDmse3yRuBQwLRY,37185
|
|
15
16
|
robotcode/robot/diagnostics/entities.py,sha256=vE5szceIL-ANqJPnAbqIebg3kLddE9OPhxwBL9iKP-M,11949
|
|
16
17
|
robotcode/robot/diagnostics/errors.py,sha256=lqHDWrMNy3ZhuEIVxeEhaU0ns8PB6pVTQBfaMqRQ8L4,2733
|
|
17
18
|
robotcode/robot/diagnostics/import_resolver.py,sha256=DZjUOD3uNxFAwsVUqrCTRhColjz9DRPetAvIb_Ccufs,32588
|
|
18
|
-
robotcode/robot/diagnostics/imports_manager.py,sha256=
|
|
19
|
+
robotcode/robot/diagnostics/imports_manager.py,sha256=F5tX-wVojpTitkN-IMhuLH0m1KF_95Lb5-eY6f37m7E,90458
|
|
19
20
|
robotcode/robot/diagnostics/keyword_finder.py,sha256=nwTmjvhyu5H7HHzyk8gt-pny2K2xdH2qCNyKXwwXRnk,18998
|
|
20
21
|
robotcode/robot/diagnostics/library_doc.py,sha256=glFn-FODQBRTXbM_4On2WAb7MwyTK5NvXpfyMDk-x8U,155212
|
|
21
22
|
robotcode/robot/diagnostics/model_helper.py,sha256=_ySXwerkK5xvjWa82T0DFy8jpxRzcaavTJiAHnk2lXQ,29740
|
|
@@ -45,6 +46,6 @@ robotcode/robot/utils/robot_path.py,sha256=ObLP8PqamTZAz5oi0eDXE_dnyZwAPXp4TJYm6
|
|
|
45
46
|
robotcode/robot/utils/stubs.py,sha256=umugZYAyneFNgqRJBRMJPzm0u0B_TH8Sx_y-ykXnxpw,351
|
|
46
47
|
robotcode/robot/utils/variables.py,sha256=9WnP3QqcHdq-zioJ_gJXJobw_2Gcto_rGPCUGmOH9YQ,9829
|
|
47
48
|
robotcode/robot/utils/visitor.py,sha256=nP3O0qh3YYuxR6S8wYJRBFfNwIVgsgohURBlrnFkRYQ,2299
|
|
48
|
-
robotcode_robot-2.9.0.
|
|
49
|
-
robotcode_robot-2.9.0.
|
|
50
|
-
robotcode_robot-2.9.0.
|
|
49
|
+
robotcode_robot-2.9.0.dev214.dist-info/METADATA,sha256=uR5zP682R0dTxD6t6LlpwskTD_CaMAFKaYC6fO_nwC8,2960
|
|
50
|
+
robotcode_robot-2.9.0.dev214.dist-info/WHEEL,sha256=2iZrJkDIkeDh0k9SikKMqFuRP-ua6mb4Ir1AsER4BEw,87
|
|
51
|
+
robotcode_robot-2.9.0.dev214.dist-info/RECORD,,
|
|
File without changes
|