@uipath/maestro-builder-sdk 6.104.0 → 6.105.0
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.
- package/dist/api-index.md +50 -49
- package/dist/api-members.md +158 -157
- package/dist/check.js +3 -2
- package/dist/core/actions.d.ts +23 -3
- package/dist/core/form-field-type.d.ts +55 -1
- package/dist/core/form-field-type.js +101 -29
- package/dist/core/refusals.d.ts +3 -0
- package/dist/core/refusals.js +3 -0
- package/dist/flow-node-type.d.ts +2 -0
- package/dist/nodes/agent/flow/check.js +1 -0
- package/dist/nodes/agent/flow/inline-agent-lift.js +4 -1
- package/dist/nodes/agent/flow/inline-agent.js +12 -1
- package/dist/nodes/data-fabric/flow/check.d.ts +14 -0
- package/dist/nodes/data-fabric/flow/check.js +65 -0
- package/dist/nodes/data-fabric/flow/family.js +5 -2
- package/dist/nodes/hitl/flow/check.js +2 -1
- package/dist/nodes/hitl/flow/node-type.js +16 -4
- package/package.json +2 -2
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* every edge out of an outcome-handle node to.
|
|
14
14
|
*/
|
|
15
15
|
import { Expr, toExpr } from '../../../core/expr.js';
|
|
16
|
-
import { formFieldJsonSchema, formFieldRowLoss, formFieldRowLossMessage, formFieldSettingsSource, formFieldSettingsWire, formFieldVariableName, liftFormFieldSettings, sourceFormFieldType, wireFormFieldType, } from '../../../core/form-field-type.js';
|
|
16
|
+
import { formFieldExtraConflicts, formFieldExtraWire, formFieldJsonSchema, formFieldRowExtra, formFieldRowLoss, formFieldRowLossMessage, formFieldSettingsSource, formFieldSettingsWire, formFieldVariableName, liftFormFieldSettings, sourceFormFieldType, wireFormFieldType, } from '../../../core/form-field-type.js';
|
|
17
17
|
import { isAnswerField } from '../../../core/hitl-answers.js';
|
|
18
18
|
import { OUTCOME_HANDLE_NODE_TYPES, hitlDerivesOutcomeHandles, hitlExitModel, outcomeIdOf, outcomeSlug } from '../../../core/hitl-routing.js';
|
|
19
19
|
import { jsonClone } from '../../../core/json-clone.js';
|
|
@@ -97,7 +97,8 @@ function hitlInputs(inputs, nodeType, ctx) {
|
|
|
97
97
|
// The field's settings — `controlType`, a picker's `options`,
|
|
98
98
|
// `defaultValue`, `colSpan`, `rules`, … — as the canvas stores them on the
|
|
99
99
|
// row, in the platform's key order (#1235, #1250).
|
|
100
|
-
|
|
100
|
+
// Then the row keys the SDK has no option for, as decompile found them (#1989).
|
|
101
|
+
return { ...base, ...formFieldSettingsWire(f), ...formFieldExtraWire(f) };
|
|
101
102
|
});
|
|
102
103
|
const outcomes = (inputs?.outcomes ?? []).map((o, i) => {
|
|
103
104
|
const name = typeof o === 'string' ? o : o?.name;
|
|
@@ -434,6 +435,13 @@ function refuseUnwritable(inputs, typeName, step) {
|
|
|
434
435
|
throw new CompileRefusal('HITL_FIELD_NO_ID', `Human task "${step}" has a form field with no id (fields[${i}]). The id is the key the `
|
|
435
436
|
+ `reviewer's answer comes back under, so a field without one is dropped.`, `id: 'amount'`);
|
|
436
437
|
}
|
|
438
|
+
// An `extra` key may not replace a key the SDK writes from a typed option (#1989).
|
|
439
|
+
const conflicts = formFieldExtraConflicts(f, 'human task');
|
|
440
|
+
if (conflicts.length > 0) {
|
|
441
|
+
throw new CompileRefusal('HITL_FIELD_EXTRA_CONFLICT', `Human task "${step}"'s form field "${id}" sets ${conflicts.map((k) => `\`${k}\``).join(', ')} in \`extra\`, `
|
|
442
|
+
+ `which the SDK writes from the field's own options. \`extra\` carries only the row keys the SDK has no option for.`, `Set ${conflicts.length === 1 ? 'it' : 'them'} with the field's own option${conflicts.length === 1 ? '' : 's'} and drop ${conflicts.length === 1 ? 'it' : 'them'} from \`extra\`, `
|
|
443
|
+
+ `or, for a key decompile put in \`extra\`, change it there and drop the typed one.`);
|
|
444
|
+
}
|
|
437
445
|
// Only an asked row is written with a `variable`, as `vars.<variable>`.
|
|
438
446
|
const variable = f.variable;
|
|
439
447
|
if (variable !== undefined) {
|
|
@@ -644,11 +652,13 @@ function liftHitl(node, typeName, ctx) {
|
|
|
644
652
|
// reports any other spelling.
|
|
645
653
|
const landing = direction === 'output' ? formFieldVariableName(f.variable) : undefined;
|
|
646
654
|
const variable = landing !== undefined && landing !== id ? landing : undefined;
|
|
647
|
-
//
|
|
648
|
-
//
|
|
655
|
+
// A row key the SDK has no option for rides in `extra` (#1989); one it
|
|
656
|
+
// cannot write back at all is reported, never dropped silently: a
|
|
657
|
+
// warning, an error under --strict (#1250).
|
|
649
658
|
const loss = formFieldRowLoss(f, 'human task');
|
|
650
659
|
if (loss.length > 0)
|
|
651
660
|
ctx.lossy(formFieldRowLossMessage(`human task ${JSON.stringify(n.id)}`, id, loss));
|
|
661
|
+
const extra = formFieldRowExtra(f, 'human task');
|
|
652
662
|
return {
|
|
653
663
|
id,
|
|
654
664
|
// serialize defaults a row's label to its id.
|
|
@@ -661,6 +671,7 @@ function liftHitl(node, typeName, ctx) {
|
|
|
661
671
|
...(typeof f.required === 'boolean' && direction !== 'input' ? { required: f.required } : {}),
|
|
662
672
|
...(variable !== undefined ? { variable } : {}),
|
|
663
673
|
...liftFormFieldSettings(f),
|
|
674
|
+
...(Object.keys(extra).length > 0 ? { extra } : {}),
|
|
664
675
|
};
|
|
665
676
|
});
|
|
666
677
|
const outcomeRows = (Array.isArray(schema.outcomes) ? schema.outcomes : []);
|
|
@@ -837,6 +848,7 @@ function printHitl({ inputs }, ctx) {
|
|
|
837
848
|
['required', f.required !== undefined ? String(f.required) : undefined],
|
|
838
849
|
['variable', f.variable !== undefined ? ctx.string(f.variable) : undefined],
|
|
839
850
|
...formFieldSettingsSource(f, ctx.value),
|
|
851
|
+
['extra', f.extra !== undefined ? ctx.value(f.extra) : undefined],
|
|
840
852
|
], ctx));
|
|
841
853
|
const outcomes = h.outcomes.map((o) => (typeof o === 'string' ? ctx.string(o) : obj([
|
|
842
854
|
['name', ctx.string(o.name)],
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uipath/maestro-builder-sdk",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.105.0",
|
|
4
4
|
"description": "Build UiPath Flow, Case, and BPMN artifacts by writing TypeScript.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://docs.uipath.com/maestro",
|
|
@@ -121,5 +121,5 @@
|
|
|
121
121
|
"@types/node": "^22.7.0",
|
|
122
122
|
"esbuild": "^0.28.1"
|
|
123
123
|
},
|
|
124
|
-
"gitref": "
|
|
124
|
+
"gitref": "73e97cc8d46b9b8679fb8f70f7a38262590f51e0"
|
|
125
125
|
}
|