opentf-toolkit-nightly 0.57.0.dev1080__py3-none-any.whl → 0.57.0.dev1093__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.
opentf/commons/schemas.py CHANGED
@@ -46,7 +46,7 @@ GENERATORRESULT = 'opentestfactory.org/v1/GeneratorResult'
46
46
  PROVIDERCOMMAND = 'opentestfactory.org/v1beta1/ProviderCommand'
47
47
  PROVIDERRESULT = 'opentestfactory.org/v1/ProviderResult'
48
48
 
49
- EXECUTIONCOMMAND = 'opentestfactory.org/v1beta1/ExecutionCommand'
49
+ EXECUTIONCOMMAND = 'opentestfactory.org/v1/ExecutionCommand'
50
50
  EXECUTIONRESULT = 'opentestfactory.org/v1alpha1/ExecutionResult'
51
51
  EXECUTIONERROR = 'opentestfactory.org/v1alpha1/ExecutionError'
52
52
 
@@ -0,0 +1,139 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2019-09/schema#",
3
+ "title": "JSON SCHEMA for opentestfactory.org/v1alpha1 ExecutionCommand manifests",
4
+ "type": "object",
5
+ "properties": {
6
+ "apiVersion": {
7
+ "const": "opentestfactory.org/v1"
8
+ },
9
+ "kind": {
10
+ "const": "ExecutionCommand"
11
+ },
12
+ "metadata": {
13
+ "type": "object",
14
+ "properties": {
15
+ "name": {
16
+ "type": "string"
17
+ },
18
+ "namespace": {
19
+ "type": "string",
20
+ "pattern": "^[a-z0-9][a-z0-9-]*$"
21
+ },
22
+ "workflow_id": {
23
+ "type": "string"
24
+ },
25
+ "job_id": {
26
+ "type": "string"
27
+ },
28
+ "job_origin": {
29
+ "type": "array",
30
+ "items": {
31
+ "type": "string"
32
+ }
33
+ },
34
+ "step_id": {
35
+ "type": "string"
36
+ },
37
+ "step_origin": {
38
+ "type": "array",
39
+ "items": {
40
+ "type": "string"
41
+ }
42
+ },
43
+ "step_origin_status": {
44
+ "type": "object",
45
+ "patternProperties": {
46
+ "^[a-zA-Z0-9-]+$": {
47
+ "type": "number"
48
+ }
49
+ }
50
+ },
51
+ "step_sequence_id": {
52
+ "type": "number"
53
+ },
54
+ "labels": {
55
+ "type": "object",
56
+ "patternProperties": {
57
+ "^([a-zA-Z0-9-.]+/)?[a-zA-Z0-9]([a-zA-Z0-9._-]*[a-zA-Z0-9])?$": {
58
+ "type": "string"
59
+ }
60
+ },
61
+ "minProperties": 1,
62
+ "additionalProperties": false
63
+ }
64
+ },
65
+ "additionalProperties": true,
66
+ "required": [
67
+ "name",
68
+ "workflow_id",
69
+ "job_id",
70
+ "job_origin",
71
+ "step_sequence_id"
72
+ ]
73
+ },
74
+ "runs-on": {
75
+ "$ref": "#/definitions/runs-on-maybe-empty-const-array"
76
+ },
77
+ "scripts": {
78
+ "type": "array",
79
+ "items": {
80
+ "type": "string"
81
+ }
82
+ },
83
+ "shell": {
84
+ "type": "string"
85
+ },
86
+ "variables": {
87
+ "$ref": "#/definitions/variables"
88
+ },
89
+ "working-directory": {
90
+ "type": "string"
91
+ }
92
+ },
93
+ "required": [
94
+ "apiVersion",
95
+ "kind",
96
+ "metadata",
97
+ "runs-on",
98
+ "scripts"
99
+ ],
100
+ "additionalProperties": false,
101
+ "definitions": {
102
+ "runs-on-maybe-empty-const-array": {
103
+ "type": "array",
104
+ "items": {
105
+ "type": "string",
106
+ "pattern": "^[a-zA-Z][a-zA-Z0-9-]*$"
107
+ },
108
+ "minItems": 0
109
+ },
110
+ "variables": {
111
+ "type": "object",
112
+ "patternProperties": {
113
+ "^[a-zA-Z0-9_]+$": {
114
+ "oneOf": [
115
+ {
116
+ "type": "string"
117
+ },
118
+ {
119
+ "type": "object",
120
+ "properties": {
121
+ "value": {
122
+ "type": "string"
123
+ },
124
+ "verbatim": {
125
+ "type": "boolean"
126
+ }
127
+ },
128
+ "required": [
129
+ "value"
130
+ ],
131
+ "additionalProperties": false
132
+ }
133
+ ]
134
+ }
135
+ },
136
+ "minProperties": 1
137
+ }
138
+ }
139
+ }
opentf/toolkit/core.py CHANGED
@@ -262,7 +262,7 @@ def export_variable(name: str, value: str, verbatim: bool = False) -> str:
262
262
  encoded = str(base64.b64encode(bytes(value, 'utf8')), 'utf8')
263
263
  marker = make_uuid()
264
264
  temp = make_uuid()
265
- return f'echo @echo {encoded} ^> {marker} ^& @certutil -f -decode {marker} {temp} ^& @del {marker} ^& set /P {name}^=^<{temp} ^& del {temp} >>"%OPENTF_VARIABLES%"'
265
+ return f'@echo @echo {encoded} ^> {marker} ^& @certutil -f -decode {marker} {temp} ^>nul ^& @del {marker} ^& set /P {name}^=^<{temp} ^& del {temp} >>"%OPENTF_VARIABLES%"'
266
266
  return f'@echo set "{name}={value}" >>"%OPENTF_VARIABLES%"'
267
267
  if verbatim:
268
268
  decode_string = f'$(echo {_encode_value(value)} | base64 --decode)'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: opentf-toolkit-nightly
3
- Version: 0.57.0.dev1080
3
+ Version: 0.57.0.dev1093
4
4
  Summary: OpenTestFactory Orchestrator Toolkit
5
5
  Home-page: https://gitlab.com/henixdevelopment/open-source/opentestfactory/python-toolkit
6
6
  Author: Martin Lafaix
@@ -4,10 +4,11 @@ opentf/commons/config.py,sha256=dyus4K5Zdmcftc3Y9Z1YRkzA1KwiRLHoeAlg2_A49QM,7876
4
4
  opentf/commons/datasources.py,sha256=LjIjZbf08u1VllPN4fDss0OAg-_7gtRqgpIZ2tLuiHo,26807
5
5
  opentf/commons/expressions.py,sha256=jM_YKXVOFhvOE2aE2IuacuvxhIsOYTFs2oQkpcbWR6g,19645
6
6
  opentf/commons/pubsub.py,sha256=DVrSara5FRfNdPBwXKUkTobqGki0RPDehylTEFcJnFc,7341
7
- opentf/commons/schemas.py,sha256=P2fJIufoqz4txoeUrwccN_GlqrTx2LBD24s9VtsiTQU,4206
7
+ opentf/commons/schemas.py,sha256=Ya5aNBSvq4oFu6oRQcyM7CHNjTDgaX8O2JrN1S9X1I4,4201
8
8
  opentf/commons/selectors.py,sha256=DEpLgRAr5HXSpSYI4liXP2hLUTvOSexFa9Vfa1xIQTk,7134
9
9
  opentf/schemas/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
10
  opentf/schemas/abac.opentestfactory.org/v1alpha1/Policy.json,sha256=JXsfNAPSEYggeyaDutSQBeG38o4Bmcr70dPLWWeqIh8,2105
11
+ opentf/schemas/opentestfactory.org/v1/ExecutionCommand.json,sha256=UtmAlTaYdPSZDeQnx-ocX8IonyEPWoNmgDkHwQwQxWE,4126
11
12
  opentf/schemas/opentestfactory.org/v1/GeneratorResult.json,sha256=neoFocJGkVTQQPtnG5xnbqNLX8ivFBJbanbbPweId7s,16608
12
13
  opentf/schemas/opentestfactory.org/v1/ProviderResult.json,sha256=Ej4zhCE3rCqCGKcaeAoIHwSJTV_7fw-rAxhJ52qA-Gs,9641
13
14
  opentf/schemas/opentestfactory.org/v1/Workflow.json,sha256=mpWxJfP3aV3sYzVxxWOivD55Top4J5WXTTKBzp7gjIw,22486
@@ -51,9 +52,9 @@ opentf/scripts/launch_java_service.sh,sha256=S0jAaCuv2sZy0Gf2NGBuPX-eD531rcM-b0f
51
52
  opentf/scripts/startup.py,sha256=Da2zo93pBWbdRmj-wgekgLcF94rpNc3ZkbvR8R0w8XY,21279
52
53
  opentf/toolkit/__init__.py,sha256=nbllYXON3Rzd-hU7Cred7r4hPaCPbfSJmoY7cQ6RShc,22589
53
54
  opentf/toolkit/channels.py,sha256=6xcVKHUK2FdyVKIQmPQbakngfVuQDzCcD_lInOdKpro,17171
54
- opentf/toolkit/core.py,sha256=KN6-z8Hmty1thZ-c0mTbcqkF6q1nNrtE8A3F6-wjX4g,9788
55
- opentf_toolkit_nightly-0.57.0.dev1080.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
56
- opentf_toolkit_nightly-0.57.0.dev1080.dist-info/METADATA,sha256=10xoi8J6JtEFB8cInxXghDj0CBBj7FQ5bcMjm_u_uQU,1946
57
- opentf_toolkit_nightly-0.57.0.dev1080.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
58
- opentf_toolkit_nightly-0.57.0.dev1080.dist-info/top_level.txt,sha256=_gPuE6GTT6UNXy1DjtmQSfCcZb_qYA2vWmjg7a30AGk,7
59
- opentf_toolkit_nightly-0.57.0.dev1080.dist-info/RECORD,,
55
+ opentf/toolkit/core.py,sha256=6nud1vqcfjs9swZu_Z-rbvdbejtrlSjOd8eZXIF0ChE,9795
56
+ opentf_toolkit_nightly-0.57.0.dev1093.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
57
+ opentf_toolkit_nightly-0.57.0.dev1093.dist-info/METADATA,sha256=0087ivZhlFClfs_ytPhHZMPsQ134M1jStT6afbJkhB8,1946
58
+ opentf_toolkit_nightly-0.57.0.dev1093.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
59
+ opentf_toolkit_nightly-0.57.0.dev1093.dist-info/top_level.txt,sha256=_gPuE6GTT6UNXy1DjtmQSfCcZb_qYA2vWmjg7a30AGk,7
60
+ opentf_toolkit_nightly-0.57.0.dev1093.dist-info/RECORD,,