@uipath/maestro-sdk 1.199.0-preview.108 → 1.199.0-preview.111

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.
@@ -3784,8 +3784,8 @@ var bpmn_spec_default = {
3784
3784
  <bpmn:outgoing>{outgoingEdge}</bpmn:outgoing>
3785
3785
  </bpmn:Task>`,
3786
3786
  inputNotes: "Variable mappings use uipath:mapping with direct input/output elements, not a jsonBody pattern",
3787
- bpmnElementNotes: "Also used on bpmn:StartEvent and bpmn:EndEvent for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
3788
- extensionTagNotes: "Uses uipath:mapping (not uipath:activity). createExtensionTask checks for serviceType=BPMN.Variables on StartEvent/EndEvent/Task and routes to createModdleExtensionVariableMapping."
3787
+ bpmnElementNotes: "Also used on bpmn:StartEvent, bpmn:EndEvent, bpmn:ScriptTask, and bpmn:SubProcess for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
3788
+ extensionTagNotes: "Uses uipath:mapping (not uipath:activity). BPMN.Variables mappings are supported on StartEvent, EndEvent, Task, ScriptTask, and SubProcess owners."
3789
3789
  },
3790
3790
  "BPMN.ScriptTask": {
3791
3791
  extensionType: "BPMN.ScriptTask",
@@ -18150,4 +18150,4 @@ export {
18150
18150
  BPMN_PARSE_ERROR
18151
18151
  };
18152
18152
 
18153
- //# debugId=EA502822B8A99FEC64756E2164756E21
18153
+ //# debugId=BAFB4C19AB3E5A8F64756E2164756E21
@@ -2250,8 +2250,8 @@ var bpmn_spec_default = {
2250
2250
  <bpmn:outgoing>{outgoingEdge}</bpmn:outgoing>
2251
2251
  </bpmn:Task>`,
2252
2252
  inputNotes: "Variable mappings use uipath:mapping with direct input/output elements, not a jsonBody pattern",
2253
- bpmnElementNotes: "Also used on bpmn:StartEvent and bpmn:EndEvent for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
2254
- extensionTagNotes: "Uses uipath:mapping (not uipath:activity). createExtensionTask checks for serviceType=BPMN.Variables on StartEvent/EndEvent/Task and routes to createModdleExtensionVariableMapping."
2253
+ bpmnElementNotes: "Also used on bpmn:StartEvent, bpmn:EndEvent, bpmn:ScriptTask, and bpmn:SubProcess for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
2254
+ extensionTagNotes: "Uses uipath:mapping (not uipath:activity). BPMN.Variables mappings are supported on StartEvent, EndEvent, Task, ScriptTask, and SubProcess owners."
2255
2255
  },
2256
2256
  "BPMN.ScriptTask": {
2257
2257
  extensionType: "BPMN.ScriptTask",
@@ -2998,6 +2998,7 @@ var SUPPORTED_UIPATH_EXTENSION_TAGS = Object.freeze(SUPPORTED_UIPATH_EXTENSION_T
2998
2998
  // src/bpmn-validation/project-validator.ts
2999
2999
  var KNOWN_UIPATH_TAGS = new Set(SUPPORTED_UIPATH_EXTENSION_TAGS);
3000
3000
  var SEMANTIC_VALIDATION_ERROR = "BPMN_VALIDATION_ERROR";
3001
+ var BPMN_MODEL_NAMESPACE = "http://www.omg.org/spec/BPMN/20100524/MODEL";
3001
3002
 
3002
3003
  class BpmnValidateService {
3003
3004
  fileSystem;
@@ -3204,7 +3205,7 @@ class BpmnValidateService {
3204
3205
  });
3205
3206
  }
3206
3207
  const allowedOwners = getAllowedOwnerTypes(contract);
3207
- if (!allowedOwners.some((allowedOwner) => normalizeBpmnName(allowedOwner) === normalizeBpmnName(owner.name))) {
3208
+ if (!allowedOwners.some((allowedOwner) => getLocalName(allowedOwner) === getLocalName(owner.name) && resolveNamespace(owner) === BPMN_MODEL_NAMESPACE)) {
3208
3209
  diagnostics.push({
3209
3210
  file,
3210
3211
  element: describeElement(owner),
@@ -3673,10 +3674,23 @@ function findFirst(node, predicate) {
3673
3674
  return;
3674
3675
  }
3675
3676
  function hasLocalName(node, localName) {
3676
- return normalizeBpmnName(node.name).split(":").pop() === localName.toLowerCase();
3677
+ return getLocalName(node.name) === localName.toLowerCase();
3677
3678
  }
3678
- function normalizeBpmnName(name) {
3679
- return name.toLowerCase();
3679
+ function getLocalName(name) {
3680
+ return name.slice(name.lastIndexOf(":") + 1).toLowerCase();
3681
+ }
3682
+ function resolveNamespace(node) {
3683
+ const separator = node.name.indexOf(":");
3684
+ const prefix = separator === -1 ? "" : node.name.slice(0, separator);
3685
+ const declaration = prefix ? `xmlns:${prefix}` : "xmlns";
3686
+ let current = node;
3687
+ while (current) {
3688
+ if (Object.hasOwn(current.attributes, declaration)) {
3689
+ return current.attributes[declaration];
3690
+ }
3691
+ current = current.parent;
3692
+ }
3693
+ return;
3680
3694
  }
3681
3695
  function findBpmnOwner(payload) {
3682
3696
  const extensionElements = payload.parent;
@@ -3705,7 +3719,8 @@ function getAllowedOwnerTypes(contract) {
3705
3719
  "bpmn:StartEvent",
3706
3720
  "bpmn:EndEvent",
3707
3721
  "bpmn:Task",
3708
- "bpmn:ScriptTask"
3722
+ "bpmn:ScriptTask",
3723
+ "bpmn:SubProcess"
3709
3724
  ];
3710
3725
  }
3711
3726
  const placementTypes = Object.values(contract.placements).map((placement) => placement.type);
@@ -3865,4 +3880,4 @@ export {
3865
3880
  BpmnValidateService
3866
3881
  };
3867
3882
 
3868
- //# debugId=707B5C006739D7FD64756E2164756E21
3883
+ //# debugId=DE15716967BCD42764756E2164756E21
package/dist/index.js CHANGED
@@ -42333,7 +42333,12 @@ var require_fast_uri = __commonJS((exports, module) => {
42333
42333
  }
42334
42334
  function resolve2(baseURI, relativeURI, options) {
42335
42335
  const schemelessOptions = options ? Object.assign({ scheme: "null" }, options) : { scheme: "null" };
42336
- const resolved = resolveComponent(parse5(baseURI, schemelessOptions), parse5(relativeURI, schemelessOptions), schemelessOptions, true);
42336
+ const { parsed: baseParsed, malformedAuthorityOrPort: baseMalformed } = parseWithStatus(baseURI, schemelessOptions);
42337
+ const { parsed: relativeParsed, malformedAuthorityOrPort: relativeMalformed } = parseWithStatus(relativeURI, schemelessOptions);
42338
+ if (baseMalformed || relativeMalformed) {
42339
+ throw new Error(baseParsed.error || relativeParsed.error || "URI is malformed.");
42340
+ }
42341
+ const resolved = resolveComponent(baseParsed, relativeParsed, schemelessOptions, true);
42337
42342
  schemelessOptions.skipEscape = true;
42338
42343
  return serialize(resolved, schemelessOptions);
42339
42344
  }
@@ -42460,6 +42465,7 @@ var require_fast_uri = __commonJS((exports, module) => {
42460
42465
  }
42461
42466
  var URI_PARSE = /^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;
42462
42467
  var AUTHORITY_PREFIX = /^(?:[^#/:?]+:)?\/\/([^/?#]*)/;
42468
+ var AUTHORITY_INTRODUCER_REGION = /^(?:[^#/:?]+:)?([/\\\t\n\r]*)/;
42463
42469
  function getParseError(parsed, matches) {
42464
42470
  if (matches[2] !== undefined && parsed.path && parsed.path[0] !== "/") {
42465
42471
  return 'URI path must start with "/" when authority is present.';
@@ -42494,6 +42500,20 @@ var require_fast_uri = __commonJS((exports, module) => {
42494
42500
  parsed.error = "URI authority must not contain a literal backslash.";
42495
42501
  malformedAuthorityOrPort = true;
42496
42502
  }
42503
+ const introducerMatch = uri.match(AUTHORITY_INTRODUCER_REGION);
42504
+ if (introducerMatch !== null) {
42505
+ const region = introducerMatch[1];
42506
+ const normalizedRegion = region.replace(/[\t\n\r]/g, "");
42507
+ if (normalizedRegion.length >= 2) {
42508
+ if (normalizedRegion.slice(0, 2) !== "//") {
42509
+ parsed.error = parsed.error || "URI authority must not contain a literal backslash.";
42510
+ malformedAuthorityOrPort = true;
42511
+ } else if (region.length !== normalizedRegion.length) {
42512
+ parsed.error = parsed.error || "URI authority introducer must not contain whitespace.";
42513
+ malformedAuthorityOrPort = true;
42514
+ }
42515
+ }
42516
+ }
42497
42517
  const matches = uri.match(URI_PARSE);
42498
42518
  if (matches) {
42499
42519
  parsed.scheme = matches[1];
@@ -49435,8 +49455,8 @@ var bpmn_spec_default = {
49435
49455
  <bpmn:outgoing>{outgoingEdge}</bpmn:outgoing>
49436
49456
  </bpmn:Task>`,
49437
49457
  inputNotes: "Variable mappings use uipath:mapping with direct input/output elements, not a jsonBody pattern",
49438
- bpmnElementNotes: "Also used on bpmn:StartEvent and bpmn:EndEvent for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
49439
- extensionTagNotes: "Uses uipath:mapping (not uipath:activity). createExtensionTask checks for serviceType=BPMN.Variables on StartEvent/EndEvent/Task and routes to createModdleExtensionVariableMapping."
49458
+ bpmnElementNotes: "Also used on bpmn:StartEvent, bpmn:EndEvent, bpmn:ScriptTask, and bpmn:SubProcess for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
49459
+ extensionTagNotes: "Uses uipath:mapping (not uipath:activity). BPMN.Variables mappings are supported on StartEvent, EndEvent, Task, ScriptTask, and SubProcess owners."
49440
49460
  },
49441
49461
  "BPMN.ScriptTask": {
49442
49462
  extensionType: "BPMN.ScriptTask",
@@ -50183,6 +50203,7 @@ var SUPPORTED_UIPATH_EXTENSION_TAGS = Object.freeze(SUPPORTED_UIPATH_EXTENSION_T
50183
50203
  // src/bpmn-validation/project-validator.ts
50184
50204
  var KNOWN_UIPATH_TAGS = new Set(SUPPORTED_UIPATH_EXTENSION_TAGS);
50185
50205
  var SEMANTIC_VALIDATION_ERROR = "BPMN_VALIDATION_ERROR";
50206
+ var BPMN_MODEL_NAMESPACE = "http://www.omg.org/spec/BPMN/20100524/MODEL";
50186
50207
 
50187
50208
  class BpmnValidateService {
50188
50209
  fileSystem;
@@ -50389,7 +50410,7 @@ class BpmnValidateService {
50389
50410
  });
50390
50411
  }
50391
50412
  const allowedOwners = getAllowedOwnerTypes(contract);
50392
- if (!allowedOwners.some((allowedOwner) => normalizeBpmnName(allowedOwner) === normalizeBpmnName(owner.name))) {
50413
+ if (!allowedOwners.some((allowedOwner) => getLocalName(allowedOwner) === getLocalName(owner.name) && resolveNamespace(owner) === BPMN_MODEL_NAMESPACE)) {
50393
50414
  diagnostics.push({
50394
50415
  file,
50395
50416
  element: describeElement(owner),
@@ -50858,10 +50879,23 @@ function findFirst(node, predicate) {
50858
50879
  return;
50859
50880
  }
50860
50881
  function hasLocalName(node, localName) {
50861
- return normalizeBpmnName(node.name).split(":").pop() === localName.toLowerCase();
50882
+ return getLocalName(node.name) === localName.toLowerCase();
50862
50883
  }
50863
- function normalizeBpmnName(name) {
50864
- return name.toLowerCase();
50884
+ function getLocalName(name) {
50885
+ return name.slice(name.lastIndexOf(":") + 1).toLowerCase();
50886
+ }
50887
+ function resolveNamespace(node) {
50888
+ const separator = node.name.indexOf(":");
50889
+ const prefix = separator === -1 ? "" : node.name.slice(0, separator);
50890
+ const declaration = prefix ? `xmlns:${prefix}` : "xmlns";
50891
+ let current = node;
50892
+ while (current) {
50893
+ if (Object.hasOwn(current.attributes, declaration)) {
50894
+ return current.attributes[declaration];
50895
+ }
50896
+ current = current.parent;
50897
+ }
50898
+ return;
50865
50899
  }
50866
50900
  function findBpmnOwner(payload) {
50867
50901
  const extensionElements = payload.parent;
@@ -50890,7 +50924,8 @@ function getAllowedOwnerTypes(contract) {
50890
50924
  "bpmn:StartEvent",
50891
50925
  "bpmn:EndEvent",
50892
50926
  "bpmn:Task",
50893
- "bpmn:ScriptTask"
50927
+ "bpmn:ScriptTask",
50928
+ "bpmn:SubProcess"
50894
50929
  ];
50895
50930
  }
50896
50931
  const placementTypes = Object.values(contract.placements).map((placement) => placement.type);
@@ -54335,7 +54370,7 @@ function requireOmap() {
54335
54370
  function resolveYamlOmap(data) {
54336
54371
  if (data === null)
54337
54372
  return true;
54338
- const objectKeys = [];
54373
+ const objectKeys = {};
54339
54374
  const object = data;
54340
54375
  for (let index = 0, length = object.length;index < length; index += 1) {
54341
54376
  const pair = object[index];
@@ -54353,10 +54388,9 @@ function requireOmap() {
54353
54388
  }
54354
54389
  if (!pairHasKey)
54355
54390
  return false;
54356
- if (objectKeys.indexOf(pairKey) === -1)
54357
- objectKeys.push(pairKey);
54358
- else
54391
+ if (_hasOwnProperty.call(objectKeys, pairKey))
54359
54392
  return false;
54393
+ Object.defineProperty(objectKeys, pairKey, { value: true });
54360
54394
  }
54361
54395
  return true;
54362
54396
  }
@@ -131061,7 +131095,7 @@ class TextApiResponse {
131061
131095
  var package_default = {
131062
131096
  name: "@uipath/integrationservice-sdk",
131063
131097
  license: "MIT",
131064
- version: "1.199.0-preview.108",
131098
+ version: "1.199.0-preview.111",
131065
131099
  repository: {
131066
131100
  type: "git",
131067
131101
  url: "https://github.com/UiPath/cli.git",
@@ -142923,4 +142957,4 @@ export {
142923
142957
  BPMN_SPEC
142924
142958
  };
142925
142959
 
142926
- //# debugId=F08A77EEC5E3334564756E2164756E21
142960
+ //# debugId=569CDD15D6C3D79764756E2164756E21
@@ -2250,8 +2250,8 @@ var bpmn_spec_default = {
2250
2250
  <bpmn:outgoing>{outgoingEdge}</bpmn:outgoing>
2251
2251
  </bpmn:Task>`,
2252
2252
  inputNotes: "Variable mappings use uipath:mapping with direct input/output elements, not a jsonBody pattern",
2253
- bpmnElementNotes: "Also used on bpmn:StartEvent and bpmn:EndEvent for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
2254
- extensionTagNotes: "Uses uipath:mapping (not uipath:activity). createExtensionTask checks for serviceType=BPMN.Variables on StartEvent/EndEvent/Task and routes to createModdleExtensionVariableMapping."
2253
+ bpmnElementNotes: "Also used on bpmn:StartEvent, bpmn:EndEvent, bpmn:ScriptTask, and bpmn:SubProcess for variable mappings. On bpmn:Task with no serviceType, defaults to BPMN.Variables.",
2254
+ extensionTagNotes: "Uses uipath:mapping (not uipath:activity). BPMN.Variables mappings are supported on StartEvent, EndEvent, Task, ScriptTask, and SubProcess owners."
2255
2255
  },
2256
2256
  "BPMN.ScriptTask": {
2257
2257
  extensionType: "BPMN.ScriptTask",
@@ -3000,4 +3000,4 @@ export {
3000
3000
  BPMN_SPEC
3001
3001
  };
3002
3002
 
3003
- //# debugId=4424DF01E4340FBF64756E2164756E21
3003
+ //# debugId=2A58D609C0428ABD64756E2164756E21
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/maestro-sdk",
3
3
  "license": "MIT",
4
- "version": "1.199.0-preview.108",
4
+ "version": "1.199.0-preview.111",
5
5
  "description": "SDK for the UiPath Maestro (PIMS) API — process instance management.",
6
6
  "repository": {
7
7
  "type": "git",
@@ -47,5 +47,5 @@
47
47
  "files": [
48
48
  "dist"
49
49
  ],
50
- "gitHead": "171f68daab68809916e8df10ea198c259f688ede"
50
+ "gitHead": "1a86625f94b9abd4d02444b8c5deec7e9d08d210"
51
51
  }