@intuned/runtime-dev 0.1.0-test.3 → 0.1.0-test.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/Intuned.json +1 -1
  2. package/WebTemplate/api.ts +90 -92
  3. package/WebTemplate/controllers/async.ts +52 -48
  4. package/WebTemplate/controllers/authSessions/check.ts +3 -4
  5. package/WebTemplate/controllers/authSessions/create.ts +5 -7
  6. package/WebTemplate/controllers/authSessions/resumeOperation.ts +1 -1
  7. package/WebTemplate/controllers/runApi/helpers.ts +12 -7
  8. package/WebTemplate/index.playwright.ts +32 -42
  9. package/WebTemplate/jobs.ts +13 -2
  10. package/WebTemplate/utils.ts +51 -1
  11. package/api/test2.ts +7 -5
  12. package/auth-sessions/check.ts +3 -1
  13. package/auth-sessions/create.ts +10 -10
  14. package/bin/intuned-api-run +1 -1
  15. package/bin/intuned-auth-session-check +1 -1
  16. package/bin/intuned-auth-session-create +1 -1
  17. package/bin/intuned-auth-session-load +1 -1
  18. package/bin/intuned-auth-session-refresh +1 -1
  19. package/bin/intuned-browser-save-state +1 -1
  20. package/bin/intuned-browser-start +1 -1
  21. package/bin/intuned-build +1 -1
  22. package/bin/intuned-ts-check +1 -1
  23. package/dist/commands/api/run.js +4 -2
  24. package/dist/commands/auth-sessions/run-check.js +3 -1
  25. package/dist/commands/auth-sessions/run-create.js +5 -3
  26. package/dist/commands/build.js +6 -4
  27. package/dist/commands/common/browserUtils.js +1 -1
  28. package/dist/commands/common/getFirstLineNumber.test.js +2 -2
  29. package/dist/commands/common/tsNodeImport.d.ts +1 -0
  30. package/dist/commands/common/{getDefaultExportFromFile.js → tsNodeImport.js} +6 -5
  31. package/dist/commands/common/utils/settings.js +1 -2
  32. package/dist/commands/common/utils/webTemplate.js +2 -2
  33. package/dist/commands/interface/run.js +131 -105
  34. package/dist/commands/ts-check.js +2 -2
  35. package/dist/common/Logger/Logger/index.d.ts +1 -1
  36. package/dist/common/Logger/index.d.ts +1 -1
  37. package/dist/common/getPlaywrightConstructs.d.ts +1 -1
  38. package/dist/common/getPlaywrightConstructs.js +3 -3
  39. package/dist/common/runApi/errors.d.ts +1 -1
  40. package/dist/common/runApi/index.d.ts +5 -5
  41. package/dist/common/runApi/index.js +22 -54
  42. package/dist/common/runApi/types.d.ts +2 -4
  43. package/dist/common/runApi/types.js +0 -1
  44. package/dist/index.d.ts +4 -4
  45. package/dist/index.js +12 -12
  46. package/dist/runtime/RunError.d.ts +1 -1
  47. package/dist/runtime/executionHelpers.test.js +2 -2
  48. package/dist/runtime/export.d.ts +1 -1
  49. package/dist/runtime/extendPayload.d.ts +1 -1
  50. package/dist/runtime/extendPayload.js +1 -1
  51. package/dist/runtime/index.d.ts +7 -7
  52. package/dist/runtime/index.js +6 -6
  53. package/dist/runtime/runInfo.d.ts +1 -1
  54. package/dist/runtime/runInfo.js +1 -1
  55. package/package.json +6 -5
  56. package/tsconfig.json +1 -1
  57. package/dist/commands/common/getDefaultExportFromFile.d.ts +0 -1
  58. package/testing +0 -0
@@ -1,12 +1,12 @@
1
1
  import { Result } from "neverthrow";
2
- import { RunAutomationError } from "./errors";
2
+ import { RunAutomationError } from "./errors.js";
3
3
  import { Page, BrowserContext } from "@intuned/playwright-core";
4
- import { ExtendedRunApiParameters, RunApiResult, RunApiResultWithSessionOk } from "./types";
5
- export * from "./types";
6
- export * from "./errors";
4
+ import { ExtendedRunApiParameters, RunApiResult, RunApiResultWithSessionOk } from "./types.js";
5
+ export * from "./types.js";
6
+ export * from "./errors.js";
7
7
  export declare function runApiGenerator<ResultType = any, _YieldType = any, _NextType = any>(params: ExtendedRunApiParameters & {
8
8
  retrieveSession: true;
9
9
  }): AsyncGenerator<_YieldType, RunApiResult<ResultType, RunApiResultWithSessionOk>, _NextType>;
10
10
  export declare function runApiGenerator<ResultType = any, _YieldType = any, _NextType = any>(params: ExtendedRunApiParameters): AsyncGenerator<_YieldType, RunApiResult<ResultType>, _NextType>;
11
11
  export declare function runApi<ResultType = any>(params: ExtendedRunApiParameters): Promise<RunApiResult<ResultType>>;
12
- export declare function checkAuthSessionWithRetries(page: Page, context: BrowserContext, retries?: number): Promise<Result<boolean, RunAutomationError>>;
12
+ export declare function checkAuthSessionWithRetries(page: Page, context: BrowserContext, importFunction: ExtendedRunApiParameters["importFunction"], retries?: number): Promise<Result<boolean, RunAutomationError>>;
@@ -15,10 +15,9 @@ var _downloadDirectory = require("../../runtime/downloadDirectory");
15
15
  var _asyncLocalStorage = require("../asyncLocalStorage");
16
16
  var _fsExtra = _interopRequireWildcard(require("fs-extra"));
17
17
  var fs = _fsExtra;
18
- var _jwtTokenManager = require("../jwtTokenManager");
19
18
  var _contextStorageStateHelpers = require("../contextStorageStateHelpers");
20
19
  var _neverthrow = require("neverthrow");
21
- var _errors = require("./errors");
20
+ var _errors = require("./errors.js");
22
21
  Object.keys(_errors).forEach(function (key) {
23
22
  if (key === "default" || key === "__esModule") return;
24
23
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -32,7 +31,7 @@ Object.keys(_errors).forEach(function (key) {
32
31
  });
33
32
  var _constants = require("../constants");
34
33
  var _getPlaywrightConstructs = require("../getPlaywrightConstructs");
35
- var _types = require("./types");
34
+ var _types = require("./types.js");
36
35
  Object.keys(_types).forEach(function (key) {
37
36
  if (key === "default" || key === "__esModule") return;
38
37
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -49,6 +48,7 @@ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e;
49
48
  async function* runApiGenerator({
50
49
  retrieveSession = false,
51
50
  abortSignal,
51
+ importFunction,
52
52
  ...input
53
53
  }) {
54
54
  let traceStarted = false;
@@ -56,14 +56,13 @@ async function* runApiGenerator({
56
56
  automationFunction,
57
57
  runOptions,
58
58
  tracing,
59
- auth,
60
- functionsToken
59
+ auth
61
60
  } = _types.runApiParametersSchema.parse(input);
62
- _jwtTokenManager.backendFunctionsTokenManager.token = functionsToken;
63
- const downloadsPath = (0, _downloadDirectory.getDownloadDirectoryPath)();
64
61
  let page;
65
62
  let context;
63
+ let downloadsPath;
66
64
  if (runOptions.environment === "deployed") {
65
+ downloadsPath = (0, _downloadDirectory.getDownloadDirectoryPath)();
67
66
  const {
68
67
  headless,
69
68
  proxy
@@ -87,10 +86,6 @@ async function* runApiGenerator({
87
86
  context
88
87
  } = await (0, _getPlaywrightConstructs.getPlaywrightConstructsForMode)(mode, cdpAddress, auth === null || auth === void 0 ? void 0 : auth.session));
89
88
  }
90
- const executionContext = (0, _asyncLocalStorage.getExecutionContext)();
91
- if (!executionContext) {
92
- throw "";
93
- }
94
89
  async function saveTraceIfNeeded({
95
90
  errorMessage
96
91
  }) {
@@ -128,12 +123,10 @@ async function* runApiGenerator({
128
123
  var _getExecutionContext;
129
124
  if (auth !== null && auth !== void 0 && auth.runCheck) {
130
125
  if (!auth.session) {
131
- return (0, _neverthrow.err)({
132
- code: "AuthRequiredError"
133
- });
126
+ return (0, _neverthrow.err)(new _errors.AuthRequiredError());
134
127
  }
135
128
  console.log("Running auth check");
136
- const authCheckResult = await checkAuthSessionWithRetries(page, context, 2);
129
+ const authCheckResult = await checkAuthSessionWithRetries(page, context, importFunction, 2);
137
130
  if (authCheckResult.isErr()) {
138
131
  const error = authCheckResult.error;
139
132
  if (["APINotFoundError", "InvalidAPIError"].includes(error.code)) {
@@ -142,20 +135,17 @@ async function* runApiGenerator({
142
135
  return authCheckResult;
143
136
  }
144
137
  if (!authCheckResult.value) {
145
- return (0, _neverthrow.err)({
146
- code: "AuthCheckFailedError"
147
- });
138
+ return (0, _neverthrow.err)(new _errors.AuthCheckFailedError());
148
139
  }
149
140
  }
150
- console.log("Running function", automationFunction.name);
151
141
  const args = [...(automationFunction.params ? [automationFunction.params] : []), page, context];
152
- const importResult = await importFunction(automationFunction.name);
153
- if (importResult.isErr()) {
154
- return importResult;
142
+ const validatedModuleResult = await importUsingImportFunction(automationFunction.name, importFunction);
143
+ if (validatedModuleResult.isErr()) {
144
+ return validatedModuleResult;
155
145
  }
156
146
  let result;
157
- if (importResult.value.type === "async-generator") {
158
- const generator = importResult.value.generator(...args);
147
+ if (validatedModuleResult.value.type === "async-generator") {
148
+ const generator = validatedModuleResult.value.generator(...args);
159
149
  let next = undefined;
160
150
  while (true) {
161
151
  const generatorResult = await generator.next(...(next ? [next] : []));
@@ -167,7 +157,7 @@ async function* runApiGenerator({
167
157
  break;
168
158
  }
169
159
  } else {
170
- result = await importResult.value.func(...args);
160
+ result = await validatedModuleResult.value.func(...args);
171
161
  }
172
162
  return (0, _neverthrow.ok)({
173
163
  result,
@@ -197,7 +187,9 @@ async function* runApiGenerator({
197
187
  errorMessage: "failed to save trace"
198
188
  });
199
189
  await context.close();
200
- await fs.remove(downloadsPath);
190
+ if (downloadsPath !== undefined) {
191
+ await fs.remove(downloadsPath);
192
+ }
201
193
  }
202
194
  }
203
195
  async function runApi(params) {
@@ -211,13 +203,13 @@ async function runApi(params) {
211
203
  }
212
204
  return (0, _neverthrow.err)(new _errors.InvalidApiError("Expected API to be async function, got async generator"));
213
205
  }
214
- async function checkAuthSessionWithRetries(page, context, retries = 3) {
206
+ async function checkAuthSessionWithRetries(page, context, importFunction, retries = 3) {
215
207
  if (retries === 0) {
216
208
  return (0, _neverthrow.ok)(false);
217
209
  }
218
210
  let tryNumber = 0;
219
211
  console.log("Checking auth session with retries", `${_constants.AUTH_SESSIONS_FOLDER_NAME}/check`);
220
- const importResult = await importFunction(`${_constants.AUTH_SESSIONS_FOLDER_NAME}/check`);
212
+ const importResult = await importUsingImportFunction(`${_constants.AUTH_SESSIONS_FOLDER_NAME}/check`, importFunction);
221
213
  if (importResult.isErr()) {
222
214
  return (0, _neverthrow.err)(importResult.error);
223
215
  }
@@ -232,33 +224,9 @@ async function checkAuthSessionWithRetries(page, context, retries = 3) {
232
224
  }
233
225
  return (0, _neverthrow.ok)(false);
234
226
  }
235
- async function importFunction(path) {
236
- const functionNameParts = path.split("/");
237
- const functionNameDepth = functionNameParts.length;
227
+ async function importUsingImportFunction(path, importFunction) {
238
228
  try {
239
- let imported = undefined;
240
- switch (functionNameDepth) {
241
- case 1:
242
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}.ts`);
243
- break;
244
- case 2:
245
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}/${functionNameParts[1]}.ts`);
246
- break;
247
- case 3:
248
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}/${functionNameParts[1]}/${functionNameParts[2]}.ts`);
249
- break;
250
- case 4:
251
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}/${functionNameParts[1]}/${functionNameParts[2]}/${functionNameParts[3]}.ts`);
252
- break;
253
- case 5:
254
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}/${functionNameParts[1]}/${functionNameParts[2]}/${functionNameParts[3]}/${functionNameParts[4]}.ts`);
255
- break;
256
- case 6:
257
- imported = await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`${functionNameParts[0]}/${functionNameParts[1]}/${functionNameParts[2]}/${functionNameParts[3]}/${functionNameParts[4]}/${functionNameParts[5]}.ts`);
258
- break;
259
- default:
260
- return (0, _neverthrow.err)(new _errors.MaxLevelsExceededError(5));
261
- }
229
+ const imported = importFunction ? await importFunction(path) : await (specifier => new Promise(r => r(specifier)).then(s => _interopRequireWildcard(require(s))))(`./${path}.ts`);
262
230
  if (!imported || !imported.default || !imported.default.constructor) {
263
231
  return (0, _neverthrow.err)(new _errors.InvalidApiError("API file path does not have a default export"));
264
232
  }
@@ -1,7 +1,7 @@
1
1
  import type { IntunedStorageState } from "../contextStorageStateHelpers";
2
2
  import type { Payload } from "../../runtime/export";
3
3
  import type { Result } from "neverthrow";
4
- import type { RunAutomationError } from "./errors";
4
+ import type { RunAutomationError } from "./errors.js";
5
5
  import z from "zod";
6
6
  export interface PayloadToAppend {
7
7
  apiName: string;
@@ -125,7 +125,6 @@ export declare const runApiSessionSchema: z.ZodDiscriminatedUnion<"type", [z.Zod
125
125
  };
126
126
  }>]>;
127
127
  export declare const runApiParametersSchema: z.ZodObject<{
128
- functionsToken: z.ZodOptional<z.ZodString>;
129
128
  automationFunction: z.ZodObject<{
130
129
  name: z.ZodString;
131
130
  params: z.ZodOptional<z.ZodAny>;
@@ -383,7 +382,6 @@ export declare const runApiParametersSchema: z.ZodObject<{
383
382
  cdpAddress: string;
384
383
  };
385
384
  retrieveSession: boolean;
386
- functionsToken?: string | undefined;
387
385
  auth?: {
388
386
  session: {
389
387
  type: "file";
@@ -419,7 +417,6 @@ export declare const runApiParametersSchema: z.ZodObject<{
419
417
  name: string;
420
418
  params?: any;
421
419
  };
422
- functionsToken?: string | undefined;
423
420
  tracing?: {
424
421
  enabled: false;
425
422
  } | {
@@ -475,6 +472,7 @@ export type RunApiSession = z.infer<typeof runApiSessionSchema>;
475
472
  export type RunApiParameters = z.input<typeof runApiParametersSchema>;
476
473
  export type ExtendedRunApiParameters = RunApiParameters & {
477
474
  abortSignal?: AbortSignal;
475
+ importFunction?: (name: string) => Promise<any> | undefined;
478
476
  };
479
477
  export type RunApiResultOk<R = any> = {
480
478
  result: R;
@@ -14,7 +14,6 @@ const runApiSessionSchema = exports.runApiSessionSchema = _zod.default.discrimin
14
14
  state: _zod.default.custom(v => v)
15
15
  })]);
16
16
  const runApiParametersSchema = exports.runApiParametersSchema = _zod.default.object({
17
- functionsToken: _zod.default.string().optional(),
18
17
  automationFunction: _zod.default.object({
19
18
  name: _zod.default.string(),
20
19
  params: _zod.default.any().optional()
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { extendPayload, extendTimeout, runInfo, RunError, requestMultipleChoice, requestOTP, } from "./runtime";
2
- export { runWithContext, getExecutionContext, } from "./common/asyncLocalStorage";
3
- export { getDownloadDirectoryPath } from "./runtime/downloadDirectory";
4
- export { getProductionPlaywrightConstructs } from "./common/getPlaywrightConstructs";
1
+ export { extendPayload, extendTimeout, runInfo, RunError, requestMultipleChoice, requestOTP, } from "./runtime/index.js";
2
+ export { runWithContext, getExecutionContext, } from "./common/asyncLocalStorage/index.js";
3
+ export { getDownloadDirectoryPath } from "./runtime/downloadDirectory.js";
4
+ export { getProductionPlaywrightConstructs } from "./common/getPlaywrightConstructs.js";
package/dist/index.js CHANGED
@@ -6,19 +6,19 @@ Object.defineProperty(exports, "__esModule", {
6
6
  Object.defineProperty(exports, "RunError", {
7
7
  enumerable: true,
8
8
  get: function () {
9
- return _runtime.RunError;
9
+ return _index.RunError;
10
10
  }
11
11
  });
12
12
  Object.defineProperty(exports, "extendPayload", {
13
13
  enumerable: true,
14
14
  get: function () {
15
- return _runtime.extendPayload;
15
+ return _index.extendPayload;
16
16
  }
17
17
  });
18
18
  Object.defineProperty(exports, "extendTimeout", {
19
19
  enumerable: true,
20
20
  get: function () {
21
- return _runtime.extendTimeout;
21
+ return _index.extendTimeout;
22
22
  }
23
23
  });
24
24
  Object.defineProperty(exports, "getDownloadDirectoryPath", {
@@ -30,7 +30,7 @@ Object.defineProperty(exports, "getDownloadDirectoryPath", {
30
30
  Object.defineProperty(exports, "getExecutionContext", {
31
31
  enumerable: true,
32
32
  get: function () {
33
- return _asyncLocalStorage.getExecutionContext;
33
+ return _index2.getExecutionContext;
34
34
  }
35
35
  });
36
36
  Object.defineProperty(exports, "getProductionPlaywrightConstructs", {
@@ -42,28 +42,28 @@ Object.defineProperty(exports, "getProductionPlaywrightConstructs", {
42
42
  Object.defineProperty(exports, "requestMultipleChoice", {
43
43
  enumerable: true,
44
44
  get: function () {
45
- return _runtime.requestMultipleChoice;
45
+ return _index.requestMultipleChoice;
46
46
  }
47
47
  });
48
48
  Object.defineProperty(exports, "requestOTP", {
49
49
  enumerable: true,
50
50
  get: function () {
51
- return _runtime.requestOTP;
51
+ return _index.requestOTP;
52
52
  }
53
53
  });
54
54
  Object.defineProperty(exports, "runInfo", {
55
55
  enumerable: true,
56
56
  get: function () {
57
- return _runtime.runInfo;
57
+ return _index.runInfo;
58
58
  }
59
59
  });
60
60
  Object.defineProperty(exports, "runWithContext", {
61
61
  enumerable: true,
62
62
  get: function () {
63
- return _asyncLocalStorage.runWithContext;
63
+ return _index2.runWithContext;
64
64
  }
65
65
  });
66
- var _runtime = require("./runtime");
67
- var _asyncLocalStorage = require("./common/asyncLocalStorage");
68
- var _downloadDirectory = require("./runtime/downloadDirectory");
69
- var _getPlaywrightConstructs = require("./common/getPlaywrightConstructs");
66
+ var _index = require("./runtime/index.js");
67
+ var _index2 = require("./common/asyncLocalStorage/index.js");
68
+ var _downloadDirectory = require("./runtime/downloadDirectory.js");
69
+ var _getPlaywrightConstructs = require("./common/getPlaywrightConstructs.js");
@@ -1,4 +1,4 @@
1
- import { RunErrorOptions } from "./export";
1
+ import { RunErrorOptions } from "./export.js";
2
2
  export declare class RunError extends Error {
3
3
  options: RunErrorOptions;
4
4
  constructor(message: string, options?: RunErrorOptions);
@@ -2,8 +2,8 @@
2
2
 
3
3
  var _vitest = require("vitest");
4
4
  var _asyncLocalStorage = require("../common/asyncLocalStorage");
5
- var _index = require("./index");
6
- var _enums = require("./enums");
5
+ var _index = require("./index.js");
6
+ var _enums = require("./enums.js");
7
7
  (0, _vitest.describe)("Execution Helpers", () => {
8
8
  (0, _vitest.it)("should be able to get execution info", () => {
9
9
  (0, _asyncLocalStorage.runWithContext)({
@@ -1,4 +1,4 @@
1
- import { RunEnvironment } from "./enums";
1
+ import { RunEnvironment } from "./enums.js";
2
2
 
3
3
  /**
4
4
  * ## Description
@@ -1,2 +1,2 @@
1
- import { Payload } from "./export";
1
+ import { Payload } from "./export.js";
2
2
  export declare function extendPayload(payload: Payload | Payload[]): void;
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.extendPayload = extendPayload;
7
7
  var _asyncLocalStorage = require("../common/asyncLocalStorage");
8
- var _extendTimeout = require("./extendTimeout");
8
+ var _extendTimeout = require("./extendTimeout.js");
9
9
  function extendPayload(payload) {
10
10
  const context = (0, _asyncLocalStorage.getExecutionContext)();
11
11
  if (!context) {
@@ -1,7 +1,7 @@
1
- export { extendPayload } from "./extendPayload";
2
- export { extendTimeout } from "./extendTimeout";
3
- export { runInfo } from "./runInfo";
4
- export { RunError } from "./RunError";
5
- export { requestMultipleChoice, requestOTP } from "./requestMoreInfo";
6
- export type { RequestMoreInfoDetails } from "./requestMoreInfo";
7
- export { getDownloadDirectoryPath } from "./downloadDirectory";
1
+ export { extendPayload } from "./extendPayload.js";
2
+ export { extendTimeout } from "./extendTimeout.js";
3
+ export { runInfo } from "./runInfo.js";
4
+ export { RunError } from "./RunError.js";
5
+ export { requestMultipleChoice, requestOTP } from "./requestMoreInfo.js";
6
+ export type { RequestMoreInfoDetails } from "./requestMoreInfo.js";
7
+ export { getDownloadDirectoryPath } from "./downloadDirectory.js";
@@ -45,9 +45,9 @@ Object.defineProperty(exports, "runInfo", {
45
45
  return _runInfo.runInfo;
46
46
  }
47
47
  });
48
- var _extendPayload = require("./extendPayload");
49
- var _extendTimeout = require("./extendTimeout");
50
- var _runInfo = require("./runInfo");
51
- var _RunError = require("./RunError");
52
- var _requestMoreInfo = require("./requestMoreInfo");
53
- var _downloadDirectory = require("./downloadDirectory");
48
+ var _extendPayload = require("./extendPayload.js");
49
+ var _extendTimeout = require("./extendTimeout.js");
50
+ var _runInfo = require("./runInfo.js");
51
+ var _RunError = require("./RunError.js");
52
+ var _requestMoreInfo = require("./requestMoreInfo.js");
53
+ var _downloadDirectory = require("./downloadDirectory.js");
@@ -1,2 +1,2 @@
1
- import { RunInfo } from "./export";
1
+ import { RunInfo } from "./export.js";
2
2
  export declare function runInfo(): RunInfo;
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.runInfo = runInfo;
7
7
  var _asyncLocalStorage = require("../common/asyncLocalStorage");
8
- var _enums = require("./enums");
8
+ var _enums = require("./enums.js");
9
9
  function runInfo() {
10
10
  const context = (0, _asyncLocalStorage.getExecutionContext)();
11
11
  if (!context) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intuned/runtime-dev",
3
- "version": "0.1.0-test.3",
3
+ "version": "0.1.0-test.31",
4
4
  "description": "Intuned runtime",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",
@@ -12,8 +12,7 @@
12
12
  "./dist/common/jwtTokenManager": "./dist/common/jwtTokenManager.js",
13
13
  "./dist/common/asyncLocalStorage": "./dist/common/asyncLocalStorage/index.js",
14
14
  "./dist/common/cleanEnvironmentVariables": "./dist/common/cleanEnvironmentVariables.js",
15
- "./dist/common/constants": "./dist/common/constants.js",
16
- "./dist/commands/interface/run": "./dist/commands/interface/run.js"
15
+ "./dist/common/constants": "./dist/common/constants.js"
17
16
  },
18
17
  "types": "./dist/index.d.ts",
19
18
  "author": "Intuned Team",
@@ -51,6 +50,7 @@
51
50
  "intuned-ts-check": "./bin/intuned-ts-check"
52
51
  },
53
52
  "dependencies": {
53
+ "@babel/plugin-syntax-dynamic-import": "^7.8.3",
54
54
  "@intuned/playwright": "^1.44.1-4",
55
55
  "@intuned/playwright-core": "^1.44.1-4",
56
56
  "@rollup/plugin-commonjs": "^25.0.2",
@@ -65,6 +65,7 @@
65
65
  "@types/node": "^20.4.1",
66
66
  "applicationinsights": "^2.9.2",
67
67
  "async-retry": "^1.3.3",
68
+ "babel-plugin-dynamic-import-node": "^2.3.3",
68
69
  "chalk": "^4.1.2",
69
70
  "commander": "^11.0.0",
70
71
  "cross-fetch": "^4.0.0",
@@ -89,12 +90,12 @@
89
90
  "source-map": "^0.7.4",
90
91
  "stack-utils": "^2.0.6",
91
92
  "ts-morph": "^21.0.1",
92
- "ts-node": "^10.9.1",
93
93
  "tslib": "^2.6.0",
94
94
  "typescript": "^5.1.6",
95
95
  "wait-on": "^7.2.0",
96
96
  "zod": "^3.21.4",
97
- "zod-validation-error": "^3.0.3"
97
+ "zod-validation-error": "^3.0.3",
98
+ "ts-node": "^10.9.1"
98
99
  },
99
100
  "devDependencies": {
100
101
  "@babel/cli": "^7.23.4",
package/tsconfig.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "target": "es2021",
4
4
  "module": "esnext",
5
5
  "esModuleInterop": true,
6
- "moduleResolution": "bundler",
6
+ "moduleResolution": "node",
7
7
  "resolveJsonModule": true,
8
8
  "outDir": "./dist",
9
9
  "strict": false,
@@ -1 +0,0 @@
1
- export declare function getDefaultExportFromFile(apiFilePath: string): Promise<any>;
package/testing DELETED
Binary file