@uipath/project-packager 1.199.0 → 1.200.0-preview.117

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
@@ -22652,7 +22652,7 @@ var COMMAND_ATTRIBUTION = commandAttribution([
22652
22652
  ["agents", "build", ["uip.codedagent", "uip.agent"]],
22653
22653
  ["agenthub", "build", ["uip.agenthub"]],
22654
22654
  ["coded-apps", "build", ["uip.codedapp"]],
22655
- ["functions", "build", ["uip.functions"]],
22655
+ ["functions", "build", ["uip.function", "uip.functions"]],
22656
22656
  ["solution", "build", ["uip.solution"]],
22657
22657
  ["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
22658
22658
  ["llm-observability", "troubleshoot", ["uip.traces"]],
@@ -23190,14 +23190,11 @@ class TelemetryService {
23190
23190
  }
23191
23191
  async trackDependencyOperation(name, type, fn, properties) {
23192
23192
  const parentContext = this.getCurrentContext();
23193
- if (!parentContext) {
23194
- throw new Error("trackDependencyOperation must be called within a trackRequest block.");
23195
- }
23196
- const childContext = {
23193
+ const childContext = parentContext !== undefined ? {
23197
23194
  operationId: parentContext.operationId,
23198
23195
  parentId: parentContext.id,
23199
23196
  id: this.generateId()
23200
- };
23197
+ } : this.createRequestContext();
23201
23198
  const startTime = performance.now();
23202
23199
  try {
23203
23200
  const result = await this.contextStorage.run(childContext, fn);
@@ -23246,6 +23243,7 @@ class TelemetryService {
23246
23243
  }
23247
23244
  }
23248
23245
  var factorySlot = singleton("PackagerFactoryProvider");
23246
+ var moduleSlot = singleton("ToolModuleProvider");
23249
23247
 
23250
23248
  // src/base-browser-packager-factory.ts
23251
23249
  import { BrowserFileSystem } from "@uipath/filesystem/browser";
@@ -24082,7 +24080,7 @@ class ProjectPackager {
24082
24080
  }, cancellationToken);
24083
24081
  }
24084
24082
  async packProjectAsync(options, cancellationToken) {
24085
- return await this.telemetryService.trackRequest("ProjectPackager.Pack" /* ProjectPackagerPack */, async () => {
24083
+ return await this.telemetryService.trackDependencyOperation("ProjectPackager.Pack" /* ProjectPackagerPack */, "pack", async () => {
24086
24084
  try {
24087
24085
  await this.governancePolicyService.resolveGovernancePolicyAsync(options.validateOptions, options.connection, cancellationToken);
24088
24086
  let result = await this.packOptionsValidator.validateAsync(options, cancellationToken);
@@ -24167,7 +24165,7 @@ class ProjectPackager {
24167
24165
  return packageStreams;
24168
24166
  }
24169
24167
  async executeProjectOperationAsync(options, operationName, telemetryName, operation, _cancellationToken) {
24170
- return await this.telemetryService.trackRequest(telemetryName, async () => {
24168
+ return await this.telemetryService.trackDependencyOperation(telemetryName, operationName.toLowerCase(), async () => {
24171
24169
  try {
24172
24170
  const loadedProject = await this.projectLoader.loadProject(options.inputPath);
24173
24171
  const uiPathProject = {
@@ -24262,4 +24260,4 @@ export {
24262
24260
  BaseBrowserPackagerFactory
24263
24261
  };
24264
24262
 
24265
- //# debugId=84586968D1FD281C64756E2164756E21
24263
+ //# debugId=F73F22FB7739EA3164756E2164756E21
package/dist/index.js CHANGED
@@ -22652,7 +22652,7 @@ var COMMAND_ATTRIBUTION = commandAttribution([
22652
22652
  ["agents", "build", ["uip.codedagent", "uip.agent"]],
22653
22653
  ["agenthub", "build", ["uip.agenthub"]],
22654
22654
  ["coded-apps", "build", ["uip.codedapp"]],
22655
- ["functions", "build", ["uip.functions"]],
22655
+ ["functions", "build", ["uip.function", "uip.functions"]],
22656
22656
  ["solution", "build", ["uip.solution"]],
22657
22657
  ["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
22658
22658
  ["llm-observability", "troubleshoot", ["uip.traces"]],
@@ -23190,14 +23190,11 @@ class TelemetryService {
23190
23190
  }
23191
23191
  async trackDependencyOperation(name, type, fn, properties) {
23192
23192
  const parentContext = this.getCurrentContext();
23193
- if (!parentContext) {
23194
- throw new Error("trackDependencyOperation must be called within a trackRequest block.");
23195
- }
23196
- const childContext = {
23193
+ const childContext = parentContext !== undefined ? {
23197
23194
  operationId: parentContext.operationId,
23198
23195
  parentId: parentContext.id,
23199
23196
  id: this.generateId()
23200
- };
23197
+ } : this.createRequestContext();
23201
23198
  const startTime = performance.now();
23202
23199
  try {
23203
23200
  const result = await this.contextStorage.run(childContext, fn);
@@ -23246,6 +23243,7 @@ class TelemetryService {
23246
23243
  }
23247
23244
  }
23248
23245
  var factorySlot = singleton("PackagerFactoryProvider");
23246
+ var moduleSlot = singleton("ToolModuleProvider");
23249
23247
  // src/models/packager-parameters.ts
23250
23248
  import {
23251
23249
  LogLevel as LogLevel2
@@ -23645,7 +23643,7 @@ import { translate as translate3 } from "@uipath/solutionpackager-tool-core";
23645
23643
  var package_default = {
23646
23644
  name: "@uipath/project-packager",
23647
23645
  license: "MIT",
23648
- version: "1.199.0",
23646
+ version: "1.200.0-preview.117",
23649
23647
  description: "UiPath Project Packager - core library for packing individual UiPath projects",
23650
23648
  type: "module",
23651
23649
  main: "./dist/index.js",
@@ -23709,7 +23707,7 @@ var package_default = {
23709
23707
  "@uipath/packager-tool-workflowcompiler": "workspace:*",
23710
23708
  "@vitest/coverage-v8": "^4.1.6",
23711
23709
  jsdom: "^30.0.1",
23712
- typescript: "^6.0.2",
23710
+ typescript: "^7.0.2",
23713
23711
  "vite-tsconfig-paths": "^6.1.1",
23714
23712
  vitest: "^4.1.6"
23715
23713
  }
@@ -24734,7 +24732,7 @@ class ProjectPackager {
24734
24732
  }, cancellationToken);
24735
24733
  }
24736
24734
  async packProjectAsync(options, cancellationToken) {
24737
- return await this.telemetryService.trackRequest("ProjectPackager.Pack" /* ProjectPackagerPack */, async () => {
24735
+ return await this.telemetryService.trackDependencyOperation("ProjectPackager.Pack" /* ProjectPackagerPack */, "pack", async () => {
24738
24736
  try {
24739
24737
  await this.governancePolicyService.resolveGovernancePolicyAsync(options.validateOptions, options.connection, cancellationToken);
24740
24738
  let result = await this.packOptionsValidator.validateAsync(options, cancellationToken);
@@ -24819,7 +24817,7 @@ class ProjectPackager {
24819
24817
  return packageStreams;
24820
24818
  }
24821
24819
  async executeProjectOperationAsync(options, operationName, telemetryName, operation, _cancellationToken) {
24822
- return await this.telemetryService.trackRequest(telemetryName, async () => {
24820
+ return await this.telemetryService.trackDependencyOperation(telemetryName, operationName.toLowerCase(), async () => {
24823
24821
  try {
24824
24822
  const loadedProject = await this.projectLoader.loadProject(options.inputPath);
24825
24823
  const uiPathProject = {
@@ -24920,4 +24918,4 @@ export {
24920
24918
  BrowserContextStorage
24921
24919
  };
24922
24920
 
24923
- //# debugId=186ACF736D49FC5064756E2164756E21
24921
+ //# debugId=3302F3D60C04969564756E2164756E21
package/dist/node.js CHANGED
@@ -9823,7 +9823,7 @@ function buildCommandTerminalTelemetryProperties(input) {
9823
9823
  }
9824
9824
  var CommonTelemetryEvents = {
9825
9825
  Error: "uip.error",
9826
- ShipSucceeded: "ship_succeeded"
9826
+ ShipSucceeded: "uip.ship.succeeded"
9827
9827
  };
9828
9828
  function readRegistryValue(keyPath, valueName) {
9829
9829
  if (process.platform !== "win32") {
@@ -10360,14 +10360,11 @@ class TelemetryService {
10360
10360
  }
10361
10361
  async trackDependencyOperation(name, type2, fn, properties) {
10362
10362
  const parentContext = this.getCurrentContext();
10363
- if (!parentContext) {
10364
- throw new Error("trackDependencyOperation must be called within a trackRequest block.");
10365
- }
10366
- const childContext = {
10363
+ const childContext = parentContext !== undefined ? {
10367
10364
  operationId: parentContext.operationId,
10368
10365
  parentId: parentContext.id,
10369
10366
  id: this.generateId()
10370
- };
10367
+ } : this.createRequestContext();
10371
10368
  const startTime = performance.now();
10372
10369
  try {
10373
10370
  const result = await this.contextStorage.run(childContext, fn);
@@ -10416,6 +10413,8 @@ class TelemetryService {
10416
10413
  }
10417
10414
  }
10418
10415
  var providerSlot = singleton("TelemetryProvider");
10416
+ var sidecarEntrySlot = singleton("TelemetrySidecarEntry");
10417
+ var MAX_SPOOL_AGE_MS = 72 * 60 * 60 * 1000;
10419
10418
  var telemetryInstanceSlot = singleton("TelemetryService");
10420
10419
  var DEFAULT_AI_CONNECTION_STRING = atob("SW5zdHJ1bWVudGF0aW9uS2V5PTliZDM3NDgyLTgxMGUtNDQyYS1hYWE2LWQzOGVmNjVjNjY3NDtJbmdlc3Rpb25FbmRwb2ludD1odHRwczovL3dlc3RldXJvcGUtNS5pbi5hcHBsaWNhdGlvbmluc2lnaHRzLmF6dXJlLmNvbS87TGl2ZUVuZHBvaW50PWh0dHBzOi8vd2VzdGV1cm9wZS5saXZlZGlhZ25vc3RpY3MubW9uaXRvci5henVyZS5jb20vO0FwcGxpY2F0aW9uSWQ9MzU2OTdlZjEtOGJkMC00ZjE5LWEyN2MtZDg3Y2NhYzY2ZDJj");
10421
10420
  function getGlobalTelemetryInstance() {
@@ -10661,21 +10660,43 @@ function printTable(data, logFn, externalLogValue) {
10661
10660
  logFn(`Log: ${externalLogValue}`);
10662
10661
  }
10663
10662
  }
10663
+ function isPlainObjectArray(value) {
10664
+ return Array.isArray(value) && value.length > 0 && value.every(isPlainRecord);
10665
+ }
10666
+ function isNonEmptyPlainObject(value) {
10667
+ return isPlainRecord(value) && Object.keys(value).length > 0;
10668
+ }
10669
+ var NESTED_INDENT = " ";
10664
10670
  function printVerticalTable(data, logFn = console.log, externalLogValue) {
10665
10671
  const keys = Object.keys(data).filter((key) => !["code", "log"].includes(key.toLowerCase()));
10666
10672
  if (keys.length === 0)
10667
10673
  return;
10668
- const maxKeyWidth = Math.max(...keys.map((key) => key.length));
10674
+ const isBlockValue = (value) => isPlainObjectArray(value) || isNonEmptyPlainObject(value);
10675
+ const scalarKeys = keys.filter((key) => !isBlockValue(data[key]));
10676
+ const maxKeyWidth = scalarKeys.length > 0 ? Math.max(...scalarKeys.map((key) => key.length)) : 0;
10677
+ const termWidth = process.stdout.columns || 120;
10678
+ const nestedWidth = Math.max(termWidth - NESTED_INDENT.length, 1);
10669
10679
  keys.forEach((key) => {
10680
+ const value = data[key];
10681
+ if (isPlainObjectArray(value)) {
10682
+ logFn(`${key}:`);
10683
+ printResizableTable(value, (line) => logFn(`${NESTED_INDENT}${line}`), undefined, nestedWidth);
10684
+ return;
10685
+ }
10686
+ if (isNonEmptyPlainObject(value)) {
10687
+ logFn(`${key}:`);
10688
+ printVerticalTable(value, (line) => logFn(`${NESTED_INDENT}${line}`));
10689
+ return;
10690
+ }
10670
10691
  const keyCol = key.padEnd(maxKeyWidth);
10671
- logFn(`${keyCol} | ${cellToString(data[key])}`);
10692
+ logFn(`${keyCol} | ${cellToString(value)}`);
10672
10693
  });
10673
10694
  if (externalLogValue) {
10674
10695
  logFn("");
10675
10696
  logFn(`Log: ${externalLogValue}`);
10676
10697
  }
10677
10698
  }
10678
- function printResizableTable(data, logFn = console.log, externalLogValue) {
10699
+ function printResizableTable(data, logFn = console.log, externalLogValue, availableWidth) {
10679
10700
  if (data.length === 0)
10680
10701
  return;
10681
10702
  const keys = Object.keys(data[0]).filter((key) => !["code", "log"].includes(key.toLowerCase()));
@@ -10688,7 +10709,7 @@ function printResizableTable(data, logFn = console.log, externalLogValue) {
10688
10709
  const naturalWidths = keys.map((key) => Math.max(key.length, ...data.map((item) => cellToString(item[key]).length)));
10689
10710
  const separatorTotal = (keys.length - 1) * 3;
10690
10711
  const totalWidth = naturalWidths.reduce((a, b) => a + b, 0) + separatorTotal;
10691
- const termWidth = process.stdout.columns || 120;
10712
+ const termWidth = availableWidth ?? (process.stdout.columns || 120);
10692
10713
  if (totalWidth <= termWidth) {
10693
10714
  printTable(data, logFn, externalLogValue);
10694
10715
  return;
@@ -10769,6 +10790,19 @@ class FilterEvaluationError extends Error {
10769
10790
  this.instructions = `The --output-filter expression '${filter}' failed at evaluation time. ` + "Note that --output-filter operates on the 'Data' field of the envelope, not the full object. " + "For example, on a list result use 'length(@)' instead of 'Data | length(@)'.";
10770
10791
  }
10771
10792
  }
10793
+
10794
+ class FilterImplicitLimitError extends Error {
10795
+ __brand = "FilterImplicitLimitError";
10796
+ errorCode = "invalid_argument";
10797
+ instructions;
10798
+ retry = "RetryWillNotFix";
10799
+ result = RESULTS.ValidationError;
10800
+ constructor(defaultLimit) {
10801
+ super(`--output-filter requires an explicit --limit: this command defaults to --limit ${defaultLimit}, ` + `so the filter would silently apply to only the first ${defaultLimit} records.`);
10802
+ this.name = "FilterImplicitLimitError";
10803
+ this.instructions = "Pass --limit <n> to choose how many records the filter applies to. " + "To filter over all records, pass the command's maximum accepted --limit (see the option's description in --help).";
10804
+ }
10805
+ }
10772
10806
  function applyFilter(data, filter) {
10773
10807
  let result;
10774
10808
  try {
@@ -11020,7 +11054,7 @@ var COMMAND_ATTRIBUTION = commandAttribution([
11020
11054
  ["agents", "build", ["uip.codedagent", "uip.agent"]],
11021
11055
  ["agenthub", "build", ["uip.agenthub"]],
11022
11056
  ["coded-apps", "build", ["uip.codedapp"]],
11023
- ["functions", "build", ["uip.functions"]],
11057
+ ["functions", "build", ["uip.function", "uip.functions"]],
11024
11058
  ["solution", "build", ["uip.solution"]],
11025
11059
  ["maestro", "build", ["uip.maestro", "uip.case", "uip.flow"]],
11026
11060
  ["llm-observability", "troubleshoot", ["uip.traces"]],
@@ -11159,6 +11193,16 @@ function commandHelpHint(commandPath) {
11159
11193
  function isPromptCancellation(error) {
11160
11194
  return error instanceof Error && error.name === "ExitPromptError";
11161
11195
  }
11196
+ function implicitLimitViolation(cmd) {
11197
+ if (getOutputFilter() === undefined) {
11198
+ return;
11199
+ }
11200
+ const hasLimit = cmd.options.some((o) => o.attributeName() === "limit");
11201
+ if (!hasLimit || cmd.getOptionValueSource("limit") !== "default") {
11202
+ return;
11203
+ }
11204
+ return new FilterImplicitLimitError(String(cmd.opts().limit));
11205
+ }
11162
11206
  function exitCodeFromProcess(fallback) {
11163
11207
  return typeof process.exitCode === "number" ? process.exitCode : fallback;
11164
11208
  }
@@ -11172,7 +11216,13 @@ Command.prototype.trackedAction = function(context, fn, properties) {
11172
11216
  let errorMessage;
11173
11217
  let fallbackExitCode = EXIT_CODES.Success;
11174
11218
  clearRecordedCommandFailureTelemetry();
11175
- const [error] = await catchError(telemetry.runWithContext(requestContext, () => fn(...args)));
11219
+ const [error] = await catchError(telemetry.runWithContext(requestContext, () => {
11220
+ const violation = implicitLimitViolation(command);
11221
+ if (violation) {
11222
+ return Promise.reject(violation);
11223
+ }
11224
+ return fn(...args);
11225
+ }));
11176
11226
  if (error) {
11177
11227
  errorMessage = error instanceof Error ? error.message : String(error);
11178
11228
  logger.debug(`[trackedAction] ${telemetryName} failed: ${errorMessage}`);
@@ -11228,6 +11278,20 @@ Command.prototype.trackedAction = function(context, fn, properties) {
11228
11278
  var guardInstalledSlot = singleton("ConsoleGuardInstalled");
11229
11279
  var savedOriginalsSlot = singleton("ConsoleGuardOriginals");
11230
11280
  var DEFAULT_AUTH_TIMEOUT_MS = 5 * 60 * 1000;
11281
+ var HOST_GLOBAL_OPTIONS_WITH_VALUE = [
11282
+ "--output",
11283
+ "--output-filter",
11284
+ "--log-level",
11285
+ "--log-file",
11286
+ "--profile"
11287
+ ];
11288
+ var HOST_GLOBAL_FLAGS = [
11289
+ "--json",
11290
+ "--interactive",
11291
+ "--no-interactive"
11292
+ ];
11293
+ var VALUE_OPTIONS = new Set(HOST_GLOBAL_OPTIONS_WITH_VALUE);
11294
+ var BOOLEAN_FLAGS = new Set(HOST_GLOBAL_FLAGS);
11231
11295
  var modeSlot = singleton("InteractivityMode");
11232
11296
  var interactiveFlagSlot = singleton("InteractiveFlag");
11233
11297
  var PollOutcome = {
@@ -11279,6 +11343,8 @@ var ScreenLogger;
11279
11343
  ScreenLogger2.progress = progress;
11280
11344
  })(ScreenLogger ||= {});
11281
11345
  var sdkUserAgentHostToken = singleton("SdkUserAgentHostToken");
11346
+ var factorySlot = singleton("PackagerFactoryProvider");
11347
+ var moduleSlot = singleton("ToolModuleProvider");
11282
11348
  class ConsoleTelemetryProvider {
11283
11349
  async trackEvent(eventName, _properties) {
11284
11350
  console.debug(`[Telemetry] Event: ${eventName}`);
@@ -11294,7 +11360,6 @@ class ConsoleTelemetryProvider {
11294
11360
  }
11295
11361
  }
11296
11362
  var shippedKeysSlot = singleton("ShipSucceededDedupeKeys");
11297
- var factorySlot = singleton("PackagerFactoryProvider");
11298
11363
  // src/base-node-packager-factory.ts
11299
11364
  import { NodeFileSystem as NodeFileSystem2 } from "@uipath/filesystem";
11300
11365
  import { translate } from "@uipath/solutionpackager-tool-core";
@@ -12265,7 +12330,7 @@ class ProjectPackager {
12265
12330
  }, cancellationToken);
12266
12331
  }
12267
12332
  async packProjectAsync(options, cancellationToken) {
12268
- return await this.telemetryService.trackRequest("ProjectPackager.Pack" /* ProjectPackagerPack */, async () => {
12333
+ return await this.telemetryService.trackDependencyOperation("ProjectPackager.Pack" /* ProjectPackagerPack */, "pack", async () => {
12269
12334
  try {
12270
12335
  await this.governancePolicyService.resolveGovernancePolicyAsync(options.validateOptions, options.connection, cancellationToken);
12271
12336
  let result = await this.packOptionsValidator.validateAsync(options, cancellationToken);
@@ -12350,7 +12415,7 @@ class ProjectPackager {
12350
12415
  return packageStreams;
12351
12416
  }
12352
12417
  async executeProjectOperationAsync(options, operationName, telemetryName, operation, _cancellationToken) {
12353
- return await this.telemetryService.trackRequest(telemetryName, async () => {
12418
+ return await this.telemetryService.trackDependencyOperation(telemetryName, operationName.toLowerCase(), async () => {
12354
12419
  try {
12355
12420
  const loadedProject = await this.projectLoader.loadProject(options.inputPath);
12356
12421
  const uiPathProject = {
@@ -12702,7 +12767,7 @@ import { translate as translate9 } from "@uipath/solutionpackager-tool-core";
12702
12767
  var package_default = {
12703
12768
  name: "@uipath/project-packager",
12704
12769
  license: "MIT",
12705
- version: "1.199.0",
12770
+ version: "1.200.0-preview.117",
12706
12771
  description: "UiPath Project Packager - core library for packing individual UiPath projects",
12707
12772
  type: "module",
12708
12773
  main: "./dist/index.js",
@@ -12766,7 +12831,7 @@ var package_default = {
12766
12831
  "@uipath/packager-tool-workflowcompiler": "workspace:*",
12767
12832
  "@vitest/coverage-v8": "^4.1.6",
12768
12833
  jsdom: "^30.0.1",
12769
- typescript: "^6.0.2",
12834
+ typescript: "^7.0.2",
12770
12835
  "vite-tsconfig-paths": "^6.1.1",
12771
12836
  vitest: "^4.1.6"
12772
12837
  }
@@ -13159,4 +13224,4 @@ export {
13159
13224
  BaseNodePackagerFactory
13160
13225
  };
13161
13226
 
13162
- //# debugId=FFCECD367AEEA23564756E2164756E21
13227
+ //# debugId=283A25B7893D201064756E2164756E21
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/project-packager",
3
3
  "license": "MIT",
4
- "version": "1.199.0",
4
+ "version": "1.200.0-preview.117",
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.199.0",
36
- "@uipath/solutionpackager-tool-core": "1.199.0",
37
- "@uipath/common": "1.199.0"
35
+ "@uipath/filesystem": "1.200.0",
36
+ "@uipath/solutionpackager-tool-core": "1.200.0",
37
+ "@uipath/common": "1.200.0"
38
38
  },
39
39
  "peerDependencies": {
40
40
  "fflate": "^0.8.2"
41
41
  },
42
- "gitHead": "723e6801b77b5926ba75e75b6a756cc38b1b7adc"
42
+ "gitHead": "5ba432ca14252784a1e20c03f5a858a5ae39746e"
43
43
  }