Skip to content

Commit c7f52dc

Browse files
authored
Merge pull request #770 from writer/dev
chore: Merge for release
2 parents 0d2c2e2 + 622a209 commit c7f52dc

9 files changed

Lines changed: 81 additions & 79 deletions

File tree

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"
44

55
[tool.poetry]
66
name = "writer"
7-
version = "0.8.3rc8"
7+
version = "0.8.3rc9"
88
description = "An open-source, Python framework for building feature-rich apps that are fully integrated with the Writer platform."
99
authors = ["Writer, Inc."]
1010
readme = "README.md"

src/ui/src/builder/BuilderSwitcher.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
@click="selectOption('workflows')"
1515
>
1616
<i class="icon material-symbols-outlined"> linked_services </i>
17-
Workflows
17+
Blueprints
1818
</div>
1919
<div
2020
:class="{ active: activeId == 'preview' }"

src/ui/src/builder/sidebar/BuilderSidebarComponentTree.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
@click="addWorkflow"
3434
>
3535
<i class="material-symbols-outlined"> add </i> Add
36-
workflow</WdsButton
36+
blueprint</WdsButton
3737
>
3838
</div>
3939
</template>

src/ui/src/builder/sidebar/BuilderSidebarComponentTreeBranch.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ const name = computed(() => {
139139
return component.value.content?.["element"];
140140
}
141141
if (type == "workflows_workflow") {
142-
return component.value.content?.["key"] || "Workflow";
142+
return component.value.content?.["key"] || "Blueprint";
143143
}
144144
return def.value?.name ?? `Unknown (${component.value.type})`;
145145
});

src/ui/src/builder/sidebar/BuilderSidebarToolkit.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ const searchCount = computed(() => {
9595
9696
const placeholder = computed(() => {
9797
if (activeToolkit.value == "core") return "Core toolkit";
98-
if (activeToolkit.value == "workflows") return "Workflows toolkit";
98+
if (activeToolkit.value == "workflows") return "Blueprints toolkit";
9999
return "Toolkit";
100100
});
101101

src/ui/src/components/workflows/WorkflowsRoot.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const description =
1515
1616
export default {
1717
writer: {
18-
name: "Workflows Root",
18+
name: "Blueprints Root",
1919
toolkit: "workflows",
2020
category: "Root",
2121
description,

src/ui/src/components/workflows/WorkflowsWorkflow.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
@click="handleRun"
6464
>
6565
<i class="material-symbols-outlined">play_arrow</i>
66-
{{ isRunning ? "Running..." : "Run workflow" }}
66+
{{ isRunning ? "Running..." : "Run blueprint" }}
6767
</WdsButton>
6868
</div>
6969
<WorkflowNavigator
@@ -93,7 +93,7 @@ const description =
9393
9494
export default {
9595
writer: {
96-
name: "Workflow",
96+
name: "Blueprint",
9797
toolkit: "workflows",
9898
category: "Root",
9999
description,

src/writer/blocks/runworkflow.py

Lines changed: 41 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -4,54 +4,58 @@
44

55

66
class RunWorkflow(WorkflowBlock):
7-
87
@classmethod
98
def register(cls, type: str):
109
super(RunWorkflow, cls).register(type)
11-
register_abstract_template(type, AbstractTemplate(
12-
baseType="workflows_node",
13-
writer={
14-
"name": "Run workflow",
15-
"description": "Executes a workflow with a given key.",
16-
"category": "Logic",
17-
"fields": {
18-
"workflowKey": {
19-
"name": "Workflow Key",
20-
"type": "Workflow Key",
21-
"validator": {
22-
"type": "string",
23-
"format": "writer#workflowKey",
24-
}
25-
},
26-
"payload": {
27-
"name": "Payload",
28-
"desc": "The value specified will be available using the template syntax i.e. @{payload}",
29-
"default": "{}",
30-
"type": "Text",
31-
"control": "Textarea"
32-
},
33-
},
34-
"outs": {
35-
"success": {
36-
"name": "Success",
37-
"description": "The request was successful.",
38-
"style": "success",
10+
register_abstract_template(
11+
type,
12+
AbstractTemplate(
13+
baseType="workflows_node",
14+
writer={
15+
"name": "Run blueprint",
16+
"description": "Executes a workflow with a given key.",
17+
"category": "Logic",
18+
"fields": {
19+
"workflowKey": {
20+
"name": "Workflow Key",
21+
"type": "Workflow Key",
22+
"validator": {
23+
"type": "string",
24+
"format": "writer#workflowKey",
25+
},
26+
},
27+
"payload": {
28+
"name": "Payload",
29+
"desc": "The value specified will be available using the template syntax i.e. @{payload}",
30+
"default": "{}",
31+
"type": "Text",
32+
"control": "Textarea",
33+
},
3934
},
40-
"error": {
41-
"name": "Error",
42-
"description": "The workflow was executed successfully.",
43-
"style": "error",
35+
"outs": {
36+
"success": {
37+
"name": "Success",
38+
"description": "The request was successful.",
39+
"style": "success",
40+
},
41+
"error": {
42+
"name": "Error",
43+
"description": "The workflow was executed successfully.",
44+
"style": "error",
45+
},
4446
},
4547
},
46-
}
47-
))
48+
),
49+
)
4850

4951
def run(self):
5052
try:
5153
workflow_key = self._get_field("workflowKey")
5254
payload = self._get_field("payload")
53-
expanded_execution_environment = self.execution_environment | { "payload": payload }
54-
return_value = self.runner.run_workflow_by_key(workflow_key, expanded_execution_environment)
55+
expanded_execution_environment = self.execution_environment | {"payload": payload}
56+
return_value = self.runner.run_workflow_by_key(
57+
workflow_key, expanded_execution_environment
58+
)
5559
self.result = return_value
5660
self.outcome = "success"
5761
except BaseException as e:

src/writer/blocks/writernocodeapp.py

Lines changed: 32 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -4,46 +4,44 @@
44

55

66
class WriterNoCodeApp(WorkflowBlock):
7-
87
@classmethod
98
def register(cls, type: str):
109
super(WriterNoCodeApp, cls).register(type)
11-
register_abstract_template(type, AbstractTemplate(
12-
baseType="workflows_node",
13-
writer={
14-
"name": "No-code app",
15-
"description": "Run a no-code app.",
16-
"category": "Writer",
17-
"fields": {
18-
"appId": {
19-
"name": "App Id",
20-
"type": "App Id",
21-
"desc": "The app id can be found in the app's URL. It has a UUID format.",
22-
"validator": {
23-
"type": "string",
24-
"format": "uuid",
25-
}
26-
},
27-
"appInputs": {
28-
"name": "App inputs",
29-
"type": "Key-Value",
30-
"default": "{}"
31-
},
32-
},
33-
"outs": {
34-
"success": {
35-
"name": "Success",
36-
"description": "If the execution was successful.",
37-
"style": "success",
10+
register_abstract_template(
11+
type,
12+
AbstractTemplate(
13+
baseType="workflows_node",
14+
writer={
15+
"name": "No-code agent",
16+
"description": "Run a no-code agent.",
17+
"category": "Writer",
18+
"fields": {
19+
"appId": {
20+
"name": "App Id",
21+
"type": "App Id",
22+
"desc": "The agent id can be found in the agent's URL. It has a UUID format.",
23+
"validator": {
24+
"type": "string",
25+
"format": "uuid",
26+
},
27+
},
28+
"appInputs": {"name": "App inputs", "type": "Key-Value", "default": "{}"},
3829
},
39-
"error": {
40-
"name": "Error",
41-
"description": "If the function raises an Exception.",
42-
"style": "error",
30+
"outs": {
31+
"success": {
32+
"name": "Success",
33+
"description": "If the execution was successful.",
34+
"style": "success",
35+
},
36+
"error": {
37+
"name": "Error",
38+
"description": "If the function raises an Exception.",
39+
"style": "error",
40+
},
4341
},
4442
},
45-
}
46-
))
43+
),
44+
)
4745

4846
def run(self):
4947
try:

0 commit comments

Comments
 (0)