@mastra/deployer 0.1.0 → 0.1.1-alpha.0

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.
@@ -0,0 +1,31 @@
1
+
2
+ > @mastra/deployer@0.1.0 lint C:\Users\Ward\projects\mastra\mastra\packages\deployer
3
+ > eslint .
4
+
5
+
6
+ C:\Users\Ward\projects\mastra\mastra\packages\deployer\src\bundler\index.ts
7
+ 1:1 warning `@mastra/core/bundler` import should occur after import of `node:url` import/order
8
+ 2:1 warning `@rollup/plugin-virtual` import should occur after import of `node:url` import/order
9
+ 3:1 warning `fs-extra` import should occur after import of `node:url` import/order
10
+ 8:1 warning `rollup` type import should occur after import of `fs-extra/esm` import/order
11
+
12
+ C:\Users\Ward\projects\mastra\mastra\packages\deployer\src\deploy\log.ts
13
+ 1:1 warning `@mastra/core/logger` type import should occur after import of `stream` import/order
14
+
15
+ C:\Users\Ward\projects\mastra\mastra\packages\deployer\src\server\handlers\agents.ts
16
+ 6:1 warning `hono/http-exception` import should occur before import of `superjson` import/order
17
+
18
+ C:\Users\Ward\projects\mastra\mastra\packages\deployer\src\server\handlers\tools.ts
19
+ 5:1 warning `hono/http-exception` import should occur before import of `superjson` import/order
20
+
21
+ C:\Users\Ward\projects\mastra\mastra\packages\deployer\src\server\index.ts
22
+ 8:1 warning `path` import should occur before import of `@hono/node-server` import/order
23
+ 9:1 warning `url` import should occur before import of `@hono/node-server` import/order
24
+ 11:1 warning `fs/promises` import should occur before import of `@hono/node-server` import/order
25
+ 12:1 warning `hono/body-limit` import should occur before import of `hono-openapi` import/order
26
+ 13:1 warning `hono/cors` import should occur before import of `hono-openapi` import/order
27
+ 14:1 warning `hono/logger` import should occur before import of `hono-openapi` import/order
28
+
29
+ ✖ 13 problems (0 errors, 13 warnings)
30
+ 0 errors and 13 warnings potentially fixable with the `--fix` option.
31
+
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @mastra/deployer
2
2
 
3
+ ## 0.1.1-alpha.0
4
+
5
+ ### Patch Changes
6
+
7
+ - 936dc26: Add mastra server endpoints for watch/resume + plug watch and resume functionality to dev playground
8
+ - 91ef439: Add eslint and ran autofix
9
+ - aac1667: Improve treeshaking of core and output
10
+ - Updated dependencies [d59f1a8]
11
+ - Updated dependencies [91ef439]
12
+ - Updated dependencies [4a25be4]
13
+ - Updated dependencies [bf2e88f]
14
+ - Updated dependencies [2f0d707]
15
+ - Updated dependencies [aac1667]
16
+ - @mastra/core@0.2.1-alpha.0
17
+
3
18
  ## 0.1.0
4
19
 
5
20
  ### Minor Changes
@@ -3,10 +3,10 @@ import { BlankSchema } from 'hono/types';
3
3
  import { ContentfulStatusCode } from 'hono/utils/http-status';
4
4
  import type { Context } from 'hono';
5
5
  import { Hono } from 'hono';
6
- import { IDeployer } from '@mastra/core/deployer';
6
+ import type { IDeployer } from '@mastra/core/deployer';
7
7
  import { InputOption } from 'rollup';
8
8
  import { InputOptions } from 'rollup';
9
- import { Logger } from '@mastra/core/logger';
9
+ import type { Logger } from '@mastra/core/logger';
10
10
  import type { Logger as Logger_2 } from '@mastra/core';
11
11
  import type { Mastra } from '@mastra/core';
12
12
  import { MastraBase } from '@mastra/core/base';
@@ -316,6 +316,8 @@ export declare function removeDeployer(): babel_2.PluginObj;
316
316
 
317
317
  export declare function removeDeployer_alias_1(mastraEntry: string): Plugin;
318
318
 
319
+ export declare function resumeWorkflowHandler(c: Context): Promise<Response>;
320
+
319
321
  export declare function rewriteLibsqlImport(): babel_2.PluginObj;
320
322
 
321
323
  export declare function rootHandler(c: Context): Promise<Response & TypedResponse<"Hello to the Mastra API!", ContentfulStatusCode, "text">>;
@@ -347,6 +349,8 @@ declare type Variables = {
347
349
  playground: boolean;
348
350
  };
349
351
 
352
+ export declare function watchWorkflowHandler(c: Context): Promise<Response>;
353
+
350
354
  declare function writeTelemetryConfig(entryFile: string, outputDir: string): Promise<{
351
355
  hasCustomConfig: boolean;
352
356
  }>;
@@ -1,2 +1,2 @@
1
- export { analyzeBundle } from '../chunk-ERNQNTBH.js';
1
+ export { analyzeBundle } from '../chunk-Z3IHWUWI.js';
2
2
  import '../chunk-YNXJO2XU.js';
@@ -1,5 +1,5 @@
1
- export { FileService, createWatcher, getBundler, getWatcher, getInputOptions as getWatcherInputOptions } from '../chunk-VCRMX3ZD.js';
2
- export { Deps, writeTelemetryConfig } from '../chunk-E4D6R3B4.js';
3
- export { analyzeBundle } from '../chunk-ERNQNTBH.js';
1
+ export { FileService, createWatcher, getBundler, getWatcher, getInputOptions as getWatcherInputOptions } from '../chunk-2S4LOARP.js';
2
+ export { Deps, writeTelemetryConfig } from '../chunk-AXS5WSIK.js';
3
+ export { analyzeBundle } from '../chunk-Z3IHWUWI.js';
4
4
  export { createBundler, getInputOptions as getBundlerInputOptions } from '../chunk-KXS4XYEJ.js';
5
5
  import '../chunk-YNXJO2XU.js';
@@ -1,5 +1,5 @@
1
- export { Bundler } from '../chunk-2YECHHR3.js';
2
- import '../chunk-E4D6R3B4.js';
3
- import '../chunk-ERNQNTBH.js';
1
+ export { Bundler } from '../chunk-S6JYNXAW.js';
2
+ import '../chunk-AXS5WSIK.js';
3
+ import '../chunk-Z3IHWUWI.js';
4
4
  import '../chunk-KXS4XYEJ.js';
5
5
  import '../chunk-YNXJO2XU.js';
@@ -1,4 +1,4 @@
1
- import { aliasHono } from './chunk-ERNQNTBH.js';
1
+ import { aliasHono } from './chunk-Z3IHWUWI.js';
2
2
  import { getInputOptions, telemetryFix, libSqlFix } from './chunk-KXS4XYEJ.js';
3
3
  import { removeDeployer } from './chunk-YNXJO2XU.js';
4
4
  import alias from '@rollup/plugin-alias';
@@ -1,4 +1,3 @@
1
- import '@mastra/core/logger';
2
1
  import { spawn } from 'child_process';
3
2
  import { Transform } from 'stream';
4
3
  import { MastraBase } from '@mastra/core/base';
@@ -1,5 +1,5 @@
1
- import { Deps, writeTelemetryConfig } from './chunk-E4D6R3B4.js';
2
- import { analyzeBundle } from './chunk-ERNQNTBH.js';
1
+ import { Deps, writeTelemetryConfig } from './chunk-AXS5WSIK.js';
2
+ import { analyzeBundle } from './chunk-Z3IHWUWI.js';
3
3
  import { createBundler, getInputOptions } from './chunk-KXS4XYEJ.js';
4
4
  import { MastraBundler } from '@mastra/core/bundler';
5
5
  import virtual from '@rollup/plugin-virtual';
@@ -188,7 +188,7 @@ async function bundleExternals(depsToOptimize, outputDir, logger) {
188
188
  // this dependency breaks the build, so we need to exclude it
189
189
  // TODO actually fix this so we don't need to exclude it
190
190
  external: ["jsdom"],
191
- treeshake: true,
191
+ treeshake: "smallest",
192
192
  preserveSymlinks: true,
193
193
  plugins: [
194
194
  virtual(
@@ -207,7 +207,9 @@ async function bundleExternals(depsToOptimize, outputDir, logger) {
207
207
  ignoreTryCatch: false
208
208
  }),
209
209
  nodeResolve({
210
- preferBuiltins: true
210
+ preferBuiltins: true,
211
+ exportConditions: ["node", "import", "require"],
212
+ mainFields: ["module", "main"]
211
213
  }),
212
214
  // hono is imported from deployer, so we need to resolve from here instead of the project root
213
215
  aliasHono(),
@@ -244,6 +246,7 @@ async function validateOutput(output, reverseVirtualReferenceMap, outputDir, log
244
246
  if (file.isEntry && reverseVirtualReferenceMap.has(file.name)) {
245
247
  result.externalDependencies.add(reverseVirtualReferenceMap.get(file.name));
246
248
  }
249
+ console.log(file.fileName, file.isEntry, file.isDynamicEntry, err);
247
250
  }
248
251
  }
249
252
  return result;
package/dist/index.js CHANGED
@@ -1,17 +1,17 @@
1
- import { FileService } from './chunk-VCRMX3ZD.js';
2
- export { FileService, getBundler, getWatcher } from './chunk-VCRMX3ZD.js';
3
- import { Bundler } from './chunk-2YECHHR3.js';
4
- import { Deps } from './chunk-E4D6R3B4.js';
5
- export { Deps, createChildProcessLogger, createPinoStream } from './chunk-E4D6R3B4.js';
6
- import './chunk-ERNQNTBH.js';
1
+ import { FileService } from './chunk-2S4LOARP.js';
2
+ export { FileService, getBundler, getWatcher } from './chunk-2S4LOARP.js';
3
+ import { Bundler } from './chunk-S6JYNXAW.js';
4
+ import { Deps } from './chunk-AXS5WSIK.js';
5
+ export { Deps, createChildProcessLogger, createPinoStream } from './chunk-AXS5WSIK.js';
6
+ import './chunk-Z3IHWUWI.js';
7
7
  import './chunk-KXS4XYEJ.js';
8
8
  import './chunk-YNXJO2XU.js';
9
- import '@mastra/core/deployer';
10
9
  import * as babel from '@babel/core';
11
10
  import babel__default from '@babel/core';
12
11
  import { rollup } from 'rollup';
13
12
  import esbuild from 'rollup-plugin-esbuild';
14
13
 
14
+ // src/deploy/base.ts
15
15
  var Deployer = class extends Bundler {
16
16
  deps = new Deps();
17
17
  constructor(args) {