@uipath/codedapp-tool 1.202.0-preview.137 → 1.202.0-preview.138

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.
@@ -16,7 +16,7 @@ import {
16
16
  import {
17
17
  getFileSystem
18
18
  } from "./packager-tool-qyctya2j.js";
19
- import"./packager-tool-jke4p8q1.js";
19
+ import"./packager-tool-aybzcdfg.js";
20
20
  import"./packager-tool-0gctz400.js";
21
21
  import"./packager-tool-yc4kw997.js";
22
22
  import {
@@ -17481,6 +17481,26 @@ async function findProjectFile(projectDir) {
17481
17481
  null
17482
17482
  ];
17483
17483
  }
17484
+
17485
+ class ProjectManifestError extends Error {
17486
+ __projectManifestError = true;
17487
+ reason;
17488
+ constructor(message, reason) {
17489
+ super(message);
17490
+ this.name = "ProjectManifestError";
17491
+ this.reason = reason;
17492
+ }
17493
+ }
17494
+ function isProjectManifestError(error) {
17495
+ return !!error && typeof error === "object" && error.__projectManifestError === true;
17496
+ }
17497
+ function isMissingProjectTypeError(error) {
17498
+ return isProjectManifestError(error) && error.reason === "no-project-type";
17499
+ }
17500
+ function lastPathSegment(filePath) {
17501
+ const parts = filePath.split(/[/\\]/);
17502
+ return parts[parts.length - 1] ?? filePath;
17503
+ }
17484
17504
  async function readProjectFile(filePath, useProjectJson) {
17485
17505
  const fs = getFileSystem();
17486
17506
  const [readError, rawContent] = await catchError(fs.readFile(filePath, "utf-8"));
@@ -17490,7 +17510,7 @@ async function readProjectFile(filePath, useProjectJson) {
17490
17510
  const [parseError, content] = catchError(() => JSON.parse(rawContent));
17491
17511
  if (parseError) {
17492
17512
  return [
17493
- new Error(`Invalid JSON in project file: ${parseError.message}`),
17513
+ new ProjectManifestError(`Invalid JSON in project file: ${parseError.message}`, "invalid-json"),
17494
17514
  null
17495
17515
  ];
17496
17516
  }
@@ -17505,7 +17525,16 @@ async function readProjectFile(filePath, useProjectJson) {
17505
17525
  }
17506
17526
  ];
17507
17527
  }
17508
- return [new Error(`ProjectType not found in ${filePath}`), null];
17528
+ if (lastPathSegment(filePath) === "uipath.json") {
17529
+ return [
17530
+ new ProjectManifestError(`${filePath} has no 'ProjectType'. A uipath.json is only read as a code-first Functions project, which also needs a 'functions' entry. Other project types are registered from project.uiproj or project.json, not from uipath.json.`, "no-project-type"),
17531
+ null
17532
+ ];
17533
+ }
17534
+ return [
17535
+ new ProjectManifestError(`ProjectType not found in ${filePath}`, "no-project-type"),
17536
+ null
17537
+ ];
17509
17538
  }
17510
17539
  return [null, { content, projectType: normalizeProjectType(projectType) }];
17511
17540
  }
@@ -18343,6 +18372,7 @@ async function resourceRefreshAsync(solutionPath = ".", options = {}) {
18343
18372
  }
18344
18373
  export {
18345
18374
  EntryPointSpecEnhancer,
18375
+ ProjectManifestError,
18346
18376
  addProjectArtifactsToSolutionAsync,
18347
18377
  applyEntryPointEnhancementAsync,
18348
18378
  assertSolutionManifest,
@@ -18356,6 +18386,8 @@ export {
18356
18386
  findProjectFile,
18357
18387
  findResourceByKeyInRcs,
18358
18388
  findResourceInRcs,
18389
+ isMissingProjectTypeError,
18390
+ isProjectManifestError,
18359
18391
  normalizeFolderPath,
18360
18392
  readProjectFile,
18361
18393
  readSolutionFile,
@@ -18371,4 +18403,4 @@ export {
18371
18403
  writeSolutionFile
18372
18404
  };
18373
18405
 
18374
- //# debugId=1919410F25FB4E8D64756E2164756E21
18406
+ //# debugId=C9D4F23D6EC80E7464756E2164756E21
package/dist/index.js CHANGED
@@ -2,14 +2,14 @@
2
2
  import {
3
3
  metadata,
4
4
  registerCommands
5
- } from "./packager-tool-hmkqrzhj.js";
5
+ } from "./packager-tool-1qedv9b9.js";
6
6
  import {
7
7
  Command
8
8
  } from "./packager-tool-dhmzfax7.js";
9
9
  import"./packager-tool-8hncwr6a.js";
10
10
  import"./packager-tool-qyctya2j.js";
11
- import"./packager-tool-14ha5twz.js";
12
- import"./packager-tool-jke4p8q1.js";
11
+ import"./packager-tool-05wez2xw.js";
12
+ import"./packager-tool-aybzcdfg.js";
13
13
  import"./packager-tool-vv9c52ax.js";
14
14
  import"./packager-tool-0gctz400.js";
15
15
  import"./packager-tool-yc4kw997.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  zipSync
3
- } from "./packager-tool-jke4p8q1.js";
3
+ } from "./packager-tool-aybzcdfg.js";
4
4
 
5
5
  // ../packager/packager-core/dist/index.js
6
6
  class Path {
@@ -1158,8 +1158,7 @@ class ToolsFactoryRepository {
1158
1158
  getProjectToolFactory(projectType) {
1159
1159
  const factory = this.projectFactoryMap.get(projectType);
1160
1160
  if (!factory) {
1161
- const known = [...this.projectFactoryMap.keys()].join(", ");
1162
- throw new Error(`Cannot pack project type '${projectType}': no packager is installed for it. ` + `Project types that can be packed: ${known || "none"}.`);
1161
+ throw new Error(`Cannot pack project type '${projectType}': no packager is installed for it.`);
1163
1162
  }
1164
1163
  return factory;
1165
1164
  }
@@ -1835,4 +1834,4 @@ class WebAppToolFactory {
1835
1834
  }
1836
1835
  export { WEBAPP_MANIFEST_FILE_NAME, WebAppToolFactory };
1837
1836
 
1838
- //# debugId=858B2D102CDBECEC64756E2164756E21
1837
+ //# debugId=38E533D0C989997E64756E2164756E21
@@ -29,7 +29,7 @@ import {
29
29
  import {
30
30
  WEBAPP_MANIFEST_FILE_NAME,
31
31
  WebAppToolFactory
32
- } from "./packager-tool-14ha5twz.js";
32
+ } from "./packager-tool-05wez2xw.js";
33
33
  import {
34
34
  FormData as FormData2,
35
35
  fetch_blob_default,
@@ -30726,7 +30726,7 @@ var require_ignore = __commonJS(function(exports, module) {
30726
30726
  var package_default = {
30727
30727
  name: "@uipath/codedapp-tool",
30728
30728
  license: "MIT",
30729
- version: "1.202.0-preview.137",
30729
+ version: "1.202.0-preview.138",
30730
30730
  description: "Build, pack, publish, deploy, and manage UiPath Coded Web Applications.",
30731
30731
  keywords: [
30732
30732
  "cli-tool",
@@ -54878,7 +54878,7 @@ function querystringSingleKey(key, value, keyPrefix = "") {
54878
54878
  var package_default2 = {
54879
54879
  name: "@uipath/solution-sdk",
54880
54880
  license: "MIT",
54881
- version: "1.202.0-preview.137",
54881
+ version: "1.202.0-preview.138",
54882
54882
  repository: {
54883
54883
  type: "git",
54884
54884
  url: "https://github.com/UiPath/cli.git",
@@ -55177,7 +55177,7 @@ var SUCCEEDED = "creationsucceeded";
55177
55177
  var TERMINAL = new Set([SUCCEEDED, "creationfailed", "validationfailed"]);
55178
55178
  // src/services/project-artifacts.ts
55179
55179
  async function ensureProjectArtifacts(args) {
55180
- const { addProjectArtifactsToSolutionAsync } = await import("./index-bmzhf5fp.js");
55180
+ const { addProjectArtifactsToSolutionAsync } = await import("./index-vdjgp5by.js");
55181
55181
  return addProjectArtifactsToSolutionAsync(args);
55182
55182
  }
55183
55183
 
@@ -59403,4 +59403,4 @@ var registerCommands = async (program) => {
59403
59403
 
59404
59404
  export { metadata, registerCommands };
59405
59405
 
59406
- //# debugId=11185A09C57E31F364756E2164756E21
59406
+ //# debugId=1E44F791079025D664756E2164756E21
@@ -29,8 +29,7 @@ class ToolsFactoryRepository {
29
29
  getProjectToolFactory(projectType) {
30
30
  const factory = this.projectFactoryMap.get(projectType);
31
31
  if (!factory) {
32
- const known = [...this.projectFactoryMap.keys()].join(", ");
33
- throw new Error(`Cannot pack project type '${projectType}': no packager is installed for it. ` + `Project types that can be packed: ${known || "none"}.`);
32
+ throw new Error(`Cannot pack project type '${projectType}': no packager is installed for it.`);
34
33
  }
35
34
  return factory;
36
35
  }
@@ -1512,4 +1511,4 @@ I18nManager.registerTranslations("zu", zu);
1512
1511
  I18nManager.setLocale("en");
1513
1512
  export { zipSync, toolsFactoryRepository };
1514
1513
 
1515
- //# debugId=3B2068582B5A583164756E2164756E21
1514
+ //# debugId=7F63F7116E65B50564756E2164756E21
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  WebAppToolFactory
3
- } from "./packager-tool-14ha5twz.js";
3
+ } from "./packager-tool-05wez2xw.js";
4
4
  import {
5
5
  toolsFactoryRepository
6
- } from "./packager-tool-jke4p8q1.js";
6
+ } from "./packager-tool-aybzcdfg.js";
7
7
  import"./packager-tool-1yh8g550.js";
8
8
 
9
9
  // src/packager-tool.ts
package/dist/tool.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  metadata,
3
3
  registerCommands
4
- } from "./packager-tool-hmkqrzhj.js";
4
+ } from "./packager-tool-1qedv9b9.js";
5
5
  import"./packager-tool-dhmzfax7.js";
6
6
  import"./packager-tool-8hncwr6a.js";
7
7
  import"./packager-tool-qyctya2j.js";
8
- import"./packager-tool-14ha5twz.js";
9
- import"./packager-tool-jke4p8q1.js";
8
+ import"./packager-tool-05wez2xw.js";
9
+ import"./packager-tool-aybzcdfg.js";
10
10
  import"./packager-tool-vv9c52ax.js";
11
11
  import"./packager-tool-0gctz400.js";
12
12
  import"./packager-tool-yc4kw997.js";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/codedapp-tool",
3
3
  "license": "MIT",
4
- "version": "1.202.0-preview.137",
4
+ "version": "1.202.0-preview.138",
5
5
  "description": "Build, pack, publish, deploy, and manage UiPath Coded Web Applications.",
6
6
  "keywords": [
7
7
  "cli-tool",
@@ -28,5 +28,5 @@
28
28
  "publishConfig": {
29
29
  "registry": "https://registry.npmjs.org/"
30
30
  },
31
- "gitHead": "bbb20a6d3501afc3435a92af9ae2e9f7ab2e34f6"
31
+ "gitHead": "46372d5c4c4ae9352e9457a99e9d5efc1890cb48"
32
32
  }