@uipath/project-packager 1.198.0-preview.94 → 1.199.0-preview.92

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/browser.js CHANGED
@@ -14,9 +14,11 @@ var de_default = {
14
14
  validator: {
15
15
  errors: {
16
16
  destinationNotDefined: "Destination path is not defined",
17
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
17
18
  governanceRequired: "Governance file path is required when governance file type is not Default",
18
19
  governanceFileInfo: "Unable to get file information: {path}",
19
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
20
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
21
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
20
22
  }
21
23
  },
22
24
  packager: {
@@ -97,6 +99,8 @@ var en = {
97
99
  validator: {
98
100
  errors: {
99
101
  destinationNotDefined: "Destination path is not defined",
102
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
103
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content.",
100
104
  governanceRequired: "Governance file path is required when governance file type is not Default",
101
105
  governanceFileInfo: "Unable to get file information: {path}",
102
106
  governanceInvalidFile: "Governance file path is not a valid file: {path}"
@@ -179,9 +183,11 @@ var es_default = {
179
183
  validator: {
180
184
  errors: {
181
185
  destinationNotDefined: "Destination path is not defined",
186
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
182
187
  governanceRequired: "Governance file path is required when governance file type is not Default",
183
188
  governanceFileInfo: "Unable to get file information: {path}",
184
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
189
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
190
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
185
191
  }
186
192
  },
187
193
  packager: {
@@ -261,9 +267,11 @@ var es_MX_default = {
261
267
  validator: {
262
268
  errors: {
263
269
  destinationNotDefined: "Destination path is not defined",
270
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
264
271
  governanceRequired: "Governance file path is required when governance file type is not Default",
265
272
  governanceFileInfo: "Unable to get file information: {path}",
266
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
273
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
274
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
267
275
  }
268
276
  },
269
277
  packager: {
@@ -343,9 +351,11 @@ var fr_default = {
343
351
  validator: {
344
352
  errors: {
345
353
  destinationNotDefined: "Destination path is not defined",
354
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
346
355
  governanceRequired: "Governance file path is required when governance file type is not Default",
347
356
  governanceFileInfo: "Unable to get file information: {path}",
348
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
357
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
358
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
349
359
  }
350
360
  },
351
361
  packager: {
@@ -425,9 +435,11 @@ var ja_default = {
425
435
  validator: {
426
436
  errors: {
427
437
  destinationNotDefined: "Destination path is not defined",
438
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
428
439
  governanceRequired: "Governance file path is required when governance file type is not Default",
429
440
  governanceFileInfo: "Unable to get file information: {path}",
430
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
441
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
442
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
431
443
  }
432
444
  },
433
445
  packager: {
@@ -507,9 +519,11 @@ var ko_default = {
507
519
  validator: {
508
520
  errors: {
509
521
  destinationNotDefined: "Destination path is not defined",
522
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
510
523
  governanceRequired: "Governance file path is required when governance file type is not Default",
511
524
  governanceFileInfo: "Unable to get file information: {path}",
512
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
525
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
526
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
513
527
  }
514
528
  },
515
529
  packager: {
@@ -589,9 +603,11 @@ var pt_default = {
589
603
  validator: {
590
604
  errors: {
591
605
  destinationNotDefined: "Destination path is not defined",
606
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
592
607
  governanceRequired: "Governance file path is required when governance file type is not Default",
593
608
  governanceFileInfo: "Unable to get file information: {path}",
594
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
609
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
610
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
595
611
  }
596
612
  },
597
613
  packager: {
@@ -671,9 +687,11 @@ var pt_BR_default = {
671
687
  validator: {
672
688
  errors: {
673
689
  destinationNotDefined: "Destination path is not defined",
690
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
674
691
  governanceRequired: "Governance file path is required when governance file type is not Default",
675
692
  governanceFileInfo: "Unable to get file information: {path}",
676
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
693
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
694
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
677
695
  }
678
696
  },
679
697
  packager: {
@@ -753,9 +771,11 @@ var ro_default = {
753
771
  validator: {
754
772
  errors: {
755
773
  destinationNotDefined: "Destination path is not defined",
774
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
756
775
  governanceRequired: "Governance file path is required when governance file type is not Default",
757
776
  governanceFileInfo: "Unable to get file information: {path}",
758
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
777
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
778
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
759
779
  }
760
780
  },
761
781
  packager: {
@@ -835,9 +855,11 @@ var ru_default = {
835
855
  validator: {
836
856
  errors: {
837
857
  destinationNotDefined: "Destination path is not defined",
858
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
838
859
  governanceRequired: "Governance file path is required when governance file type is not Default",
839
860
  governanceFileInfo: "Unable to get file information: {path}",
840
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
861
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
862
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
841
863
  }
842
864
  },
843
865
  packager: {
@@ -917,9 +939,11 @@ var tr_default = {
917
939
  validator: {
918
940
  errors: {
919
941
  destinationNotDefined: "Destination path is not defined",
942
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
920
943
  governanceRequired: "Governance file path is required when governance file type is not Default",
921
944
  governanceFileInfo: "Unable to get file information: {path}",
922
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
945
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
946
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
923
947
  }
924
948
  },
925
949
  packager: {
@@ -999,9 +1023,11 @@ var zh_CN_default = {
999
1023
  validator: {
1000
1024
  errors: {
1001
1025
  destinationNotDefined: "Destination path is not defined",
1026
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1002
1027
  governanceRequired: "Governance file path is required when governance file type is not Default",
1003
1028
  governanceFileInfo: "Unable to get file information: {path}",
1004
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1029
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1030
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1005
1031
  }
1006
1032
  },
1007
1033
  packager: {
@@ -1081,9 +1107,11 @@ var zh_TW_default = {
1081
1107
  validator: {
1082
1108
  errors: {
1083
1109
  destinationNotDefined: "Destination path is not defined",
1110
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1084
1111
  governanceRequired: "Governance file path is required when governance file type is not Default",
1085
1112
  governanceFileInfo: "Unable to get file information: {path}",
1086
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1113
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1114
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1087
1115
  }
1088
1116
  },
1089
1117
  packager: {
@@ -1163,9 +1191,11 @@ var zu_default = {
1163
1191
  validator: {
1164
1192
  errors: {
1165
1193
  destinationNotDefined: "Destination path is not defined",
1194
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1166
1195
  governanceRequired: "Governance file path is required when governance file type is not Default",
1167
1196
  governanceFileInfo: "Unable to get file information: {path}",
1168
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1197
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1198
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1169
1199
  }
1170
1200
  },
1171
1201
  packager: {
@@ -22613,6 +22643,7 @@ var SKILL_ATTRIBUTION = attributionRecord([
22613
22643
  var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
22614
22644
  var COMMAND_ATTRIBUTION = commandAttribution([
22615
22645
  ["cli", "troubleshoot", ["uip.feedback"]],
22646
+ ["llm-gateway", "operate", ["uip.llm-gateway"]],
22616
22647
  ["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
22617
22648
  ["context-grounding", "build", ["uip.context-grounding"]],
22618
22649
  ["api-workflow", "build", ["uip.api-workflow"]],
@@ -23367,6 +23398,44 @@ class PackagerParametersValidator {
23367
23398
  }
23368
23399
  return ToolResult2.success();
23369
23400
  }
23401
+ async validateDestinationOutsideProjectAsync(destinationPath, inputPath) {
23402
+ const projectDirectory = await this.resolveProjectDirectoryAsync(inputPath);
23403
+ if (!projectDirectory) {
23404
+ return ToolResult2.success();
23405
+ }
23406
+ const destination = this.fileSystem.path.resolve(destinationPath);
23407
+ if (!this.isSameOrInside(projectDirectory, destination)) {
23408
+ return ToolResult2.success();
23409
+ }
23410
+ const message = translate3.t("solutionpackager.validator.errors.destinationInsideProject", {
23411
+ destinationPath: destination,
23412
+ projectPath: projectDirectory
23413
+ });
23414
+ const instructions = translate3.t("solutionpackager.validator.errors.destinationInsideProjectInstruction");
23415
+ this.logger.error(message);
23416
+ return ToolResult2.error(ToolErrorCodes2.InternalError, message, instructions);
23417
+ }
23418
+ async resolveProjectDirectoryAsync(inputPath) {
23419
+ if (!inputPath) {
23420
+ return;
23421
+ }
23422
+ const resolved = this.fileSystem.path.resolve(inputPath);
23423
+ const stat = await this.fileSystem.stat(resolved);
23424
+ if (!stat) {
23425
+ return;
23426
+ }
23427
+ return stat.isDirectory() ? resolved : this.fileSystem.path.dirname(resolved);
23428
+ }
23429
+ isSameOrInside(parent, child) {
23430
+ const relative2 = this.fileSystem.path.relative(parent, child);
23431
+ if (relative2 === "") {
23432
+ return true;
23433
+ }
23434
+ if (this.fileSystem.path.isAbsolute(relative2)) {
23435
+ return false;
23436
+ }
23437
+ return relative2 !== ".." && !relative2.startsWith("../") && !relative2.startsWith("..\\");
23438
+ }
23370
23439
  async validateGovernanceOptions(validateOptions) {
23371
23440
  if (validateOptions.governanceFileType === "Default" /* Default */) {
23372
23441
  if (validateOptions.governanceFilePath) {
@@ -23533,6 +23602,10 @@ class ProjectPackOptionsValidator extends ProjectBuildOptionsValidator {
23533
23602
  if (!destinationResult.isSuccess) {
23534
23603
  return destinationResult;
23535
23604
  }
23605
+ const containmentResult = await this.validateDestinationOutsideProjectAsync(options.destinationPath, options.inputPath);
23606
+ if (!containmentResult.isSuccess) {
23607
+ return containmentResult;
23608
+ }
23536
23609
  return await super.validateAsync(options, cancellationToken);
23537
23610
  }
23538
23611
  }
@@ -23749,7 +23822,8 @@ class ProjectPackager {
23749
23822
  outputType: options.outputType,
23750
23823
  projectType: uiPathProject.Type
23751
23824
  };
23752
- return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, undefined, cancellationToken);
23825
+ const context = this.createOperationContext(options, uiPathProject);
23826
+ return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, context, cancellationToken);
23753
23827
  }, cancellationToken);
23754
23828
  }
23755
23829
  async packProjectAsync(options, cancellationToken) {
@@ -23807,7 +23881,10 @@ class ProjectPackager {
23807
23881
  dryRun: options.dryRun ?? false,
23808
23882
  skipImports: options.skipImports ?? false
23809
23883
  };
23810
- const context = this.createOperationContext(options, uiPathProject);
23884
+ const context = {
23885
+ ...this.createOperationContext(options, uiPathProject),
23886
+ lockKey: options.lockKey
23887
+ };
23811
23888
  return await this.projectExecutor.cleanupAsync(cleanupOptions, uiPathProject, context, cancellationToken);
23812
23889
  }, cancellationToken);
23813
23890
  }
@@ -23930,4 +24007,4 @@ export {
23930
24007
  BaseBrowserPackagerFactory
23931
24008
  };
23932
24009
 
23933
- //# debugId=FD7C95F51232306D64756E2164756E21
24010
+ //# debugId=FB4C63AEE91C68CE64756E2164756E21
package/dist/index.js CHANGED
@@ -14,9 +14,11 @@ var de_default = {
14
14
  validator: {
15
15
  errors: {
16
16
  destinationNotDefined: "Destination path is not defined",
17
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
17
18
  governanceRequired: "Governance file path is required when governance file type is not Default",
18
19
  governanceFileInfo: "Unable to get file information: {path}",
19
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
20
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
21
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
20
22
  }
21
23
  },
22
24
  packager: {
@@ -97,6 +99,8 @@ var en = {
97
99
  validator: {
98
100
  errors: {
99
101
  destinationNotDefined: "Destination path is not defined",
102
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
103
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content.",
100
104
  governanceRequired: "Governance file path is required when governance file type is not Default",
101
105
  governanceFileInfo: "Unable to get file information: {path}",
102
106
  governanceInvalidFile: "Governance file path is not a valid file: {path}"
@@ -179,9 +183,11 @@ var es_default = {
179
183
  validator: {
180
184
  errors: {
181
185
  destinationNotDefined: "Destination path is not defined",
186
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
182
187
  governanceRequired: "Governance file path is required when governance file type is not Default",
183
188
  governanceFileInfo: "Unable to get file information: {path}",
184
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
189
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
190
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
185
191
  }
186
192
  },
187
193
  packager: {
@@ -261,9 +267,11 @@ var es_MX_default = {
261
267
  validator: {
262
268
  errors: {
263
269
  destinationNotDefined: "Destination path is not defined",
270
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
264
271
  governanceRequired: "Governance file path is required when governance file type is not Default",
265
272
  governanceFileInfo: "Unable to get file information: {path}",
266
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
273
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
274
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
267
275
  }
268
276
  },
269
277
  packager: {
@@ -343,9 +351,11 @@ var fr_default = {
343
351
  validator: {
344
352
  errors: {
345
353
  destinationNotDefined: "Destination path is not defined",
354
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
346
355
  governanceRequired: "Governance file path is required when governance file type is not Default",
347
356
  governanceFileInfo: "Unable to get file information: {path}",
348
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
357
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
358
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
349
359
  }
350
360
  },
351
361
  packager: {
@@ -425,9 +435,11 @@ var ja_default = {
425
435
  validator: {
426
436
  errors: {
427
437
  destinationNotDefined: "Destination path is not defined",
438
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
428
439
  governanceRequired: "Governance file path is required when governance file type is not Default",
429
440
  governanceFileInfo: "Unable to get file information: {path}",
430
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
441
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
442
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
431
443
  }
432
444
  },
433
445
  packager: {
@@ -507,9 +519,11 @@ var ko_default = {
507
519
  validator: {
508
520
  errors: {
509
521
  destinationNotDefined: "Destination path is not defined",
522
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
510
523
  governanceRequired: "Governance file path is required when governance file type is not Default",
511
524
  governanceFileInfo: "Unable to get file information: {path}",
512
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
525
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
526
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
513
527
  }
514
528
  },
515
529
  packager: {
@@ -589,9 +603,11 @@ var pt_default = {
589
603
  validator: {
590
604
  errors: {
591
605
  destinationNotDefined: "Destination path is not defined",
606
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
592
607
  governanceRequired: "Governance file path is required when governance file type is not Default",
593
608
  governanceFileInfo: "Unable to get file information: {path}",
594
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
609
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
610
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
595
611
  }
596
612
  },
597
613
  packager: {
@@ -671,9 +687,11 @@ var pt_BR_default = {
671
687
  validator: {
672
688
  errors: {
673
689
  destinationNotDefined: "Destination path is not defined",
690
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
674
691
  governanceRequired: "Governance file path is required when governance file type is not Default",
675
692
  governanceFileInfo: "Unable to get file information: {path}",
676
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
693
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
694
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
677
695
  }
678
696
  },
679
697
  packager: {
@@ -753,9 +771,11 @@ var ro_default = {
753
771
  validator: {
754
772
  errors: {
755
773
  destinationNotDefined: "Destination path is not defined",
774
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
756
775
  governanceRequired: "Governance file path is required when governance file type is not Default",
757
776
  governanceFileInfo: "Unable to get file information: {path}",
758
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
777
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
778
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
759
779
  }
760
780
  },
761
781
  packager: {
@@ -835,9 +855,11 @@ var ru_default = {
835
855
  validator: {
836
856
  errors: {
837
857
  destinationNotDefined: "Destination path is not defined",
858
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
838
859
  governanceRequired: "Governance file path is required when governance file type is not Default",
839
860
  governanceFileInfo: "Unable to get file information: {path}",
840
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
861
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
862
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
841
863
  }
842
864
  },
843
865
  packager: {
@@ -917,9 +939,11 @@ var tr_default = {
917
939
  validator: {
918
940
  errors: {
919
941
  destinationNotDefined: "Destination path is not defined",
942
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
920
943
  governanceRequired: "Governance file path is required when governance file type is not Default",
921
944
  governanceFileInfo: "Unable to get file information: {path}",
922
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
945
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
946
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
923
947
  }
924
948
  },
925
949
  packager: {
@@ -999,9 +1023,11 @@ var zh_CN_default = {
999
1023
  validator: {
1000
1024
  errors: {
1001
1025
  destinationNotDefined: "Destination path is not defined",
1026
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1002
1027
  governanceRequired: "Governance file path is required when governance file type is not Default",
1003
1028
  governanceFileInfo: "Unable to get file information: {path}",
1004
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1029
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1030
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1005
1031
  }
1006
1032
  },
1007
1033
  packager: {
@@ -1081,9 +1107,11 @@ var zh_TW_default = {
1081
1107
  validator: {
1082
1108
  errors: {
1083
1109
  destinationNotDefined: "Destination path is not defined",
1110
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1084
1111
  governanceRequired: "Governance file path is required when governance file type is not Default",
1085
1112
  governanceFileInfo: "Unable to get file information: {path}",
1086
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1113
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1114
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1087
1115
  }
1088
1116
  },
1089
1117
  packager: {
@@ -1163,9 +1191,11 @@ var zu_default = {
1163
1191
  validator: {
1164
1192
  errors: {
1165
1193
  destinationNotDefined: "Destination path is not defined",
1194
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1166
1195
  governanceRequired: "Governance file path is required when governance file type is not Default",
1167
1196
  governanceFileInfo: "Unable to get file information: {path}",
1168
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1197
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1198
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1169
1199
  }
1170
1200
  },
1171
1201
  packager: {
@@ -22613,6 +22643,7 @@ var SKILL_ATTRIBUTION = attributionRecord([
22613
22643
  var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
22614
22644
  var COMMAND_ATTRIBUTION = commandAttribution([
22615
22645
  ["cli", "troubleshoot", ["uip.feedback"]],
22646
+ ["llm-gateway", "operate", ["uip.llm-gateway"]],
22616
22647
  ["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
22617
22648
  ["context-grounding", "build", ["uip.context-grounding"]],
22618
22649
  ["api-workflow", "build", ["uip.api-workflow"]],
@@ -23005,6 +23036,7 @@ class ProjectBuildOptions extends ProjectValidateOptions {
23005
23036
  class ProjectCleanupOptions extends PackagerParameters {
23006
23037
  dryRun = false;
23007
23038
  skipImports = false;
23039
+ lockKey;
23008
23040
  }
23009
23041
  // src/models/project-pack-options.ts
23010
23042
  class ProjectPackOptions extends ProjectBuildOptions {
@@ -23358,7 +23390,7 @@ import { translate as translate3 } from "@uipath/solutionpackager-tool-core";
23358
23390
  var package_default = {
23359
23391
  name: "@uipath/project-packager",
23360
23392
  license: "MIT",
23361
- version: "1.198.0-preview.94",
23393
+ version: "1.199.0-preview.92",
23362
23394
  description: "UiPath Project Packager - core library for packing individual UiPath projects",
23363
23395
  type: "module",
23364
23396
  main: "./dist/index.js",
@@ -23992,6 +24024,44 @@ class PackagerParametersValidator {
23992
24024
  }
23993
24025
  return ToolResult6.success();
23994
24026
  }
24027
+ async validateDestinationOutsideProjectAsync(destinationPath, inputPath) {
24028
+ const projectDirectory = await this.resolveProjectDirectoryAsync(inputPath);
24029
+ if (!projectDirectory) {
24030
+ return ToolResult6.success();
24031
+ }
24032
+ const destination = this.fileSystem.path.resolve(destinationPath);
24033
+ if (!this.isSameOrInside(projectDirectory, destination)) {
24034
+ return ToolResult6.success();
24035
+ }
24036
+ const message = translate7.t("solutionpackager.validator.errors.destinationInsideProject", {
24037
+ destinationPath: destination,
24038
+ projectPath: projectDirectory
24039
+ });
24040
+ const instructions = translate7.t("solutionpackager.validator.errors.destinationInsideProjectInstruction");
24041
+ this.logger.error(message);
24042
+ return ToolResult6.error(ToolErrorCodes6.InternalError, message, instructions);
24043
+ }
24044
+ async resolveProjectDirectoryAsync(inputPath) {
24045
+ if (!inputPath) {
24046
+ return;
24047
+ }
24048
+ const resolved = this.fileSystem.path.resolve(inputPath);
24049
+ const stat = await this.fileSystem.stat(resolved);
24050
+ if (!stat) {
24051
+ return;
24052
+ }
24053
+ return stat.isDirectory() ? resolved : this.fileSystem.path.dirname(resolved);
24054
+ }
24055
+ isSameOrInside(parent, child) {
24056
+ const relative2 = this.fileSystem.path.relative(parent, child);
24057
+ if (relative2 === "") {
24058
+ return true;
24059
+ }
24060
+ if (this.fileSystem.path.isAbsolute(relative2)) {
24061
+ return false;
24062
+ }
24063
+ return relative2 !== ".." && !relative2.startsWith("../") && !relative2.startsWith("..\\");
24064
+ }
23995
24065
  async validateGovernanceOptions(validateOptions) {
23996
24066
  if (validateOptions.governanceFileType === "Default" /* Default */) {
23997
24067
  if (validateOptions.governanceFilePath) {
@@ -24184,6 +24254,10 @@ class ProjectPackOptionsValidator extends ProjectBuildOptionsValidator {
24184
24254
  if (!destinationResult.isSuccess) {
24185
24255
  return destinationResult;
24186
24256
  }
24257
+ const containmentResult = await this.validateDestinationOutsideProjectAsync(options.destinationPath, options.inputPath);
24258
+ if (!containmentResult.isSuccess) {
24259
+ return containmentResult;
24260
+ }
24187
24261
  return await super.validateAsync(options, cancellationToken);
24188
24262
  }
24189
24263
  }
@@ -24400,7 +24474,8 @@ class ProjectPackager {
24400
24474
  outputType: options.outputType,
24401
24475
  projectType: uiPathProject.Type
24402
24476
  };
24403
- return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, undefined, cancellationToken);
24477
+ const context = this.createOperationContext(options, uiPathProject);
24478
+ return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, context, cancellationToken);
24404
24479
  }, cancellationToken);
24405
24480
  }
24406
24481
  async packProjectAsync(options, cancellationToken) {
@@ -24458,7 +24533,10 @@ class ProjectPackager {
24458
24533
  dryRun: options.dryRun ?? false,
24459
24534
  skipImports: options.skipImports ?? false
24460
24535
  };
24461
- const context = this.createOperationContext(options, uiPathProject);
24536
+ const context = {
24537
+ ...this.createOperationContext(options, uiPathProject),
24538
+ lockKey: options.lockKey
24539
+ };
24462
24540
  return await this.projectExecutor.cleanupAsync(cleanupOptions, uiPathProject, context, cancellationToken);
24463
24541
  }, cancellationToken);
24464
24542
  }
@@ -24587,4 +24665,4 @@ export {
24587
24665
  BrowserContextStorage
24588
24666
  };
24589
24667
 
24590
- //# debugId=A6B54086581B60AA64756E2164756E21
24668
+ //# debugId=F3DBB5787131612164756E2164756E21
package/dist/node.js CHANGED
@@ -14,9 +14,11 @@ var de_default = {
14
14
  validator: {
15
15
  errors: {
16
16
  destinationNotDefined: "Destination path is not defined",
17
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
17
18
  governanceRequired: "Governance file path is required when governance file type is not Default",
18
19
  governanceFileInfo: "Unable to get file information: {path}",
19
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
20
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
21
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
20
22
  }
21
23
  },
22
24
  packager: {
@@ -97,6 +99,8 @@ var en = {
97
99
  validator: {
98
100
  errors: {
99
101
  destinationNotDefined: "Destination path is not defined",
102
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
103
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content.",
100
104
  governanceRequired: "Governance file path is required when governance file type is not Default",
101
105
  governanceFileInfo: "Unable to get file information: {path}",
102
106
  governanceInvalidFile: "Governance file path is not a valid file: {path}"
@@ -179,9 +183,11 @@ var es_default = {
179
183
  validator: {
180
184
  errors: {
181
185
  destinationNotDefined: "Destination path is not defined",
186
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
182
187
  governanceRequired: "Governance file path is required when governance file type is not Default",
183
188
  governanceFileInfo: "Unable to get file information: {path}",
184
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
189
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
190
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
185
191
  }
186
192
  },
187
193
  packager: {
@@ -261,9 +267,11 @@ var es_MX_default = {
261
267
  validator: {
262
268
  errors: {
263
269
  destinationNotDefined: "Destination path is not defined",
270
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
264
271
  governanceRequired: "Governance file path is required when governance file type is not Default",
265
272
  governanceFileInfo: "Unable to get file information: {path}",
266
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
273
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
274
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
267
275
  }
268
276
  },
269
277
  packager: {
@@ -343,9 +351,11 @@ var fr_default = {
343
351
  validator: {
344
352
  errors: {
345
353
  destinationNotDefined: "Destination path is not defined",
354
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
346
355
  governanceRequired: "Governance file path is required when governance file type is not Default",
347
356
  governanceFileInfo: "Unable to get file information: {path}",
348
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
357
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
358
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
349
359
  }
350
360
  },
351
361
  packager: {
@@ -425,9 +435,11 @@ var ja_default = {
425
435
  validator: {
426
436
  errors: {
427
437
  destinationNotDefined: "Destination path is not defined",
438
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
428
439
  governanceRequired: "Governance file path is required when governance file type is not Default",
429
440
  governanceFileInfo: "Unable to get file information: {path}",
430
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
441
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
442
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
431
443
  }
432
444
  },
433
445
  packager: {
@@ -507,9 +519,11 @@ var ko_default = {
507
519
  validator: {
508
520
  errors: {
509
521
  destinationNotDefined: "Destination path is not defined",
522
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
510
523
  governanceRequired: "Governance file path is required when governance file type is not Default",
511
524
  governanceFileInfo: "Unable to get file information: {path}",
512
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
525
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
526
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
513
527
  }
514
528
  },
515
529
  packager: {
@@ -589,9 +603,11 @@ var pt_default = {
589
603
  validator: {
590
604
  errors: {
591
605
  destinationNotDefined: "Destination path is not defined",
606
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
592
607
  governanceRequired: "Governance file path is required when governance file type is not Default",
593
608
  governanceFileInfo: "Unable to get file information: {path}",
594
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
609
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
610
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
595
611
  }
596
612
  },
597
613
  packager: {
@@ -671,9 +687,11 @@ var pt_BR_default = {
671
687
  validator: {
672
688
  errors: {
673
689
  destinationNotDefined: "Destination path is not defined",
690
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
674
691
  governanceRequired: "Governance file path is required when governance file type is not Default",
675
692
  governanceFileInfo: "Unable to get file information: {path}",
676
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
693
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
694
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
677
695
  }
678
696
  },
679
697
  packager: {
@@ -753,9 +771,11 @@ var ro_default = {
753
771
  validator: {
754
772
  errors: {
755
773
  destinationNotDefined: "Destination path is not defined",
774
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
756
775
  governanceRequired: "Governance file path is required when governance file type is not Default",
757
776
  governanceFileInfo: "Unable to get file information: {path}",
758
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
777
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
778
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
759
779
  }
760
780
  },
761
781
  packager: {
@@ -835,9 +855,11 @@ var ru_default = {
835
855
  validator: {
836
856
  errors: {
837
857
  destinationNotDefined: "Destination path is not defined",
858
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
838
859
  governanceRequired: "Governance file path is required when governance file type is not Default",
839
860
  governanceFileInfo: "Unable to get file information: {path}",
840
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
861
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
862
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
841
863
  }
842
864
  },
843
865
  packager: {
@@ -917,9 +939,11 @@ var tr_default = {
917
939
  validator: {
918
940
  errors: {
919
941
  destinationNotDefined: "Destination path is not defined",
942
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
920
943
  governanceRequired: "Governance file path is required when governance file type is not Default",
921
944
  governanceFileInfo: "Unable to get file information: {path}",
922
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
945
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
946
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
923
947
  }
924
948
  },
925
949
  packager: {
@@ -999,9 +1023,11 @@ var zh_CN_default = {
999
1023
  validator: {
1000
1024
  errors: {
1001
1025
  destinationNotDefined: "Destination path is not defined",
1026
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1002
1027
  governanceRequired: "Governance file path is required when governance file type is not Default",
1003
1028
  governanceFileInfo: "Unable to get file information: {path}",
1004
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1029
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1030
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1005
1031
  }
1006
1032
  },
1007
1033
  packager: {
@@ -1081,9 +1107,11 @@ var zh_TW_default = {
1081
1107
  validator: {
1082
1108
  errors: {
1083
1109
  destinationNotDefined: "Destination path is not defined",
1110
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1084
1111
  governanceRequired: "Governance file path is required when governance file type is not Default",
1085
1112
  governanceFileInfo: "Unable to get file information: {path}",
1086
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1113
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1114
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1087
1115
  }
1088
1116
  },
1089
1117
  packager: {
@@ -1163,9 +1191,11 @@ var zu_default = {
1163
1191
  validator: {
1164
1192
  errors: {
1165
1193
  destinationNotDefined: "Destination path is not defined",
1194
+ destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.",
1166
1195
  governanceRequired: "Governance file path is required when governance file type is not Default",
1167
1196
  governanceFileInfo: "Unable to get file information: {path}",
1168
- governanceInvalidFile: "Governance file path is not a valid file: {path}"
1197
+ governanceInvalidFile: "Governance file path is not a valid file: {path}",
1198
+ destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content."
1169
1199
  }
1170
1200
  },
1171
1201
  packager: {
@@ -10727,6 +10757,7 @@ var SKILL_ATTRIBUTION = attributionRecord([
10727
10757
  var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
10728
10758
  var COMMAND_ATTRIBUTION = commandAttribution([
10729
10759
  ["cli", "troubleshoot", ["uip.feedback"]],
10760
+ ["llm-gateway", "operate", ["uip.llm-gateway"]],
10730
10761
  ["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
10731
10762
  ["context-grounding", "build", ["uip.context-grounding"]],
10732
10763
  ["api-workflow", "build", ["uip.api-workflow"]],
@@ -11301,6 +11332,7 @@ class ProjectBuildOptions extends ProjectValidateOptions {
11301
11332
  class ProjectCleanupOptions extends PackagerParameters {
11302
11333
  dryRun = false;
11303
11334
  skipImports = false;
11335
+ lockKey;
11304
11336
  }
11305
11337
  // src/models/project-pack-options.ts
11306
11338
  class ProjectPackOptions extends ProjectBuildOptions {
@@ -11669,6 +11701,44 @@ class PackagerParametersValidator {
11669
11701
  }
11670
11702
  return ToolResult3.success();
11671
11703
  }
11704
+ async validateDestinationOutsideProjectAsync(destinationPath, inputPath) {
11705
+ const projectDirectory = await this.resolveProjectDirectoryAsync(inputPath);
11706
+ if (!projectDirectory) {
11707
+ return ToolResult3.success();
11708
+ }
11709
+ const destination = this.fileSystem.path.resolve(destinationPath);
11710
+ if (!this.isSameOrInside(projectDirectory, destination)) {
11711
+ return ToolResult3.success();
11712
+ }
11713
+ const message = translate4.t("solutionpackager.validator.errors.destinationInsideProject", {
11714
+ destinationPath: destination,
11715
+ projectPath: projectDirectory
11716
+ });
11717
+ const instructions = translate4.t("solutionpackager.validator.errors.destinationInsideProjectInstruction");
11718
+ this.logger.error(message);
11719
+ return ToolResult3.error(ToolErrorCodes3.InternalError, message, instructions);
11720
+ }
11721
+ async resolveProjectDirectoryAsync(inputPath) {
11722
+ if (!inputPath) {
11723
+ return;
11724
+ }
11725
+ const resolved = this.fileSystem.path.resolve(inputPath);
11726
+ const stat2 = await this.fileSystem.stat(resolved);
11727
+ if (!stat2) {
11728
+ return;
11729
+ }
11730
+ return stat2.isDirectory() ? resolved : this.fileSystem.path.dirname(resolved);
11731
+ }
11732
+ isSameOrInside(parent, child) {
11733
+ const relative2 = this.fileSystem.path.relative(parent, child);
11734
+ if (relative2 === "") {
11735
+ return true;
11736
+ }
11737
+ if (this.fileSystem.path.isAbsolute(relative2)) {
11738
+ return false;
11739
+ }
11740
+ return relative2 !== ".." && !relative2.startsWith("../") && !relative2.startsWith("..\\");
11741
+ }
11672
11742
  async validateGovernanceOptions(validateOptions) {
11673
11743
  if (validateOptions.governanceFileType === "Default" /* Default */) {
11674
11744
  if (validateOptions.governanceFilePath) {
@@ -11835,6 +11905,10 @@ class ProjectPackOptionsValidator extends ProjectBuildOptionsValidator {
11835
11905
  if (!destinationResult.isSuccess) {
11836
11906
  return destinationResult;
11837
11907
  }
11908
+ const containmentResult = await this.validateDestinationOutsideProjectAsync(options.destinationPath, options.inputPath);
11909
+ if (!containmentResult.isSuccess) {
11910
+ return containmentResult;
11911
+ }
11838
11912
  return await super.validateAsync(options, cancellationToken);
11839
11913
  }
11840
11914
  }
@@ -12051,7 +12125,8 @@ class ProjectPackager {
12051
12125
  outputType: options.outputType,
12052
12126
  projectType: uiPathProject.Type
12053
12127
  };
12054
- return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, undefined, cancellationToken);
12128
+ const context = this.createOperationContext(options, uiPathProject);
12129
+ return await this.projectExecutor.buildAsync(buildOptions, uiPathProject, context, cancellationToken);
12055
12130
  }, cancellationToken);
12056
12131
  }
12057
12132
  async packProjectAsync(options, cancellationToken) {
@@ -12109,7 +12184,10 @@ class ProjectPackager {
12109
12184
  dryRun: options.dryRun ?? false,
12110
12185
  skipImports: options.skipImports ?? false
12111
12186
  };
12112
- const context = this.createOperationContext(options, uiPathProject);
12187
+ const context = {
12188
+ ...this.createOperationContext(options, uiPathProject),
12189
+ lockKey: options.lockKey
12190
+ };
12113
12191
  return await this.projectExecutor.cleanupAsync(cleanupOptions, uiPathProject, context, cancellationToken);
12114
12192
  }, cancellationToken);
12115
12193
  }
@@ -12489,7 +12567,7 @@ import { translate as translate9 } from "@uipath/solutionpackager-tool-core";
12489
12567
  var package_default = {
12490
12568
  name: "@uipath/project-packager",
12491
12569
  license: "MIT",
12492
- version: "1.198.0-preview.94",
12570
+ version: "1.199.0-preview.92",
12493
12571
  description: "UiPath Project Packager - core library for packing individual UiPath projects",
12494
12572
  type: "module",
12495
12573
  main: "./dist/index.js",
@@ -12946,4 +13024,4 @@ export {
12946
13024
  BaseNodePackagerFactory
12947
13025
  };
12948
13026
 
12949
- //# debugId=633BCB30576070A964756E2164756E21
13027
+ //# debugId=E631A09787A43CB864756E2164756E21
@@ -15,6 +15,8 @@ export declare const en: {
15
15
  readonly validator: {
16
16
  readonly errors: {
17
17
  readonly destinationNotDefined: "Destination path is not defined";
18
+ readonly destinationInsideProject: "Destination path '{destinationPath}' is inside the project directory '{projectPath}'.";
19
+ readonly destinationInsideProjectInstruction: "Choose a destination outside the project directory. A package written inside the project would be swallowed into the next pack's content.";
18
20
  readonly governanceRequired: "Governance file path is required when governance file type is not Default";
19
21
  readonly governanceFileInfo: "Unable to get file information: {path}";
20
22
  readonly governanceInvalidFile: "Governance file path is not a valid file: {path}";
@@ -11,4 +11,10 @@ export declare class ProjectCleanupOptions extends PackagerParameters {
11
11
  * Do not clean up now-unused references to removed items in the project's files.
12
12
  */
13
13
  skipImports: boolean;
14
+ /**
15
+ * Lock key of the current editing session. Forwarded to the remote agent for
16
+ * Cleanup so its save-back overwrite is accepted while the project is locked
17
+ * by that session. Set by the caller that holds the lock.
18
+ */
19
+ lockKey?: string;
14
20
  }
@@ -22,5 +22,14 @@ export declare class PackagerParametersValidator<TOptions extends PackagerParame
22
22
  constructor(logger: IToolLogger, fileSystem: IFileSystem);
23
23
  validateAsync(_options: TOptions, _cancellationToken?: AbortSignal): Promise<ToolResult>;
24
24
  protected validateDestinationPath(destinationPath: string): ToolResult;
25
+ /**
26
+ * Reject a destination path that is equal to or inside the project
27
+ * directory — output written there is swallowed into the next pack's
28
+ * content, growing packages indefinitely. Skipped when the input path
29
+ * does not exist on disk.
30
+ */
31
+ protected validateDestinationOutsideProjectAsync(destinationPath: string, inputPath: string): Promise<ToolResult>;
32
+ private resolveProjectDirectoryAsync;
33
+ private isSameOrInside;
25
34
  protected validateGovernanceOptions(validateOptions: ValidateOptions): Promise<ToolResult>;
26
35
  }
@@ -0,0 +1 @@
1
+ import "../src/i18n/index.js";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/project-packager",
3
3
  "license": "MIT",
4
- "version": "1.198.0-preview.94",
4
+ "version": "1.199.0-preview.92",
5
5
  "description": "UiPath Project Packager - core library for packing individual UiPath projects",
6
6
  "type": "module",
7
7
  "main": "./dist/index.js",
@@ -32,12 +32,12 @@
32
32
  "dist"
33
33
  ],
34
34
  "dependencies": {
35
- "@uipath/filesystem": "1.198.0",
36
- "@uipath/solutionpackager-tool-core": "1.198.0",
37
- "@uipath/common": "1.198.0"
35
+ "@uipath/filesystem": "1.199.0",
36
+ "@uipath/solutionpackager-tool-core": "1.199.0",
37
+ "@uipath/common": "1.199.0"
38
38
  },
39
39
  "peerDependencies": {
40
40
  "fflate": "^0.8.2"
41
41
  },
42
- "gitHead": "c888e1ce7cd807c1629d556241a0d07ab156841c"
42
+ "gitHead": "d7b66f18f30e2e80a17293b6a0b656b54da35d49"
43
43
  }