@valbuild/server 0.154.3 → 0.155.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.
Files changed (46) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/browser/dist/valbuild-server-browser.cjs.dev.js +4 -4
  3. package/browser/dist/valbuild-server-browser.cjs.prod.js +4 -4
  4. package/browser/dist/valbuild-server-browser.esm.js +4 -4
  5. package/dist/{ValOpsMemory-972616ae.esm.js → ValOpsMemory-1a0bc2dc.esm.js} +33 -14
  6. package/dist/{ValOpsMemory-45ba05ad.cjs.dev.js → ValOpsMemory-6e829758.cjs.dev.js} +32 -12
  7. package/dist/{ValOpsMemory-18337353.cjs.prod.js → ValOpsMemory-f000531b.cjs.prod.js} +32 -12
  8. package/dist/{ValPatchStore-df8cdbe7.cjs.dev.js → ValPatchStore-457b166f.cjs.prod.js} +37 -59
  9. package/dist/{ValPatchStore-e23070df.esm.js → ValPatchStore-9ccc09e7.esm.js} +38 -60
  10. package/dist/{ValPatchStore-2f92eced.cjs.prod.js → ValPatchStore-b53db740.cjs.dev.js} +37 -59
  11. package/dist/{ValRouterCore-86757d56.cjs.dev.js → ValRouterCore-65bb6323.cjs.prod.js} +11 -2
  12. package/dist/{ValRouterCore-5b747abb.cjs.prod.js → ValRouterCore-adb69698.cjs.dev.js} +11 -2
  13. package/dist/{ValRouterCore-73eb843d.esm.js → ValRouterCore-f7d6394e.esm.js} +11 -2
  14. package/dist/{createPrettierFormatter-851fcf99.cjs.dev.js → createPrettierFormatter-5d830bdf.cjs.dev.js} +6 -14
  15. package/dist/{createPrettierFormatter-05ad7480.cjs.prod.js → createPrettierFormatter-b31bfbe5.cjs.prod.js} +6 -14
  16. package/dist/{createPrettierFormatter-1edca494.esm.js → createPrettierFormatter-ce478de1.esm.js} +7 -15
  17. package/dist/{createValRuntime-5cebf459.cjs.dev.js → createValRuntime-1c7d891e.cjs.dev.js} +5 -5
  18. package/dist/{createValRuntime-472df6e8.cjs.prod.js → createValRuntime-a519939b.cjs.prod.js} +5 -5
  19. package/dist/{createValRuntime-c77ee010.esm.js → createValRuntime-f55300a0.esm.js} +5 -5
  20. package/dist/declarations/src/draftReads.d.ts +5 -0
  21. package/dist/declarations/src/head.d.ts +7 -7
  22. package/dist/{draftReads-3f7dcda5.cjs.prod.js → draftReads-1f256502.cjs.dev.js} +5 -0
  23. package/dist/{draftReads-a300a02f.cjs.dev.js → draftReads-27351e97.cjs.prod.js} +5 -0
  24. package/dist/{draftReads-bca0d49c.esm.js → draftReads-7f0f0eb3.esm.js} +5 -0
  25. package/dist/{inTabFetch-c2efa1bd.cjs.prod.js → inTabFetch-3d8ceb84.cjs.prod.js} +2 -2
  26. package/dist/{inTabFetch-db6d6425.cjs.dev.js → inTabFetch-75753a09.cjs.dev.js} +2 -2
  27. package/dist/{inTabFetch-0c997998.esm.js → inTabFetch-dae5dd87.esm.js} +2 -2
  28. package/dist/{proposalJsonEntries-0669f027.esm.js → proposalJsonEntries-2cd6f6fe.esm.js} +1 -1
  29. package/dist/{proposalJsonEntries-26f397bd.cjs.dev.js → proposalJsonEntries-d21900d4.cjs.dev.js} +1 -1
  30. package/dist/{proposalJsonEntries-9e537244.cjs.prod.js → proposalJsonEntries-d4623810.cjs.prod.js} +1 -1
  31. package/dist/{publishKit-ac0af189.esm.js → publishKit-04b6d255.esm.js} +7 -7
  32. package/dist/{publishKit-7aca03bb.cjs.prod.js → publishKit-395b92e5.cjs.prod.js} +5 -5
  33. package/dist/{publishKit-38d46a51.cjs.dev.js → publishKit-de4baed6.cjs.dev.js} +5 -5
  34. package/dist/{valRuntime-e4d26702.esm.js → valRuntime-7fd12e16.esm.js} +42 -24
  35. package/dist/{valRuntime-70ee2dc2.cjs.dev.js → valRuntime-d3cc6e0d.cjs.dev.js} +41 -23
  36. package/dist/{valRuntime-2a3cc887.cjs.prod.js → valRuntime-e922e372.cjs.prod.js} +41 -23
  37. package/dist/valbuild-server.cjs.dev.js +6 -6
  38. package/dist/valbuild-server.cjs.prod.js +6 -6
  39. package/dist/valbuild-server.esm.js +9 -9
  40. package/internal/browser/dist/valbuild-server-internal-browser.cjs.dev.js +5 -5
  41. package/internal/browser/dist/valbuild-server-internal-browser.cjs.prod.js +5 -5
  42. package/internal/browser/dist/valbuild-server-internal-browser.esm.js +5 -5
  43. package/internal/dist/valbuild-server-internal.cjs.dev.js +4 -4
  44. package/internal/dist/valbuild-server-internal.cjs.prod.js +4 -4
  45. package/internal/dist/valbuild-server-internal.esm.js +4 -4
  46. package/package.json +4 -4
@@ -1,20 +1,20 @@
1
1
  'use strict';
2
2
 
3
3
  var core = require('@valbuild/core');
4
- var ValOpsMemory = require('./ValOpsMemory-18337353.cjs.prod.js');
4
+ var ValOpsMemory = require('./ValOpsMemory-f000531b.cjs.prod.js');
5
5
  var path = require('path');
6
6
  var ts = require('typescript');
7
7
  var z = require('zod');
8
8
  var fs = require('fs');
9
9
  var zodValidationError = require('zod-validation-error');
10
10
  var fp = require('@valbuild/core/fp');
11
- var proposalJsonEntries = require('./proposalJsonEntries-9e537244.cjs.prod.js');
11
+ var proposalJsonEntries = require('./proposalJsonEntries-d4623810.cjs.prod.js');
12
12
  var jsonValuesPatch = require('./jsonValuesPatch-92798812.cjs.prod.js');
13
13
  var internal = require('@valbuild/shared/internal');
14
14
  var os = require('os');
15
15
  var crypto$1 = require('crypto');
16
16
  var buffer = require('buffer');
17
- var createPrettierFormatter = require('./createPrettierFormatter-05ad7480.cjs.prod.js');
17
+ var createPrettierFormatter = require('./createPrettierFormatter-b31bfbe5.cjs.prod.js');
18
18
  var patch = require('@valbuild/core/patch');
19
19
  require('node:vm');
20
20
  require('node:module');
@@ -1889,7 +1889,7 @@ function createFsSketchpadStore(rootDir, now = () => new Date()) {
1889
1889
  * as a bundler does.
1890
1890
  */
1891
1891
  function loadTypeScriptKit() {
1892
- return Promise.resolve().then(function () { return require('./publishKit-7aca03bb.cjs.prod.js'); });
1892
+ return Promise.resolve().then(function () { return require('./publishKit-395b92e5.cjs.prod.js'); });
1893
1893
  }
1894
1894
 
1895
1895
  /** Serializes a schema, or gives up quietly — serialization errors are reported elsewhere. */
@@ -4192,7 +4192,7 @@ async function stagedModuleSources(files) {
4192
4192
  parseValFile,
4193
4193
  analyzeValModule,
4194
4194
  evaluateModuleSource
4195
- } = await Promise.resolve().then(function () { return require('./publishKit-7aca03bb.cjs.prod.js'); });
4195
+ } = await Promise.resolve().then(function () { return require('./publishKit-395b92e5.cjs.prod.js'); });
4196
4196
  const sources = {};
4197
4197
  for (const {
4198
4198
  path,
@@ -5148,7 +5148,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5148
5148
  branch
5149
5149
  })}` : "";
5150
5150
  try {
5151
- const res = await fetch(`${this.contentUrl}/v1/${this.project}/chain/version${query}`, {
5151
+ const res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/chain/version${query}`, {
5152
5152
  headers: this.authHeaders
5153
5153
  });
5154
5154
  if (res.status === 404) {
@@ -5309,7 +5309,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5309
5309
  * rather than letting the tab talk to content.
5310
5310
  */
5311
5311
  async mintPublishToken() {
5312
- const res = await fetch(`${this.contentUrl}/v1/${this.project}/publish-token`, {
5312
+ const res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/publish-token`, {
5313
5313
  method: "POST",
5314
5314
  headers: this.authHeaders
5315
5315
  });
@@ -5593,7 +5593,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5593
5593
  }
5594
5594
  // Staged module files go with the Source they declare.
5595
5595
  const body = (writes === null || writes === void 0 ? void 0 : writes.write) === "files" && init.body !== undefined ? await withStagedModuleSources(init.body) : init.body;
5596
- const res = await fetch(`${this.contentUrl}/v1/${this.project}/proposals${path}`, {
5596
+ const res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/proposals${path}`, {
5597
5597
  method: init.method,
5598
5598
  headers: {
5599
5599
  ...this.authHeaders,
@@ -5660,7 +5660,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5660
5660
  message: `Invalid update: ${zodValidationError.fromError(request.error).toString()}`
5661
5661
  });
5662
5662
  }
5663
- const content = (path, init = {}) => fetch(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5663
+ const content = (path, init = {}) => ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5664
5664
  ...init,
5665
5665
  headers: {
5666
5666
  ...this.authHeaders,
@@ -5777,7 +5777,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5777
5777
 
5778
5778
  /** Content's proposals API for one proposal, as the person asking. */
5779
5779
  proposalContent(name, profileId) {
5780
- return (path, init = {}) => fetch(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5780
+ return (path, init = {}) => ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5781
5781
  ...init,
5782
5782
  headers: {
5783
5783
  ...this.authHeaders,
@@ -5937,7 +5937,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
5937
5937
  message: `Invalid update: ${zodValidationError.fromError(request.error).toString()}`
5938
5938
  });
5939
5939
  }
5940
- const content = (path, init = {}) => fetch(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5940
+ const content = (path, init = {}) => ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/proposals/${name}${path}`, {
5941
5941
  ...init,
5942
5942
  headers: {
5943
5943
  ...this.authHeaders,
@@ -6047,7 +6047,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6047
6047
  }
6048
6048
  async callPublishApi(path, init) {
6049
6049
  const json = "application/json";
6050
- const send = async token => fetch(`${this.contentUrl}/v1${path}`, {
6050
+ const send = async token => ValOpsMemory.fetchFresh(`${this.contentUrl}/v1${path}`, {
6051
6051
  method: init.method,
6052
6052
  headers: {
6053
6053
  ...ValOpsMemory.VAL_CLIENT_HEADERS,
@@ -6114,7 +6114,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6114
6114
  async getPresignedAuthNonce(profileId, corsOrigin) {
6115
6115
  try {
6116
6116
  var _res$headers$get2;
6117
- const res = await fetch(`${this.contentUrl}/v1/${this.project}/presigned-auth-nonce`, {
6117
+ const res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/presigned-auth-nonce`, {
6118
6118
  method: "POST",
6119
6119
  headers: {
6120
6120
  ...this.authHeaders,
@@ -6441,7 +6441,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6441
6441
  * `applicable/patches`), so its `patches` messages and that stat agree.
6442
6442
  */
6443
6443
  relativeTo) {
6444
- return fetch(`${this.contentUrl}/v1/${this.project}/websocket/nonces`, {
6444
+ return ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/websocket/nonces`, {
6445
6445
  method: "POST",
6446
6446
  body: JSON.stringify({
6447
6447
  profileId,
@@ -6691,7 +6691,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6691
6691
  }
6692
6692
  const searchParams = new URLSearchParams(params);
6693
6693
  try {
6694
- const patchesRes = await fetch(`${this.contentUrl}/v1/${this.project}/applicable/patches${searchParams.size > 0 ? `?${searchParams.toString()}` : ""}`, {
6694
+ const patchesRes = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/applicable/patches${searchParams.size > 0 ? `?${searchParams.toString()}` : ""}`, {
6695
6695
  headers: this.authHeaders
6696
6696
  });
6697
6697
  const patches = [];
@@ -6825,6 +6825,24 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6825
6825
  }
6826
6826
  };
6827
6827
  } catch (err) {
6828
+ if (internal.isCrossRequestError(err)) {
6829
+ /*
6830
+ * Not the network: workerd refused, at once, a promise or I/O object
6831
+ * of another request, so nothing was asked of the content service.
6832
+ * `fetchFresh` already tried once more. A server failure, then --
6833
+ * never `networkError`, which `/stat` answers as a 503 saying the
6834
+ * service could not be reached.
6835
+ */
6836
+ const details = err instanceof Error ? err.message : String(err);
6837
+ core.Internal.log.error(`Could not get patches. ${details}`);
6838
+ return {
6839
+ patches: [],
6840
+ error: {
6841
+ message: "Val's server could not load your changes, because of an error in Val itself. Trying again usually works.",
6842
+ details
6843
+ }
6844
+ };
6845
+ }
6828
6846
  const failure = contentServiceUnreachable(contentServiceName(this.contentUrl), "load your changes", err);
6829
6847
  core.Internal.log.error(`Could not get patches. ${failure.message} ${failure.details}`);
6830
6848
  return {
@@ -6839,7 +6857,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6839
6857
  }
6840
6858
  async saveSourceFilePatch(path, patch, patchId, parentRef, authorId, sessionId) {
6841
6859
  const baseSha = await this.getBaseSha();
6842
- return fetch(`${this.contentUrl}/v1/${this.project}/patches`, {
6860
+ return ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/patches`, {
6843
6861
  method: "POST",
6844
6862
  headers: {
6845
6863
  ...this.authHeaders,
@@ -6949,7 +6967,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
6949
6967
  */
6950
6968
  async saveBase64EncodedBinaryFileFromPatch(filePathOrRef, parentRef, patchId, data, type, metadata) {
6951
6969
  const filePath = filePathOrRef;
6952
- return fetch(`${this.contentUrl}/v1/${this.project}/patches/${patchId}/files`, {
6970
+ return ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/patches/${patchId}/files`, {
6953
6971
  method: "POST",
6954
6972
  headers: {
6955
6973
  ...this.authHeaders,
@@ -7004,7 +7022,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7004
7022
  params.set("body_sha",
7005
7023
  // We use this for cache invalidation
7006
7024
  core.Internal.getSHA256Hash(textEncoder.encode(stringifiedFiles)));
7007
- return fetch(`${this.contentUrl}/v1/${this.project}/files?${params}`, {
7025
+ return ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/files?${params}`, {
7008
7026
  method: "PUT",
7009
7027
  // Yes, PUT is weird. Weirder to have a body in a GET request.
7010
7028
  headers: {
@@ -7161,7 +7179,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7161
7179
  params.set("file_path", filePath);
7162
7180
  params.set("remote", remote.toString());
7163
7181
  try {
7164
- const metadataRes = await fetch(`${this.contentUrl}/v1/${this.project}/patches/${patchId}/files?${params}`, {
7182
+ const metadataRes = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/patches/${patchId}/files?${params}`, {
7165
7183
  headers: {
7166
7184
  ...this.authHeaders,
7167
7185
  "Content-Type": "application/json"
@@ -7219,7 +7237,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7219
7237
  };
7220
7238
  }
7221
7239
  async deletePatches(patchIds) {
7222
- return fetch(`${this.contentUrl}/v1/${this.project}/patches`, {
7240
+ return ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/patches`, {
7223
7241
  method: "DELETE",
7224
7242
  headers: {
7225
7243
  ...this.authHeaders,
@@ -7291,7 +7309,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7291
7309
  */
7292
7310
  const proposalName = intoProposal ?? ((_this$proposal4 = this.proposal) === null || _this$proposal4 === void 0 ? void 0 : _this$proposal4.name);
7293
7311
  const commitUrl = proposalName !== undefined ? `${this.contentUrl}/v1/${this.project}/proposals/${proposalName}/save` : `${this.contentUrl}/v1/${this.project}/commit`;
7294
- const res = await fetch(commitUrl, {
7312
+ const res = await ValOpsMemory.fetchFresh(commitUrl, {
7295
7313
  method: "POST",
7296
7314
  headers: {
7297
7315
  ...this.authHeaders,
@@ -7427,7 +7445,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7427
7445
  async getHistory(path, schema, commitShaForErrors) {
7428
7446
  let res;
7429
7447
  try {
7430
- res = await fetch(`${this.contentUrl}/v1/${this.project}${path}`, {
7448
+ res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}${path}`, {
7431
7449
  headers: {
7432
7450
  ...this.authHeaders,
7433
7451
  "Content-Type": "application/json"
@@ -7578,7 +7596,7 @@ class ValOpsHttp extends ValOpsMemory.ValOps {
7578
7596
  }
7579
7597
  let res;
7580
7598
  try {
7581
- res = await fetch(`${this.contentUrl}/v1/${this.project}/commits/${commitSha}/file?${params}`, {
7599
+ res = await ValOpsMemory.fetchFresh(`${this.contentUrl}/v1/${this.project}/commits/${commitSha}/file?${params}`, {
7582
7600
  headers: {
7583
7601
  ...this.authHeaders
7584
7602
  }
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var proposalJsonEntries = require('./proposalJsonEntries-26f397bd.cjs.dev.js');
5
+ var proposalJsonEntries = require('./proposalJsonEntries-d21900d4.cjs.dev.js');
6
6
  var patch = require('@valbuild/core/patch');
7
- var valRuntime = require('./valRuntime-70ee2dc2.cjs.dev.js');
7
+ var valRuntime = require('./valRuntime-d3cc6e0d.cjs.dev.js');
8
8
  var fp = require('@valbuild/core/fp');
9
9
  var core = require('@valbuild/core');
10
10
  var ts = require('typescript');
@@ -13,7 +13,7 @@ var fs = require('fs');
13
13
  var vm = require('node:vm');
14
14
  var node_module = require('node:module');
15
15
  var jsonValuesPatch = require('./jsonValuesPatch-88bc661d.cjs.dev.js');
16
- var ValOpsMemory = require('./ValOpsMemory-45ba05ad.cjs.dev.js');
16
+ var ValOpsMemory = require('./ValOpsMemory-6e829758.cjs.dev.js');
17
17
  var internal = require('@valbuild/shared/internal');
18
18
  var server = require('@valbuild/ui/server');
19
19
  var http = require('node:http');
@@ -22,13 +22,13 @@ var net = require('node:net');
22
22
  var sizeOf = require('image-size');
23
23
  var http$1 = require('http');
24
24
  var https$1 = require('https');
25
- var ValRouterCore = require('./ValRouterCore-86757d56.cjs.dev.js');
26
- var createPrettierFormatter = require('./createPrettierFormatter-851fcf99.cjs.dev.js');
25
+ var ValRouterCore = require('./ValRouterCore-adb69698.cjs.dev.js');
26
+ var createPrettierFormatter = require('./createPrettierFormatter-5d830bdf.cjs.dev.js');
27
27
  var sucrase = require('sucrase');
28
28
  var fs$1 = require('fs/promises');
29
29
  var z = require('zod');
30
30
  var os = require('os');
31
- var ValPatchStore = require('./ValPatchStore-df8cdbe7.cjs.dev.js');
31
+ var ValPatchStore = require('./ValPatchStore-b53db740.cjs.dev.js');
32
32
  require('zod-validation-error');
33
33
  require('crypto');
34
34
  require('buffer');
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var proposalJsonEntries = require('./proposalJsonEntries-9e537244.cjs.prod.js');
5
+ var proposalJsonEntries = require('./proposalJsonEntries-d4623810.cjs.prod.js');
6
6
  var patch = require('@valbuild/core/patch');
7
- var valRuntime = require('./valRuntime-2a3cc887.cjs.prod.js');
7
+ var valRuntime = require('./valRuntime-e922e372.cjs.prod.js');
8
8
  var fp = require('@valbuild/core/fp');
9
9
  var core = require('@valbuild/core');
10
10
  var ts = require('typescript');
@@ -13,7 +13,7 @@ var fs = require('fs');
13
13
  var vm = require('node:vm');
14
14
  var node_module = require('node:module');
15
15
  var jsonValuesPatch = require('./jsonValuesPatch-92798812.cjs.prod.js');
16
- var ValOpsMemory = require('./ValOpsMemory-18337353.cjs.prod.js');
16
+ var ValOpsMemory = require('./ValOpsMemory-f000531b.cjs.prod.js');
17
17
  var internal = require('@valbuild/shared/internal');
18
18
  var server = require('@valbuild/ui/server');
19
19
  var http = require('node:http');
@@ -22,13 +22,13 @@ var net = require('node:net');
22
22
  var sizeOf = require('image-size');
23
23
  var http$1 = require('http');
24
24
  var https$1 = require('https');
25
- var ValRouterCore = require('./ValRouterCore-5b747abb.cjs.prod.js');
26
- var createPrettierFormatter = require('./createPrettierFormatter-05ad7480.cjs.prod.js');
25
+ var ValRouterCore = require('./ValRouterCore-65bb6323.cjs.prod.js');
26
+ var createPrettierFormatter = require('./createPrettierFormatter-b31bfbe5.cjs.prod.js');
27
27
  var sucrase = require('sucrase');
28
28
  var fs$1 = require('fs/promises');
29
29
  var z = require('zod');
30
30
  var os = require('os');
31
- var ValPatchStore = require('./ValPatchStore-2f92eced.cjs.prod.js');
31
+ var ValPatchStore = require('./ValPatchStore-457b166f.cjs.prod.js');
32
32
  require('zod-validation-error');
33
33
  require('crypto');
34
34
  require('buffer');
@@ -1,8 +1,8 @@
1
- import { a as analyzeValModule, f as flatMapErrors, b as formatSyntaxError, c as analyzeJsonValuesEntries } from './proposalJsonEntries-0669f027.esm.js';
2
- export { a as analyzeValModule, d as formatSyntaxErrorTree, p as proposalSnapshotForReaders } from './proposalJsonEntries-0669f027.esm.js';
1
+ import { a as analyzeValModule, f as flatMapErrors, b as formatSyntaxError, c as analyzeJsonValuesEntries } from './proposalJsonEntries-2cd6f6fe.esm.js';
2
+ export { a as analyzeValModule, d as formatSyntaxErrorTree, p as proposalSnapshotForReaders } from './proposalJsonEntries-2cd6f6fe.esm.js';
3
3
  import { applyPatch, PatchError, JSONOps, deepClone, sourceToPatchPath, isNotRoot } from '@valbuild/core/patch';
4
- import { T as TSOps, g as getPersonalAccessTokenPath, p as parsePersonalAccessTokenFile, v as valRuntime, a as verifyJwt, d as decodeJwtWithoutVerifying, e as encodeJwt, b as getExpire, r as readValLoginToken, c as resolveRemoteFileAuth, l as loadTypeScriptKit, i as initHandlerOptions, f as removeValJsonEntry, h as insertValJsonEntry, V as ValOpsFS } from './valRuntime-e4d26702.esm.js';
5
- export { A as APP_MODE_REQUIRES_REMOTE_FILES, V as ValOpsFS, k as ValOpsHttp, j as createValOps, d as decodeJwtWithoutVerifying, n as describePatchStoreProblems, e as encodeJwt, b as getExpire, g as getPersonalAccessTokenPath, i as initHandlerOptions, l as loadTypeScriptKit, p as parsePersonalAccessTokenFile, m as readPatchStore, c as resolveRemoteFileAuth, v as valRuntime, a as verifyJwt } from './valRuntime-e4d26702.esm.js';
4
+ import { T as TSOps, g as getPersonalAccessTokenPath, p as parsePersonalAccessTokenFile, v as valRuntime, a as verifyJwt, d as decodeJwtWithoutVerifying, e as encodeJwt, b as getExpire, r as readValLoginToken, c as resolveRemoteFileAuth, l as loadTypeScriptKit, i as initHandlerOptions, f as removeValJsonEntry, h as insertValJsonEntry, V as ValOpsFS } from './valRuntime-7fd12e16.esm.js';
5
+ export { A as APP_MODE_REQUIRES_REMOTE_FILES, V as ValOpsFS, k as ValOpsHttp, j as createValOps, d as decodeJwtWithoutVerifying, n as describePatchStoreProblems, e as encodeJwt, b as getExpire, g as getPersonalAccessTokenPath, i as initHandlerOptions, l as loadTypeScriptKit, p as parsePersonalAccessTokenFile, m as readPatchStore, c as resolveRemoteFileAuth, v as valRuntime, a as verifyJwt } from './valRuntime-7fd12e16.esm.js';
6
6
  import { pipe, result } from '@valbuild/core/fp';
7
7
  import { derefPatch, Internal, extractValModules, DEFAULT_VAL_REMOTE_HOST, DEFAULT_CONTENT_HOST } from '@valbuild/core';
8
8
  export { hasRemoteFileSchema } from '@valbuild/core';
@@ -12,8 +12,8 @@ import fs from 'fs';
12
12
  import vm from 'node:vm';
13
13
  import { Module } from 'node:module';
14
14
  import { r as resolveExistingJsonPath, f as findNestedJsonValuesRecords, g as getNewJsonEntryPaths } from './jsonValuesPatch-13acc674.esm.js';
15
- import { v as validateJsonValuesEntries, i as isHlsMasterPlaylist, s as sumHlsSegmentDurations, p as parseHlsMasterVariants, l as largestHlsVariant, g as getFileExt, f as fallbackRefOf, m as mapHlsUris, a as movedRemoteHost, n as needsHostCheck, r as rewriteRefHost, b as fallbackRemoteHost, c as checkRemoteFiles, d as getFieldsForType, V as ValServer, e as formatPatchSourceError, h as VAL_CLIENT_HEADERS } from './ValOpsMemory-972616ae.esm.js';
16
- export { o as ValOpsMemory, j as askOncePerHost, e as formatPatchSourceError, g as getFileExt, k as getSettings, u as uploadRemoteFile } from './ValOpsMemory-972616ae.esm.js';
15
+ import { v as validateJsonValuesEntries, i as isHlsMasterPlaylist, s as sumHlsSegmentDurations, p as parseHlsMasterVariants, l as largestHlsVariant, g as getFileExt, f as fallbackRefOf, m as mapHlsUris, a as movedRemoteHost, n as needsHostCheck, r as rewriteRefHost, b as fallbackRemoteHost, c as checkRemoteFiles, d as getFieldsForType, V as ValServer, e as formatPatchSourceError, h as VAL_CLIENT_HEADERS } from './ValOpsMemory-1a0bc2dc.esm.js';
16
+ export { o as ValOpsMemory, j as askOncePerHost, e as formatPatchSourceError, g as getFileExt, k as getSettings, u as uploadRemoteFile } from './ValOpsMemory-1a0bc2dc.esm.js';
17
17
  import { isJsonValuesRootOp, rebaseContentOp, classifyJsonValuesOp, LOCAL_FILE_IN_REMOTE_PROJECT_WARNING, LOCAL_FILE_IN_REMOTE_PROJECT_HINT, traverseSchemaSource, richTextImageSchema, forEachRichTextImage, isStudioFix } from '@valbuild/shared/internal';
18
18
  export { classifyJsonValuesOp, rebaseContentOp } from '@valbuild/shared/internal';
19
19
  import { createUIRequestHandler } from '@valbuild/ui/server';
@@ -23,13 +23,13 @@ import net from 'node:net';
23
23
  import sizeOf from 'image-size';
24
24
  import http$1 from 'http';
25
25
  import https$1 from 'https';
26
- import { s as setRequestGuard, p as parseAllowedHosts, c as createValRequestHandler } from './ValRouterCore-73eb843d.esm.js';
27
- export { c as contentFromEnv, b as createPrettierFormatter, l as layeredSnapshot, p as proposalFromEnv, a as proposalSnapshot } from './createPrettierFormatter-1edca494.esm.js';
26
+ import { s as setRequestGuard, p as parseAllowedHosts, c as createValRequestHandler } from './ValRouterCore-f7d6394e.esm.js';
27
+ export { c as contentFromEnv, b as createPrettierFormatter, l as layeredSnapshot, p as proposalFromEnv, a as proposalSnapshot } from './createPrettierFormatter-ce478de1.esm.js';
28
28
  import { transform } from 'sucrase';
29
29
  import fs$1 from 'fs/promises';
30
30
  import z from 'zod';
31
31
  import os from 'os';
32
- export { I as InMemoryPatchStore } from './ValPatchStore-e23070df.esm.js';
32
+ export { I as InMemoryPatchStore } from './ValPatchStore-9ccc09e7.esm.js';
33
33
  import 'zod-validation-error';
34
34
  import 'crypto';
35
35
  import 'buffer';
@@ -2,19 +2,19 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var inTabFetch = require('../../../dist/inTabFetch-db6d6425.cjs.dev.js');
6
- var draftReads = require('../../../dist/draftReads-a300a02f.cjs.dev.js');
5
+ var inTabFetch = require('../../../dist/inTabFetch-75753a09.cjs.dev.js');
6
+ var draftReads = require('../../../dist/draftReads-1f256502.cjs.dev.js');
7
7
  require('@valbuild/core');
8
- require('../../../dist/ValOpsMemory-45ba05ad.cjs.dev.js');
8
+ require('../../../dist/ValOpsMemory-6e829758.cjs.dev.js');
9
9
  require('zod');
10
10
  require('@valbuild/shared/internal');
11
11
  require('../../../dist/jsonValuesPatch-88bc661d.cjs.dev.js');
12
12
  require('@valbuild/core/fp');
13
13
  require('zod-validation-error');
14
- require('../../../dist/ValPatchStore-df8cdbe7.cjs.dev.js');
14
+ require('../../../dist/ValPatchStore-b53db740.cjs.dev.js');
15
15
  require('@valbuild/core/patch');
16
16
  require('image-size');
17
- require('../../../dist/ValRouterCore-86757d56.cjs.dev.js');
17
+ require('../../../dist/ValRouterCore-adb69698.cjs.dev.js');
18
18
 
19
19
 
20
20
 
@@ -2,19 +2,19 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var inTabFetch = require('../../../dist/inTabFetch-c2efa1bd.cjs.prod.js');
6
- var draftReads = require('../../../dist/draftReads-3f7dcda5.cjs.prod.js');
5
+ var inTabFetch = require('../../../dist/inTabFetch-3d8ceb84.cjs.prod.js');
6
+ var draftReads = require('../../../dist/draftReads-27351e97.cjs.prod.js');
7
7
  require('@valbuild/core');
8
- require('../../../dist/ValOpsMemory-18337353.cjs.prod.js');
8
+ require('../../../dist/ValOpsMemory-f000531b.cjs.prod.js');
9
9
  require('zod');
10
10
  require('@valbuild/shared/internal');
11
11
  require('../../../dist/jsonValuesPatch-92798812.cjs.prod.js');
12
12
  require('@valbuild/core/fp');
13
13
  require('zod-validation-error');
14
- require('../../../dist/ValPatchStore-2f92eced.cjs.prod.js');
14
+ require('../../../dist/ValPatchStore-457b166f.cjs.prod.js');
15
15
  require('@valbuild/core/patch');
16
16
  require('image-size');
17
- require('../../../dist/ValRouterCore-5b747abb.cjs.prod.js');
17
+ require('../../../dist/ValRouterCore-65bb6323.cjs.prod.js');
18
18
 
19
19
 
20
20
 
@@ -1,13 +1,13 @@
1
- export { a as createInTabVal } from '../../../dist/inTabFetch-0c997998.esm.js';
2
- export { s as serverDraftSource } from '../../../dist/draftReads-bca0d49c.esm.js';
1
+ export { a as createInTabVal } from '../../../dist/inTabFetch-dae5dd87.esm.js';
2
+ export { s as serverDraftSource } from '../../../dist/draftReads-7f0f0eb3.esm.js';
3
3
  import '@valbuild/core';
4
- import '../../../dist/ValOpsMemory-972616ae.esm.js';
4
+ import '../../../dist/ValOpsMemory-1a0bc2dc.esm.js';
5
5
  import 'zod';
6
6
  import '@valbuild/shared/internal';
7
7
  import '../../../dist/jsonValuesPatch-13acc674.esm.js';
8
8
  import '@valbuild/core/fp';
9
9
  import 'zod-validation-error';
10
- import '../../../dist/ValPatchStore-e23070df.esm.js';
10
+ import '../../../dist/ValPatchStore-9ccc09e7.esm.js';
11
11
  import '@valbuild/core/patch';
12
12
  import 'image-size';
13
- import '../../../dist/ValRouterCore-73eb843d.esm.js';
13
+ import '../../../dist/ValRouterCore-f7d6394e.esm.js';
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var draftReads = require('../../dist/draftReads-a300a02f.cjs.dev.js');
6
- var createPrettierFormatter = require('../../dist/createPrettierFormatter-851fcf99.cjs.dev.js');
7
- var ValPatchStore = require('../../dist/ValPatchStore-df8cdbe7.cjs.dev.js');
5
+ var draftReads = require('../../dist/draftReads-1f256502.cjs.dev.js');
6
+ var createPrettierFormatter = require('../../dist/createPrettierFormatter-5d830bdf.cjs.dev.js');
7
+ var ValPatchStore = require('../../dist/ValPatchStore-b53db740.cjs.dev.js');
8
8
  require('@valbuild/core');
9
9
  require('@valbuild/shared/internal');
10
10
  require('path');
@@ -37,7 +37,7 @@ require('path');
37
37
  async function createValRuntime(valModules, route, opts, config) {
38
38
  const {
39
39
  createValRuntime
40
- } = await Promise.resolve().then(function () { return require('../../dist/createValRuntime-5cebf459.cjs.dev.js'); });
40
+ } = await Promise.resolve().then(function () { return require('../../dist/createValRuntime-1c7d891e.cjs.dev.js'); });
41
41
  return createValRuntime(valModules, route, opts, config);
42
42
  }
43
43
 
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var draftReads = require('../../dist/draftReads-3f7dcda5.cjs.prod.js');
6
- var createPrettierFormatter = require('../../dist/createPrettierFormatter-05ad7480.cjs.prod.js');
7
- var ValPatchStore = require('../../dist/ValPatchStore-2f92eced.cjs.prod.js');
5
+ var draftReads = require('../../dist/draftReads-27351e97.cjs.prod.js');
6
+ var createPrettierFormatter = require('../../dist/createPrettierFormatter-b31bfbe5.cjs.prod.js');
7
+ var ValPatchStore = require('../../dist/ValPatchStore-457b166f.cjs.prod.js');
8
8
  require('@valbuild/core');
9
9
  require('@valbuild/shared/internal');
10
10
  require('path');
@@ -37,7 +37,7 @@ require('path');
37
37
  async function createValRuntime(valModules, route, opts, config) {
38
38
  const {
39
39
  createValRuntime
40
- } = await Promise.resolve().then(function () { return require('../../dist/createValRuntime-472df6e8.cjs.prod.js'); });
40
+ } = await Promise.resolve().then(function () { return require('../../dist/createValRuntime-a519939b.cjs.prod.js'); });
41
41
  return createValRuntime(valModules, route, opts, config);
42
42
  }
43
43
 
@@ -1,6 +1,6 @@
1
- export { d as draftForRequest, r as readDraftChanges, s as serverDraftSource } from '../../dist/draftReads-bca0d49c.esm.js';
2
- export { b as createPrettierFormatter, l as layeredSnapshot, g as proposalAsBuilt, r as readerSnapshot, h as serverCanStartLazily, e as servingBuildOf, s as stagedAfterBuild } from '../../dist/createPrettierFormatter-1edca494.esm.js';
3
- export { H as HEAD_BUDGET_BYTES, a as HEAD_VERSIONS_PER_MODULE, I as InMemoryPatchStore, V as ValHead, h as headWork } from '../../dist/ValPatchStore-e23070df.esm.js';
1
+ export { d as draftForRequest, r as readDraftChanges, s as serverDraftSource } from '../../dist/draftReads-7f0f0eb3.esm.js';
2
+ export { b as createPrettierFormatter, l as layeredSnapshot, g as proposalAsBuilt, r as readerSnapshot, h as serverCanStartLazily, e as servingBuildOf, s as stagedAfterBuild } from '../../dist/createPrettierFormatter-ce478de1.esm.js';
3
+ export { H as HEAD_BUDGET_BYTES, a as HEAD_VERSIONS_PER_MODULE, I as InMemoryPatchStore, V as ValHead, h as headWork } from '../../dist/ValPatchStore-9ccc09e7.esm.js';
4
4
  import '@valbuild/core';
5
5
  import '@valbuild/shared/internal';
6
6
  import 'path';
@@ -33,7 +33,7 @@ import 'path';
33
33
  async function createValRuntime(valModules, route, opts, config) {
34
34
  const {
35
35
  createValRuntime
36
- } = await import('../../dist/createValRuntime-c77ee010.esm.js');
36
+ } = await import('../../dist/createValRuntime-f55300a0.esm.js');
37
37
  return createValRuntime(valModules, route, opts, config);
38
38
  }
39
39
 
package/package.json CHANGED
@@ -37,7 +37,7 @@
37
37
  ],
38
38
  "exports": true
39
39
  },
40
- "version": "0.154.3",
40
+ "version": "0.155.0",
41
41
  "devDependencies": {
42
42
  "@prettier/sync": "^0.6.1",
43
43
  "@types/jest": "^30.0.0",
@@ -51,9 +51,9 @@
51
51
  "typescript": "^6.0.3",
52
52
  "zod": "^4.6.6",
53
53
  "zod-validation-error": "^5.0.0",
54
- "@valbuild/shared": "0.154.3",
55
- "@valbuild/core": "0.154.2",
56
- "@valbuild/ui": "0.154.2"
54
+ "@valbuild/core": "0.155.0",
55
+ "@valbuild/shared": "0.155.0",
56
+ "@valbuild/ui": "0.155.0"
57
57
  },
58
58
  "engines": {
59
59
  "node": "^20.19.0 || >=22"