@replayio-app-building/netlify-recorder 0.56.0 → 0.57.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.
- package/dist/index.js +3 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -984,7 +984,7 @@ async function finishRequest(requestContext, callbacks, response, options) {
|
|
|
984
984
|
body: typeof response.body === "string" ? response.body : void 0
|
|
985
985
|
},
|
|
986
986
|
originalRequestId: options?.originalRequestId,
|
|
987
|
-
packageVersion: "0.
|
|
987
|
+
packageVersion: "0.57.0"
|
|
988
988
|
};
|
|
989
989
|
const blobData = redactBlobData(rawBlobData);
|
|
990
990
|
const blobContent = JSON.stringify(blobData);
|
|
@@ -1549,7 +1549,6 @@ async function createRequestRecording(blobUrlOrData, handlerPath, requestInfo, p
|
|
|
1549
1549
|
|
|
1550
1550
|
// src/backendRequests.ts
|
|
1551
1551
|
import { gzipSync } from "zlib";
|
|
1552
|
-
import { createHash } from "crypto";
|
|
1553
1552
|
import { UTApi } from "uploadthing/server";
|
|
1554
1553
|
async function backendRequestsEnsureTable(sql) {
|
|
1555
1554
|
await sql`
|
|
@@ -1681,9 +1680,9 @@ async function uploadBlobData(blobData, requestId) {
|
|
|
1681
1680
|
const file = Object.assign(blob, { name: `blob-${requestId}.json.gz` });
|
|
1682
1681
|
const result = await utapi.uploadFiles(file);
|
|
1683
1682
|
if (result.error || !result.data?.ufsUrl) {
|
|
1684
|
-
const
|
|
1683
|
+
const preview = token.length > 8 ? `${token.slice(0, 4)}\u2026${token.slice(-4)}` : "(short)";
|
|
1685
1684
|
console.error(
|
|
1686
|
-
`netlify-recorder: uploadBlobData failed for request ${requestId} (token length=${token.length}
|
|
1685
|
+
`netlify-recorder: uploadBlobData failed for request ${requestId} (token: ${preview}, length=${token.length}): ${JSON.stringify(result.error ?? "no URL returned")}`
|
|
1687
1686
|
);
|
|
1688
1687
|
throw new Error(
|
|
1689
1688
|
`Failed to upload blob data for request ${requestId}: ${JSON.stringify(result.error ?? "no URL returned")}`
|