@uipath/case-tool 1.207.0-preview.309 → 1.207.0-preview.317

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.
Files changed (57) hide show
  1. package/dist/{authoring-qqev46bh.js → authoring-bbpz96s8.js} +19 -7
  2. package/dist/{business-rule-export-56a4wtat.js → business-rule-export-8atavmgc.js} +1 -1
  3. package/dist/{case-api-bfwmvkb8.js → case-api-1dzfey2w.js} +1 -1
  4. package/dist/{case-bindings-service-5r7c70kz.js → case-bindings-service-dspmg5yt.js} +3 -2
  5. package/dist/{case-debug-solution-projects-56ytn6q9.js → case-debug-solution-projects-k4hnpe9v.js} +1 -1
  6. package/dist/{case-debug-studio-web-service-cbepjsw6.js → case-debug-studio-web-service-fcbc3eq6.js} +2 -2
  7. package/dist/{case-described-io-service-ddsvkz8w.js → case-described-io-service-xmf67njw.js} +2 -2
  8. package/dist/{case-event-trigger-bindings-8nd78j4e.js → case-event-trigger-bindings-e7np51by.js} +3 -2
  9. package/dist/{case-pack-service-xzeevh5m.js → case-pack-service-41navhdw.js} +3 -3
  10. package/dist/{case-splice-service-tpp2syvn.js → case-splice-service-r1z78g04.js} +2 -2
  11. package/dist/{case-validate-service-jbs5dx1t.js → case-validate-service-j5zts9xw.js} +11 -9
  12. package/dist/{connector-enrichment-service-ng3pmfkp.js → connector-enrichment-service-cq8cb488.js} +9 -9
  13. package/dist/{connector-lookup-service-b1wye7n2.js → connector-lookup-service-yc98t9ec.js} +2 -2
  14. package/dist/{connector-task-shape-s2zny4gf.js → connector-task-shape-qamydqnd.js} +2 -2
  15. package/dist/decompile-subscription-hint-b995mwgw.js +164 -0
  16. package/dist/{enrichment-service-dm5kvwhy.js → enrichment-service-j39a1eca.js} +3 -3
  17. package/dist/{index-3jzr9kxp.js → index-0406anvw.js} +2 -2
  18. package/dist/{index-5s9evsb9.js → index-4qst6cty.js} +5 -5
  19. package/dist/{index-wkmh1h6w.js → index-c419fv92.js} +1 -1
  20. package/dist/{index-r16ndadh.js → index-dfqmvdbz.js} +1 -1
  21. package/dist/{index-z763ab07.js → index-xv6ha4j4.js} +1 -1
  22. package/dist/index.js +2 -2
  23. package/dist/{integration-service-fetcher-hr1v19dk.js → integration-service-fetcher-f08y59dm.js} +2 -2
  24. package/dist/{node-sync-service-r6ja3pv2.js → node-sync-service-f7jasxbc.js} +3 -3
  25. package/dist/{packager-tool-x9z4krtr.js → packager-tool-0jxyc8eb.js} +2 -2
  26. package/dist/{packager-tool-f9n5mk1c.js → packager-tool-11y4k1rg.js} +2 -2
  27. package/dist/packager-tool-19nw15jy.js +11 -0
  28. package/dist/{packager-tool-sdf3s26m.js → packager-tool-77cpxq23.js} +1 -1
  29. package/dist/{packager-tool-9pqfpszq.js → packager-tool-7yrbhzz5.js} +1 -1
  30. package/dist/{packager-tool-3hzsw5r7.js → packager-tool-8mjsktc7.js} +8 -6
  31. package/dist/{packager-tool-pq61r2f1.js → packager-tool-brgq2a72.js} +1 -1
  32. package/dist/{packager-tool-fspmvh6g.js → packager-tool-h91jhw3z.js} +1 -1
  33. package/dist/{packager-tool-jhcqampv.js → packager-tool-keyfwxtv.js} +4 -4
  34. package/dist/{packager-tool-p4c1g2sj.js → packager-tool-kn97dw7h.js} +10 -1
  35. package/dist/{packager-tool-jydreskq.js → packager-tool-p1vd39dr.js} +7 -2
  36. package/dist/{packager-tool-t9we85b3.js → packager-tool-pg8620xm.js} +4 -4
  37. package/dist/{packager-tool-exrjwmew.js → packager-tool-rsbzvrtt.js} +1 -1
  38. package/dist/{packager-tool-k08k9g2y.js → packager-tool-s4k3jd8w.js} +2 -2
  39. package/dist/{packager-tool-1473d3cf.js → packager-tool-v54p4t05.js} +2 -2
  40. package/dist/{packager-tool-bw4fsdq4.js → packager-tool-xbgh2w9f.js} +1 -1
  41. package/dist/{packager-tool-83r0jxtd.js → packager-tool-xktgfj5c.js} +1 -1
  42. package/dist/{packager-tool-kpja9yc6.js → packager-tool-z0d3fnwa.js} +43 -43
  43. package/dist/{packager-tool-y69796fy.js → packager-tool-z1fw9a8v.js} +11 -19
  44. package/dist/{packager-tool-225b9qhq.js → packager-tool-z38143ar.js} +1 -1
  45. package/dist/{packager-tool-dv2vtyg0.js → packager-tool-z8anzghw.js} +5 -6
  46. package/dist/{project-artifacts-jaj95t3d.js → project-artifacts-z7cf8atq.js} +1 -1
  47. package/dist/{resourcesSyncService-nph7ap2v.js → resourcesSyncService-qsqjpq21.js} +5 -5
  48. package/dist/{rule-type-declaration-a0fk7fe7.js → rule-type-declaration-89gv5kct.js} +5 -5
  49. package/dist/{sdd-convert-service-2ag3xjpj.js → sdd-convert-service-mpcgtzd3.js} +8 -8
  50. package/dist/{sdd-resolve-siblings-b42j0syn.js → sdd-resolve-siblings-j5dxc62p.js} +1 -1
  51. package/dist/{strict-entry-points-anxeg692.js → strict-entry-points-tr37nfad.js} +4 -3
  52. package/dist/{strict-sdd-audit-z1bg2zr0.js → strict-sdd-audit-xcrvk62x.js} +4 -4
  53. package/dist/{task-type-declaration-b0ejzhc6.js → task-type-declaration-wfvqetdw.js} +3 -3
  54. package/dist/tool.js +2 -2
  55. package/dist/{trigger-enrichment-service-xs7tcw6z.js → trigger-enrichment-service-mrt1q6qy.js} +9 -9
  56. package/dist/{trigger-entry-point-id-hre2ewts.js → trigger-entry-point-id-p405ajdn.js} +1 -1
  57. package/package.json +2 -2
@@ -415,11 +415,14 @@ async function delegateToMaestroBuilderSdk(request) {
415
415
  });
416
416
  return 0;
417
417
  }
418
+ const explainFailure = request.explainFailure;
419
+ const [, explained] = explainFailure ? await catchError2(() => explainFailure(result.message)) : [undefined, undefined];
420
+ const errorCode = explained?.errorCode ?? result.errorCode;
418
421
  OutputFormatter.error({
419
422
  Result: result.result,
420
- ...result.errorCode ? { ErrorCode: result.errorCode } : {},
423
+ ...errorCode ? { ErrorCode: errorCode } : {},
421
424
  Message: result.message,
422
- Instructions: result.instructions,
425
+ Instructions: explained?.instructions ?? result.instructions,
423
426
  ...result.data ? { Data: pascalCaseDataKeys(result.data) } : {}
424
427
  });
425
428
  return result.exitCode;
@@ -843,7 +846,7 @@ var ARTIFACT = {
843
846
  case: { artifact: "caseplan.json", source: ".case.ts" },
844
847
  bpmn: { artifact: ".bpmn", source: ".bpmn.ts" }
845
848
  };
846
- var registerDecompileCommand = (program, family) => {
849
+ var registerDecompileCommand = (program, family, hooks = {}) => {
847
850
  const command = program.command("decompile <input>").description(`Convert a ${ARTIFACT[family].artifact} artifact to authored TypeScript.`).option("-o, --output-file <file>", `Output ${ARTIFACT[family].source} path`).option("--import <specifier>", "SDK import specifier in generated source");
848
851
  addDeprecatedOptionAlias(command, "--output <file>", "--output-file");
849
852
  if (family === "flow") {
@@ -858,7 +861,7 @@ var registerDecompileCommand = (program, family) => {
858
861
  command.option("--no-pipeline", "Do not emit a brownfield pipeline helper");
859
862
  }
860
863
  const example = DECOMPILE_EXAMPLES[family];
861
- command.examples(sdkCliExample(family, "decompile", `Convert a ${family} artifact back to authored TypeScript`, `uip maestro ${family} decompile ${example.input} --output-file ${example.output}${example.extra ?? ""}`, example.result)).trackedAction(processContext, async (_input, options, cmd) => {
864
+ command.examples(sdkCliExample(family, "decompile", `Convert a ${family} artifact back to authored TypeScript`, `uip maestro ${family} decompile ${example.input} --output-file ${example.output}${example.extra ?? ""}`, example.result)).trackedAction(processContext, async (input, options, cmd) => {
862
865
  const parsed = [];
863
866
  addValue(parsed, "-o", options.outputFile);
864
867
  addValue(parsed, "--import", options.import);
@@ -874,11 +877,15 @@ var registerDecompileCommand = (program, family) => {
874
877
  addValue(parsed, "--style", options.style);
875
878
  addValue(parsed, "--scripts", options.scripts);
876
879
  const { argv, passthrough } = delegateArgv(cmd, parsed);
880
+ const explain = hooks.explainFailure;
877
881
  const code = await delegateToMaestroBuilderSdk({
878
882
  family,
879
883
  commandVerb: "decompile",
880
884
  argv,
881
885
  ...passthrough ? { passthrough } : {},
886
+ ...explain ? {
887
+ explainFailure: (message) => explain(input, message)
888
+ } : {},
882
889
  ...options.scripts ? {
883
890
  requiresSdkVersion: {
884
891
  version: FLOW_DECOMPILE_SCRIPTS_VERSION,
@@ -1017,7 +1024,7 @@ var syncCompiledCaseBindings = async (data) => {
1017
1024
  const path = typeof reported === "string" ? reported : undefined;
1018
1025
  if (path === undefined)
1019
1026
  return { ok: true };
1020
- const { bindingIdentity, bindingsV2PathFor, syncCaseBindings } = await import("./case-bindings-service-5r7c70kz.js");
1027
+ const { bindingIdentity, bindingsV2PathFor, syncCaseBindings } = await import("./case-bindings-service-dspmg5yt.js");
1021
1028
  const fs = getFileSystem2();
1022
1029
  const sidecar = bindingsV2PathFor(path);
1023
1030
  if (!await fs.exists(sidecar)) {
@@ -1077,11 +1084,16 @@ var registerCaseAuthoringCommands = (program) => {
1077
1084
  afterSuccess: syncCompiledCaseBindings
1078
1085
  });
1079
1086
  registerCheckCommand(program, "case");
1080
- registerDecompileCommand(program, "case");
1087
+ registerDecompileCommand(program, "case", {
1088
+ explainFailure: async (input, message) => {
1089
+ const { explainCaseDecompileFailure } = await import("./decompile-subscription-hint-b995mwgw.js");
1090
+ return explainCaseDecompileFailure(input, message);
1091
+ }
1092
+ });
1081
1093
  registerMergeCommand(program, "case");
1082
1094
  };
1083
1095
  export {
1084
1096
  registerCaseAuthoringCommands
1085
1097
  };
1086
1098
 
1087
- //# debugId=58347904F8219F9C64756E2164756E21
1099
+ //# debugId=5CA1FF08BE3CD6F664756E2164756E21
@@ -7,7 +7,7 @@ async function readBusinessRuleEntryPointAsync(entry) {
7
7
  getRemoteResourceClients,
8
8
  readSpecEntryPoints,
9
9
  toCatalogReference
10
- } = await import("./index-r16ndadh.js");
10
+ } = await import("./index-dfqmvdbz.js");
11
11
  await getSolutionAuthContext({});
12
12
  const { importer } = getRemoteResourceClients(await createResourceBuilderServices());
13
13
  const folder = entry.folders?.[0];
@@ -11,7 +11,7 @@ import {
11
11
  ReleasesApi2,
12
12
  createOrchestratorConfig2,
13
13
  resolveFolder2
14
- } from "./packager-tool-p4c1g2sj.js";
14
+ } from "./packager-tool-kn97dw7h.js";
15
15
  import"./packager-tool-n3r5apbb.js";
16
16
  import"./packager-tool-c0pavv0s.js";
17
17
  import {
@@ -23,10 +23,11 @@ import {
23
23
  diffBindingsV22,
24
24
  hasBindingsV2Difference2
25
25
  } from "./packager-tool-qzyb1eac.js";
26
+ import"./packager-tool-p1vd39dr.js";
26
27
  import {
27
28
  readEntryPointIds2,
28
29
  deriveEventTriggerResources2
29
- } from "./packager-tool-dv2vtyg0.js";
30
+ } from "./packager-tool-z8anzghw.js";
30
31
  import"./packager-tool-68648y3j.js";
31
32
 
32
33
  // src/services/case-bindings-service.ts
@@ -475,4 +476,4 @@ export {
475
476
  syncCaseBindings
476
477
  };
477
478
 
478
- //# debugId=B294578EFB32B17D64756E2164756E21
479
+ //# debugId=06122EE0E5E8281864756E2164756E21
@@ -1,6 +1,6 @@
1
1
  // src/services/case-debug-solution-projects.ts
2
2
  var caseSolutionProjects = async (solutionDir, uploaded, solutionId) => {
3
- const { readSolutionAt } = await import("./index-5s9evsb9.js");
3
+ const { readSolutionAt } = await import("./index-4qst6cty.js");
4
4
  const context = await readSolutionAt(solutionDir);
5
5
  if (context === null)
6
6
  return [];
@@ -28,7 +28,7 @@ import {
28
28
  import {
29
29
  buildSolutionPackageFromDir2,
30
30
  uploadOrOverwriteSolution2
31
- } from "./packager-tool-1473d3cf.js";
31
+ } from "./packager-tool-v54p4t05.js";
32
32
  import {
33
33
  findSolutionFile2,
34
34
  updateSolutionFile2
@@ -127,7 +127,7 @@ class CaseDebugStudioWebService {
127
127
  entryPoint,
128
128
  projectType: "CaseManagement",
129
129
  buildSolutionProjects: async (uploadedProjects, solutionId) => {
130
- const { caseSolutionProjects } = await import("./case-debug-solution-projects-56ytn6q9.js");
130
+ const { caseSolutionProjects } = await import("./case-debug-solution-projects-k4hnpe9v.js");
131
131
  return caseSolutionProjects(solutionDir, uploadedProjects, solutionId);
132
132
  },
133
133
  apiConfig,
@@ -5,11 +5,11 @@ import {
5
5
  isExpressionNamespace
6
6
  } from "./packager-tool-mk9fmzdy.js";
7
7
  import"./packager-tool-00ck60cc.js";
8
- import"./packager-tool-jydreskq.js";
8
+ import"./packager-tool-p1vd39dr.js";
9
9
  import {
10
10
  RESULT_OUTPUT_SOURCE,
11
11
  outputSourceFor
12
- } from "./packager-tool-bw4fsdq4.js";
12
+ } from "./packager-tool-xbgh2w9f.js";
13
13
  import"./packager-tool-p64w2wrt.js";
14
14
  import"./packager-tool-j8mnpsv8.js";
15
15
  import {
@@ -2,8 +2,9 @@ import {
2
2
  entryPointIdsByNode2,
3
3
  readEntryPointIds2,
4
4
  deriveEventTriggerResources2
5
- } from "./packager-tool-dv2vtyg0.js";
5
+ } from "./packager-tool-z8anzghw.js";
6
6
  import"./packager-tool-qzyb1eac.js";
7
+ import"./packager-tool-p1vd39dr.js";
7
8
  import"./packager-tool-68648y3j.js";
8
9
  import"./packager-tool-00ck60cc.js";
9
10
  import"./packager-tool-j8mnpsv8.js";
@@ -14,4 +15,4 @@ export {
14
15
  readEntryPointIds2 as readEntryPointIds
15
16
  };
16
17
 
17
- //# debugId=E3A6E343695C0F3464756E2164756E21
18
+ //# debugId=2FC7A6A93EDF58D664756E2164756E21
@@ -152,7 +152,7 @@ Packing Case project...
152
152
  logger.info(`BPMN file written to ${bpmnFilePath}`);
153
153
  }
154
154
  async refuseInvalidSla(projectPath, casePlanFileName) {
155
- const { CaseValidateService } = await import("./case-validate-service-jbs5dx1t.js");
155
+ const { CaseValidateService } = await import("./case-validate-service-j5zts9xw.js");
156
156
  const result = await new CaseValidateService().validateFileUsingSDK(this.fs.path.join(projectPath, casePlanFileName));
157
157
  const found = slaErrors(result.issues);
158
158
  if (found.length === 0)
@@ -194,8 +194,8 @@ ${found.map(issueLine).join(`
194
194
  { entryPointIdsByNode },
195
195
  { currentTriggers, entryPointIdOf, stampEntryPointIds }
196
196
  ] = await Promise.all([
197
- import("./case-event-trigger-bindings-8nd78j4e.js"),
198
- import("./trigger-entry-point-id-hre2ewts.js")
197
+ import("./case-event-trigger-bindings-e7np51by.js"),
198
+ import("./trigger-entry-point-id-p405ajdn.js")
199
199
  ]);
200
200
  const document = JSON.parse(plan);
201
201
  const ids = entryPointIdsByNode({ entryPoints: entries });
@@ -10,13 +10,13 @@ import {
10
10
  CONNECTOR_CALL_TASK_TYPES,
11
11
  isMappedExecution,
12
12
  serviceTypeFor
13
- } from "./packager-tool-jydreskq.js";
13
+ } from "./packager-tool-p1vd39dr.js";
14
14
  import {
15
15
  BINDING_REFERENCE_PREFIX
16
16
  } from "./packager-tool-nfhtwa72.js";
17
17
  import {
18
18
  camelizeDisplayName
19
- } from "./packager-tool-bw4fsdq4.js";
19
+ } from "./packager-tool-xbgh2w9f.js";
20
20
  import"./packager-tool-p64w2wrt.js";
21
21
  import"./packager-tool-j8mnpsv8.js";
22
22
  import"./packager-tool-0nbcqyvp.js";
@@ -17,11 +17,11 @@ import {
17
17
  serviceTypesFor,
18
18
  isMappedExecution,
19
19
  serviceTypeFor
20
- } from "./packager-tool-jydreskq.js";
20
+ } from "./packager-tool-p1vd39dr.js";
21
21
  import {
22
22
  RESULT_OUTPUT_NAME,
23
23
  RESULT_OUTPUT_SOURCE
24
- } from "./packager-tool-bw4fsdq4.js";
24
+ } from "./packager-tool-xbgh2w9f.js";
25
25
  import {
26
26
  contextEntries,
27
27
  contextEntry,
@@ -33,7 +33,7 @@ import {
33
33
  } from "./packager-tool-2xemp3b1.js";
34
34
  import {
35
35
  validateIntSvcNode
36
- } from "./packager-tool-jhcqampv.js";
36
+ } from "./packager-tool-keyfwxtv.js";
37
37
  import"./packager-tool-n3r5apbb.js";
38
38
  import"./packager-tool-c0pavv0s.js";
39
39
  import {
@@ -53,11 +53,13 @@ import {
53
53
  BINDING_REFERENCE_PREFIX
54
54
  } from "./packager-tool-nfhtwa72.js";
55
55
  import {
56
- readRegistryLedger,
56
+ readRegistryLedger
57
+ } from "./packager-tool-z1fw9a8v.js";
58
+ import {
57
59
  VARIABLE_GROUPS,
58
60
  DECLARING_GROUPS,
59
61
  asRecord
60
- } from "./packager-tool-y69796fy.js";
62
+ } from "./packager-tool-19nw15jy.js";
61
63
  import {
62
64
  VALID_TASK_ENTRY_RULE_TYPES,
63
65
  VALID_STAGE_ENTRY_RULE_TYPES,
@@ -2564,7 +2566,7 @@ Validating: ${absolutePath}
2564
2566
  const sddPath = this.fs.path.resolve(options.sddPath);
2565
2567
  if (await this.fs.exists(sddPath)) {
2566
2568
  const sddText = await this.fs.readFile(sddPath, "utf-8") ?? "";
2567
- const { auditCaseplanAgainstSdd } = await import("./strict-sdd-audit-z1bg2zr0.js");
2569
+ const { auditCaseplanAgainstSdd } = await import("./strict-sdd-audit-xcrvk62x.js");
2568
2570
  issues.push(...auditCaseplanAgainstSdd(parsed, sddText, this.fs.path.basename(sddPath), await findRegistryLedger(this.fs, absolutePath)));
2569
2571
  } else {
2570
2572
  issues.push({
@@ -2607,13 +2609,13 @@ Validating: ${absolutePath}
2607
2609
  if (parseError) {
2608
2610
  return unreadable(`is not JSON (${parseError.message})`);
2609
2611
  }
2610
- const { checkEntryPoints } = await import("./strict-entry-points-anxeg692.js");
2612
+ const { checkEntryPoints } = await import("./strict-entry-points-tr37nfad.js");
2611
2613
  return checkEntryPoints(document, parsed, this.fs.path.basename(candidate), this.fs.path.basename(casePlanPath));
2612
2614
  }
2613
2615
  return [];
2614
2616
  }
2615
2617
  async checkBindingsSidecar(casePlanPath, parsed) {
2616
- const { compareCaseBindingsV2 } = await import("./case-bindings-service-5r7c70kz.js");
2618
+ const { compareCaseBindingsV2 } = await import("./case-bindings-service-dspmg5yt.js");
2617
2619
  const [error, comparison] = await catchError2(compareCaseBindingsV2(casePlanPath, parsed));
2618
2620
  if (error || comparison === undefined)
2619
2621
  return [];
@@ -2717,4 +2719,4 @@ export {
2717
2719
  CaseValidateService
2718
2720
  };
2719
2721
 
2720
- //# debugId=A9B7D9A95742658464756E2164756E21
2722
+ //# debugId=1ACCD2CCAC6593BC64756E2164756E21
@@ -11,30 +11,30 @@ import {
11
11
  extractFieldDefinitions2,
12
12
  enrichConnectorRegistryEntry2,
13
13
  enrichConnectorActivity2
14
- } from "./packager-tool-t9we85b3.js";
15
- import"./packager-tool-bw4fsdq4.js";
16
- import"./packager-tool-jydreskq.js";
17
- import"./packager-tool-83r0jxtd.js";
14
+ } from "./packager-tool-pg8620xm.js";
15
+ import"./packager-tool-xbgh2w9f.js";
16
+ import"./packager-tool-xktgfj5c.js";
18
17
  import"./packager-tool-j53d4vv1.js";
19
18
  import"./packager-tool-ef43cy32.js";
20
19
  import"./packager-tool-4seehsme.js";
21
- import"./packager-tool-sdf3s26m.js";
20
+ import"./packager-tool-77cpxq23.js";
22
21
  import"./packager-tool-36vkdb3h.js";
23
22
  import"./packager-tool-xb16e3tz.js";
24
- import"./packager-tool-9pqfpszq.js";
25
- import"./packager-tool-jhcqampv.js";
23
+ import"./packager-tool-7yrbhzz5.js";
24
+ import"./packager-tool-keyfwxtv.js";
26
25
  import"./packager-tool-c9h0rwgv.js";
27
- import"./packager-tool-p4c1g2sj.js";
26
+ import"./packager-tool-kn97dw7h.js";
28
27
  import"./packager-tool-5s476jdt.js";
29
28
  import"./packager-tool-hrd44w8g.js";
30
29
  import"./packager-tool-jv5byaww.js";
31
- import"./packager-tool-x9z4krtr.js";
30
+ import"./packager-tool-0jxyc8eb.js";
32
31
  import"./packager-tool-rzxnm9yj.js";
33
32
  import"./packager-tool-zte9svtn.js";
34
33
  import"./packager-tool-4w7nzx18.js";
35
34
  import"./packager-tool-wvf6b31h.js";
36
35
  import"./packager-tool-c0pavv0s.js";
37
36
  import"./packager-tool-n3r5apbb.js";
37
+ import"./packager-tool-p1vd39dr.js";
38
38
  import"./packager-tool-68648y3j.js";
39
39
  import"./packager-tool-00ck60cc.js";
40
40
  import"./packager-tool-j8mnpsv8.js";
@@ -2,9 +2,9 @@ import {
2
2
  lookupTypeCacheEntry2,
3
3
  caseTypeCacheSource2,
4
4
  fetchConnectorConnections2
5
- } from "./packager-tool-83r0jxtd.js";
5
+ } from "./packager-tool-xktgfj5c.js";
6
6
  import"./packager-tool-j53d4vv1.js";
7
- import"./packager-tool-jhcqampv.js";
7
+ import"./packager-tool-keyfwxtv.js";
8
8
  import"./packager-tool-jv5byaww.js";
9
9
  import"./packager-tool-c0pavv0s.js";
10
10
  import"./packager-tool-n3r5apbb.js";
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  designerConnectorShape2,
3
3
  designerShapeConnectorTasks2
4
- } from "./packager-tool-pq61r2f1.js";
5
- import"./packager-tool-jydreskq.js";
4
+ } from "./packager-tool-brgq2a72.js";
5
+ import"./packager-tool-p1vd39dr.js";
6
6
  import"./packager-tool-68648y3j.js";
7
7
  import"./packager-tool-00ck60cc.js";
8
8
  export {
@@ -0,0 +1,164 @@
1
+ import {
2
+ getFileSystem2
3
+ } from "./packager-tool-p64w2wrt.js";
4
+ import {
5
+ catchError2
6
+ } from "./packager-tool-j8mnpsv8.js";
7
+ import"./packager-tool-00ck60cc.js";
8
+ import {
9
+ SERVICE_TYPE_BY_TASK,
10
+ EVENT_TRIGGER_SERVICE_TYPE,
11
+ TRIGGER_NODE_TYPES
12
+ } from "./packager-tool-p1vd39dr.js";
13
+ import {
14
+ asRecord
15
+ } from "./packager-tool-19nw15jy.js";
16
+ import"./packager-tool-68648y3j.js";
17
+
18
+ // src/services/decompile-subscription-hint.ts
19
+ var UNCONFIGURED_SUBSCRIPTION = /subscription metadata configuration/;
20
+ var SUBSCRIPTION_SERVICE_TYPES = new Set([
21
+ EVENT_TRIGGER_SERVICE_TYPE,
22
+ SERVICE_TYPE_BY_TASK["wait-for-connector"]
23
+ ]);
24
+ var GUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
25
+ var LISTED_LIMIT = 3;
26
+ var text = (value) => typeof value === "string" && value.trim() !== "" ? value : undefined;
27
+ var guid = (value) => {
28
+ const id = text(value);
29
+ return id !== undefined && GUID.test(id) ? id : undefined;
30
+ };
31
+ var nonEmpty = (value) => Array.isArray(value) && value.length > 0;
32
+ var contextValue = (context, name) => context.map(asRecord).find((entry) => entry?.name === name);
33
+ var acceptedWithoutConfiguration = (record) => {
34
+ const resolved = ["inputs", "outputs", "bindings"].some((name) => nonEmpty(record[name]));
35
+ if (resolved)
36
+ return false;
37
+ if (record.context === undefined)
38
+ return true;
39
+ const context = Array.isArray(record.context) ? record.context : [];
40
+ const names = new Set(context.map((entry) => asRecord(entry)?.name));
41
+ return context.length === 2 && names.has("connectorKey") && names.has("operation");
42
+ };
43
+ var unconfigured = (bag) => {
44
+ const record = asRecord(bag);
45
+ if (record === undefined || !SUBSCRIPTION_SERVICE_TYPES.has(String(record.serviceType)) || acceptedWithoutConfiguration(record)) {
46
+ return;
47
+ }
48
+ const context = Array.isArray(record.context) ? record.context : [];
49
+ const property = asRecord(asRecord(asRecord(contextValue(context, "metadata"))?.body)?.activityPropertyConfiguration);
50
+ const configuration = property?.configuration;
51
+ if (typeof configuration === "string" && configuration.startsWith("=jsonString:")) {
52
+ return;
53
+ }
54
+ return {
55
+ hasInputs: nonEmpty(record.inputs),
56
+ activityTypeId: guid(property?.uiPathActivityTypeId),
57
+ connectionId: guid(asRecord(contextValue(context, "resourceKey"))?.value)
58
+ };
59
+ };
60
+ var unconfiguredSubscriptions = (plan) => {
61
+ const found = [];
62
+ const rules = (conditions, where) => {
63
+ if (!Array.isArray(conditions))
64
+ return;
65
+ for (const condition of conditions) {
66
+ const groups = asRecord(condition)?.rules;
67
+ for (const group of Array.isArray(groups) ? groups : []) {
68
+ for (const rule of Array.isArray(group) ? group : [group]) {
69
+ const gap = unconfigured(asRecord(rule)?.uipath);
70
+ if (gap)
71
+ found.push({ kind: "rule", label: where, ...gap });
72
+ }
73
+ }
74
+ }
75
+ };
76
+ const nodes = Array.isArray(plan.nodes) ? plan.nodes : [];
77
+ for (const raw of nodes) {
78
+ const node = asRecord(raw);
79
+ const data = asRecord(node?.data);
80
+ const type = String(node?.type ?? "");
81
+ const name = text(data?.label) ?? text(node?.displayName) ?? String(node?.id);
82
+ if (TRIGGER_NODE_TYPES.has(type)) {
83
+ const gap = unconfigured(type === "uipath.case.trigger" ? data?.inputs : data?.uipath);
84
+ if (gap) {
85
+ found.push({
86
+ kind: "trigger",
87
+ label: `trigger "${name}"`,
88
+ ...gap
89
+ });
90
+ }
91
+ continue;
92
+ }
93
+ if (!type.endsWith("Stage"))
94
+ continue;
95
+ rules(data?.entryConditions, `an entry rule of stage "${name}"`);
96
+ rules(data?.exitConditions, `an exit rule of stage "${name}"`);
97
+ const lanes = Array.isArray(data?.tasks) ? data.tasks : [];
98
+ for (const lane of lanes) {
99
+ for (const rawTask of Array.isArray(lane) ? lane : []) {
100
+ const task = asRecord(rawTask);
101
+ const taskName = text(task?.displayName) ?? String(task?.id ?? "?");
102
+ const gap = unconfigured(task?.data);
103
+ if (gap) {
104
+ found.push({
105
+ kind: "task",
106
+ label: `task "${taskName}"`,
107
+ ...gap
108
+ });
109
+ }
110
+ rules(task?.entryConditions, `an entry rule of task "${taskName}"`);
111
+ }
112
+ }
113
+ }
114
+ return found;
115
+ };
116
+ var specCommands = (gaps) => {
117
+ const commands = new Set;
118
+ for (const gap of gaps) {
119
+ if (gap.activityTypeId === undefined || gap.connectionId === undefined)
120
+ continue;
121
+ const kind = gap.kind === "trigger" ? "start" : "wait-for";
122
+ commands.add(`uip maestro case spec --type trigger --trigger-kind ${kind} --activity-type-id ${gap.activityTypeId} --connection-id ${gap.connectionId} --output json`);
123
+ }
124
+ return [...commands].slice(0, LISTED_LIMIT);
125
+ };
126
+ var subscriptionInstructions = (gaps) => {
127
+ const listed = gaps.slice(0, LISTED_LIMIT).map((gap) => gap.label).join(", ");
128
+ const more = gaps.length > LISTED_LIMIT ? ` and ${gaps.length - LISTED_LIMIT} more` : "";
129
+ const commands = specCommands(gaps);
130
+ const fetch = commands.length > 0 ? `Fetch it with ${commands.map((command) => `\`${command}\``).join(", ")}` : "Fetch it with `uip maestro case spec --type trigger` for the subscription's activity type id and connection id";
131
+ const unresolvedIds = gaps.some((gap) => gap.activityTypeId === undefined || gap.connectionId === undefined) ? " (`--trigger-kind wait-for` for a task or rule, `start` for a trigger; the plan states no usable id for at least one of them)" : "";
132
+ const parts = [
133
+ `${gaps.length} connector subscription(s) carry no \`metadata.activityPropertyConfiguration.configuration\`, which decompile reads: ${listed}${more}. \`sdd convert\` leaves it for a tenant to fill.`,
134
+ `${fetch}${unresolvedIds}, and copy the result's \`Data.CaseShape.context\` \`metadata\` entry over the subscription's own \`metadata\` context entry (a task's \`data.context\`, a rule's \`uipath.context\`).`,
135
+ "Leave its inputs as they are."
136
+ ];
137
+ if (gaps.some((gap) => gap.kind === "rule" && !gap.hasInputs)) {
138
+ parts.push('A rule with no `uipath.inputs` takes one row, `{ "name": "body", "type": "json", "body": {} }`, for a subscription with no parameters.');
139
+ }
140
+ if (gaps.some((gap) => gap.kind === "trigger")) {
141
+ parts.push("A trigger's start spec may have no `context`; then set the trigger up in Studio Web.");
142
+ }
143
+ parts.push("Then run decompile again.");
144
+ return parts.join(" ");
145
+ };
146
+ var explainCaseDecompileFailure = async (input, message) => {
147
+ if (!UNCONFIGURED_SUBSCRIPTION.test(message))
148
+ return;
149
+ const [, plan] = await catchError2(async () => asRecord(JSON.parse(await getFileSystem2().readFile(input, "utf-8") ?? "")));
150
+ if (plan === undefined)
151
+ return;
152
+ const gaps = unconfiguredSubscriptions(plan);
153
+ if (gaps.length === 0)
154
+ return;
155
+ return {
156
+ instructions: subscriptionInstructions(gaps),
157
+ errorCode: "invalid_argument"
158
+ };
159
+ };
160
+ export {
161
+ explainCaseDecompileFailure
162
+ };
163
+
164
+ //# debugId=D261A0135A4C286664756E2164756E21
@@ -7,7 +7,7 @@ import {
7
7
  getAuthContext2
8
8
  } from "./packager-tool-c0pavv0s.js";
9
9
  import"./packager-tool-00ck60cc.js";
10
- import"./packager-tool-jydreskq.js";
10
+ import"./packager-tool-p1vd39dr.js";
11
11
  import {
12
12
  transformSchemaToVariables,
13
13
  convertActionArgsToVariables,
@@ -17,7 +17,7 @@ import {
17
17
  BUSINESS_RULE_TASK_VERSION,
18
18
  buildErrorOutput,
19
19
  addVarIdsToInputsOutputs
20
- } from "./packager-tool-bw4fsdq4.js";
20
+ } from "./packager-tool-xbgh2w9f.js";
21
21
  import {
22
22
  loadResourceIndex
23
23
  } from "./packager-tool-j53d4vv1.js";
@@ -402,7 +402,7 @@ async function enrichBusinessRuleType(id) {
402
402
  if (!entry) {
403
403
  throw new Error(`No business-rule entry found with entityKey "${id}" in businessRule-index.json`);
404
404
  }
405
- const { readBusinessRuleEntryPointAsync } = await import("./business-rule-export-56a4wtat.js");
405
+ const { readBusinessRuleEntryPointAsync } = await import("./business-rule-export-8atavmgc.js");
406
406
  const exported = await readBusinessRuleEntryPointAsync(entry);
407
407
  if (!exported) {
408
408
  throw new Error("Describing a business rule needs the Node CLI: the browser build cannot export a rule's contract.");
@@ -20,7 +20,7 @@ import {
20
20
  findTriggerDesignAction,
21
21
  triggerEventParameters,
22
22
  runTriggerDesignAction
23
- } from "./packager-tool-jhcqampv.js";
23
+ } from "./packager-tool-keyfwxtv.js";
24
24
  import"./packager-tool-n3r5apbb.js";
25
25
  import"./packager-tool-c0pavv0s.js";
26
26
  import"./packager-tool-p64w2wrt.js";
@@ -43,7 +43,7 @@ import {
43
43
  assertConnectionConnector2,
44
44
  fetchConnectionInfo2,
45
45
  fetchConnectorMetadata2
46
- } from "./packager-tool-9pqfpszq.js";
46
+ } from "./packager-tool-7yrbhzz5.js";
47
47
  import"./packager-tool-hrd44w8g.js";
48
48
  import {
49
49
  findSolutionFromCwd2
@@ -1,21 +1,21 @@
1
1
  import"./packager-tool-ef43cy32.js";
2
2
  import"./packager-tool-4seehsme.js";
3
- import"./packager-tool-sdf3s26m.js";
3
+ import"./packager-tool-77cpxq23.js";
4
4
  import"./packager-tool-36vkdb3h.js";
5
5
  import"./packager-tool-xb16e3tz.js";
6
6
  import {
7
7
  fetchConnectorMetadata2
8
- } from "./packager-tool-9pqfpszq.js";
9
- import"./packager-tool-jhcqampv.js";
8
+ } from "./packager-tool-7yrbhzz5.js";
9
+ import"./packager-tool-keyfwxtv.js";
10
10
  import"./packager-tool-c9h0rwgv.js";
11
- import"./packager-tool-p4c1g2sj.js";
11
+ import"./packager-tool-kn97dw7h.js";
12
12
  import {
13
13
  solutionSearchDirs2,
14
14
  readSolutionAt2,
15
15
  findSolutionFromCwd2
16
16
  } from "./packager-tool-5s476jdt.js";
17
17
  import"./packager-tool-hrd44w8g.js";
18
- import"./packager-tool-x9z4krtr.js";
18
+ import"./packager-tool-0jxyc8eb.js";
19
19
  import"./packager-tool-rzxnm9yj.js";
20
20
  import"./packager-tool-zte9svtn.js";
21
21
  import"./packager-tool-4w7nzx18.js";
@@ -7,7 +7,7 @@ import {
7
7
  resolveFolder2,
8
8
  quoteODataStringLiteral2,
9
9
  ReleaseNotFoundError2
10
- } from "./packager-tool-p4c1g2sj.js";
10
+ } from "./packager-tool-kn97dw7h.js";
11
11
  import"./packager-tool-c0pavv0s.js";
12
12
  import"./packager-tool-n3r5apbb.js";
13
13
  import"./packager-tool-j8mnpsv8.js";
@@ -64,7 +64,7 @@ import {
64
64
  import {
65
65
  UsersApi2,
66
66
  createApiClient3
67
- } from "./packager-tool-p4c1g2sj.js";
67
+ } from "./packager-tool-kn97dw7h.js";
68
68
  import {
69
69
  getSolutionAuthContext2
70
70
  } from "./packager-tool-kh9gs4d5.js";
@@ -3,7 +3,7 @@ import {
3
3
  isSolutionUploadHttpError2,
4
4
  buildSolutionUploadFailureOutput2,
5
5
  uploadOrOverwriteSolution2
6
- } from "./packager-tool-1473d3cf.js";
6
+ } from "./packager-tool-v54p4t05.js";
7
7
  import {
8
8
  prepareProjectLocation2,
9
9
  findSolutionFile2,
package/dist/index.js CHANGED
@@ -8,11 +8,11 @@ import"./packager-tool-wvf6b31h.js";
8
8
  import"./packager-tool-4w7nzx18.js";
9
9
  import"./packager-tool-n3r5apbb.js";
10
10
  import"./packager-tool-c0pavv0s.js";
11
- import"./packager-tool-x9z4krtr.js";
11
+ import"./packager-tool-0jxyc8eb.js";
12
12
  import {
13
13
  metadata2,
14
14
  registerCommands2
15
- } from "./packager-tool-kpja9yc6.js";
15
+ } from "./packager-tool-z0d3fnwa.js";
16
16
  import"./packager-tool-jv5byaww.js";
17
17
  import"./packager-tool-00ck60cc.js";
18
18
  import"./packager-tool-n6h4bz4d.js";
@@ -14,7 +14,7 @@ import {
14
14
  fetchConnectorMaxPageSize2,
15
15
  fetchConnectorActivityMetadataV42,
16
16
  enrichConnectorNode2
17
- } from "./packager-tool-9pqfpszq.js";
17
+ } from "./packager-tool-7yrbhzz5.js";
18
18
  import {
19
19
  ACTIVITY_VERSION_V42,
20
20
  SUPPORTED_ACTIVITY_VERSIONS2,
@@ -27,7 +27,7 @@ import {
27
27
  extractMultipartParameters2,
28
28
  inlineMultipartFileValues2,
29
29
  buildInputMetadata2
30
- } from "./packager-tool-jhcqampv.js";
30
+ } from "./packager-tool-keyfwxtv.js";
31
31
  import"./packager-tool-c0pavv0s.js";
32
32
  import"./packager-tool-n3r5apbb.js";
33
33
  import {