@mastra/deployer 0.1.0 → 0.1.1
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/.turbo/turbo-build.log +12 -12
- package/.turbo/turbo-lint.log +31 -0
- package/CHANGELOG.md +30 -0
- package/dist/_tsup-dts-rollup.d.ts +6 -2
- package/dist/build/analyze.js +1 -1
- package/dist/build/index.js +3 -3
- package/dist/bundler/index.js +3 -3
- package/dist/{chunk-VCRMX3ZD.js → chunk-2S4LOARP.js} +1 -1
- package/dist/{chunk-E4D6R3B4.js → chunk-AXS5WSIK.js} +0 -1
- package/dist/{chunk-2YECHHR3.js → chunk-S6JYNXAW.js} +2 -2
- package/dist/{chunk-ERNQNTBH.js → chunk-Z3IHWUWI.js} +5 -2
- package/dist/index.js +7 -7
- package/dist/server/index.js +320 -223
- package/dist/templates/instrumentation-template.js +4 -3
- package/eslint.config.js +6 -0
- package/package.json +7 -4
- package/public/templates/instrumentation-template.js +4 -3
- package/src/build/analyze.ts +4 -2
- package/src/deploy/base.ts +1 -1
- package/src/deploy/log.ts +1 -1
- package/src/server/handlers/workflows.ts +40 -1
- package/src/server/index.ts +64 -3
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
|
|
2
|
-
> @mastra/deployer@0.1.
|
|
2
|
+
> @mastra/deployer@0.1.1-alpha.0 build C:\Users\Ward\projects\mastra\mastra\packages\deployer
|
|
3
3
|
> tsup src/index.ts src/build/index.ts src/server/index.ts src/build/bundler.ts src/build/analyze.ts src/bundler/index.ts --format esm --clean --experimental-dts --treeshake --publicDir
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts, src/build/analyze.ts, src/build/bundler.ts, src/build/index.ts, src/bundler/index.ts, src/server/index.ts
|
|
6
6
|
[34mCLI[39m Using tsconfig: tsconfig.json
|
|
7
7
|
[34mCLI[39m tsup v8.3.6
|
|
8
8
|
[34mTSC[39m Build start
|
|
9
|
-
[32mTSC[39m ⚡️ Build success in
|
|
9
|
+
[32mTSC[39m ⚡️ Build success in 7607ms
|
|
10
10
|
[34mDTS[39m Build start
|
|
11
11
|
[34mCLI[39m Target: es2022
|
|
12
12
|
Analysis will use the bundled TypeScript version 5.7.3
|
|
13
13
|
[36mWriting package typings: C:\Users\Ward\projects\mastra\mastra\packages\deployer\dist\_tsup-dts-rollup.d.ts[39m
|
|
14
|
-
[32mDTS[39m ⚡️ Build success in
|
|
14
|
+
[32mDTS[39m ⚡️ Build success in 4167ms
|
|
15
15
|
[34mCLI[39m Cleaning output folder
|
|
16
16
|
[34mESM[39m Build start
|
|
17
17
|
[32mESM[39m [1mdist\bundler\index.js [22m[32m172.00 B[39m
|
|
18
|
-
[32mESM[39m [1mdist\build\index.js [22m[32m361.00 B[39m
|
|
19
|
-
[32mESM[39m [1mdist\index.js [22m[32m3.73 KB[39m
|
|
20
18
|
[32mESM[39m [1mdist\build\analyze.js [22m[32m85.00 B[39m
|
|
21
|
-
[32mESM[39m [1mdist\build\
|
|
22
|
-
[32mESM[39m [1mdist\
|
|
23
|
-
[32mESM[39m [1mdist\chunk-
|
|
19
|
+
[32mESM[39m [1mdist\build\index.js [22m[32m383.00 B[39m
|
|
20
|
+
[32mESM[39m [1mdist\index.js [22m[32m3.72 KB[39m
|
|
21
|
+
[32mESM[39m [1mdist\chunk-S6JYNXAW.js [22m[32m4.40 KB[39m
|
|
24
22
|
[32mESM[39m [1mdist\chunk-YNXJO2XU.js [22m[32m2.08 KB[39m
|
|
25
|
-
[32mESM[39m [1mdist\
|
|
26
|
-
[32mESM[39m [1mdist\
|
|
27
|
-
[32mESM[39m [1mdist\chunk-
|
|
23
|
+
[32mESM[39m [1mdist\build\bundler.js [22m[32m102.00 B[39m
|
|
24
|
+
[32mESM[39m [1mdist\chunk-AXS5WSIK.js [22m[32m8.23 KB[39m
|
|
25
|
+
[32mESM[39m [1mdist\chunk-Z3IHWUWI.js [22m[32m8.13 KB[39m
|
|
26
|
+
[32mESM[39m [1mdist\server\index.js [22m[32m147.40 KB[39m
|
|
27
|
+
[32mESM[39m [1mdist\chunk-2S4LOARP.js [22m[32m7.41 KB[39m
|
|
28
28
|
[32mESM[39m [1mdist\chunk-KXS4XYEJ.js [22m[32m7.20 KB[39m
|
|
29
|
-
[32mESM[39m ⚡️ Build success in
|
|
29
|
+
[32mESM[39m ⚡️ Build success in 1862ms
|
|
@@ -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,35 @@
|
|
|
1
1
|
# @mastra/deployer
|
|
2
2
|
|
|
3
|
+
## 0.1.1
|
|
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
|
|
17
|
+
|
|
18
|
+
## 0.1.1-alpha.0
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- 936dc26: Add mastra server endpoints for watch/resume + plug watch and resume functionality to dev playground
|
|
23
|
+
- 91ef439: Add eslint and ran autofix
|
|
24
|
+
- aac1667: Improve treeshaking of core and output
|
|
25
|
+
- Updated dependencies [d59f1a8]
|
|
26
|
+
- Updated dependencies [91ef439]
|
|
27
|
+
- Updated dependencies [4a25be4]
|
|
28
|
+
- Updated dependencies [bf2e88f]
|
|
29
|
+
- Updated dependencies [2f0d707]
|
|
30
|
+
- Updated dependencies [aac1667]
|
|
31
|
+
- @mastra/core@0.2.1-alpha.0
|
|
32
|
+
|
|
3
33
|
## 0.1.0
|
|
4
34
|
|
|
5
35
|
### 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
|
}>;
|
package/dist/build/analyze.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { analyzeBundle } from '../chunk-
|
|
1
|
+
export { analyzeBundle } from '../chunk-Z3IHWUWI.js';
|
|
2
2
|
import '../chunk-YNXJO2XU.js';
|
package/dist/build/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { FileService, createWatcher, getBundler, getWatcher, getInputOptions as getWatcherInputOptions } from '../chunk-
|
|
2
|
-
export { Deps, writeTelemetryConfig } from '../chunk-
|
|
3
|
-
export { analyzeBundle } from '../chunk-
|
|
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';
|
package/dist/bundler/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { Bundler } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
import '../chunk-
|
|
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-
|
|
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,5 +1,5 @@
|
|
|
1
|
-
import { Deps, writeTelemetryConfig } from './chunk-
|
|
2
|
-
import { analyzeBundle } from './chunk-
|
|
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:
|
|
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-
|
|
2
|
-
export { FileService, getBundler, getWatcher } from './chunk-
|
|
3
|
-
import { Bundler } from './chunk-
|
|
4
|
-
import { Deps } from './chunk-
|
|
5
|
-
export { Deps, createChildProcessLogger, createPinoStream } from './chunk-
|
|
6
|
-
import './chunk-
|
|
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) {
|