gencow 0.1.181 → 0.1.182

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.
@@ -12,6 +12,7 @@ import {
12
12
  formatAppDiagnosticLogBlock,
13
13
  normalizeDiagnosticLogLines,
14
14
  } from "./app-diagnostics.mjs";
15
+ import { buildDeployClaimFromArchive } from "./deploy-package-claim.mjs";
15
16
  import { hasProjectDatabaseSchemaSource } from "./project-migration-manifest.mjs";
16
17
  import {
17
18
  extractActionableMigrationDiagnostic,
@@ -88,6 +89,24 @@ export function formatDevCloudLogEntry(msg, palette) {
88
89
  return `${palette.DIM}${ts}${palette.RESET} ${lvl}${src} ${msg.message}`;
89
90
  }
90
91
 
92
+ export async function buildDevCloudDeployProtocolHeaders({
93
+ bundle,
94
+ cliVersion,
95
+ buildDeployClaimFromArchiveImpl = buildDeployClaimFromArchive,
96
+ }) {
97
+ const version = cliVersion ?? "0.0.0";
98
+ const deployClaim = await buildDeployClaimFromArchiveImpl({
99
+ bundleBuffer: bundle,
100
+ declaredRuntime: "server",
101
+ cliVersion: version,
102
+ });
103
+ return {
104
+ "X-Gencow-Deploy-Claim": deployClaim.header,
105
+ "X-Gencow-Deploy-Protocol": "1",
106
+ "X-Gencow-CLI-Version": version,
107
+ };
108
+ }
109
+
91
110
  export function createDevCloudCommand(deps) {
92
111
  return async function devCloud(...cloudArgs) {
93
112
  const config = await deps.loadConfig();
@@ -232,6 +251,11 @@ export function createDevCloudCommand(deps) {
232
251
  writeFileSyncImpl: deps.writeFileSyncImpl,
233
252
  });
234
253
  if (auditMessage) deps.logImpl(auditMessage);
254
+ const protocolHeaders = await buildDevCloudDeployProtocolHeaders({
255
+ bundle,
256
+ cliVersion: deps.cliVersion,
257
+ buildDeployClaimFromArchiveImpl: deps.buildDeployClaimFromArchiveImpl,
258
+ });
235
259
  const form = new FormData();
236
260
  form.append("bundle", new Blob([bundle], { type: "application/gzip" }), "bundle.tar.gz");
237
261
 
@@ -240,7 +264,7 @@ export function createDevCloudCommand(deps) {
240
264
  body: form,
241
265
  headers: {
242
266
  "X-Deploy-Local-Dir": cwd,
243
- "X-Gencow-CLI-Version": deps.cliVersion ?? "0.0.0",
267
+ ...protocolHeaders,
244
268
  },
245
269
  });
246
270
  const data = await res.json();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gencow",
3
- "version": "0.1.181",
3
+ "version": "0.1.182",
4
4
  "description": "Gencow — AI Backend Engine",
5
5
  "type": "module",
6
6
  "bin": {
@@ -33,8 +33,8 @@
33
33
  "@types/node": "^25.9.5",
34
34
  "better-auth": "^1.6.23",
35
35
  "@gencow/client": "0.2.6",
36
- "@gencow/react": "0.2.6",
37
- "@gencow/core": "0.1.42"
36
+ "@gencow/core": "0.1.42",
37
+ "@gencow/react": "0.2.6"
38
38
  },
39
39
  "scripts": {
40
40
  "prebuild": "pnpm --filter @gencow/migration-contract run build && pnpm --filter @gencow/server run build",