@indigoai-us/hq-cloud 5.46.0 → 5.47.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/dist/bin/sync-runner.d.ts +12 -0
- package/dist/bin/sync-runner.d.ts.map +1 -1
- package/dist/bin/sync-runner.js +39 -0
- package/dist/bin/sync-runner.js.map +1 -1
- package/dist/bin/sync-runner.test.js +27 -1
- package/dist/bin/sync-runner.test.js.map +1 -1
- package/dist/cli/share.d.ts.map +1 -1
- package/dist/cli/share.js +17 -2
- package/dist/cli/share.js.map +1 -1
- package/dist/cli/share.test.js +2 -0
- package/dist/cli/share.test.js.map +1 -1
- package/dist/cli/sync-scope.test.js +1 -0
- package/dist/cli/sync-scope.test.js.map +1 -1
- package/dist/cli/sync.d.ts.map +1 -1
- package/dist/cli/sync.js +11 -1
- package/dist/cli/sync.js.map +1 -1
- package/dist/cli/sync.test.js +1 -0
- package/dist/cli/sync.test.js.map +1 -1
- package/dist/object-io.d.ts +218 -0
- package/dist/object-io.d.ts.map +1 -0
- package/dist/object-io.js +588 -0
- package/dist/object-io.js.map +1 -0
- package/dist/object-io.test.d.ts +11 -0
- package/dist/object-io.test.d.ts.map +1 -0
- package/dist/object-io.test.js +568 -0
- package/dist/object-io.test.js.map +1 -0
- package/dist/s3.d.ts +37 -0
- package/dist/s3.d.ts.map +1 -1
- package/dist/s3.js +225 -201
- package/dist/s3.js.map +1 -1
- package/dist/s3.test.js +21 -0
- package/dist/s3.test.js.map +1 -1
- package/dist/vault-client.d.ts +68 -0
- package/dist/vault-client.d.ts.map +1 -1
- package/dist/vault-client.js +35 -0
- package/dist/vault-client.js.map +1 -1
- package/package.json +1 -1
- package/scripts/presign-transport-e2e.mjs +203 -0
- package/scripts/vault-rebaseline.sh +275 -0
- package/scripts/vault-rescue.sh +8 -0
- package/src/bin/sync-runner.test.ts +41 -0
- package/src/bin/sync-runner.ts +52 -0
- package/src/cli/share.test.ts +2 -0
- package/src/cli/share.ts +29 -2
- package/src/cli/sync-scope.test.ts +1 -0
- package/src/cli/sync.test.ts +1 -0
- package/src/cli/sync.ts +22 -1
- package/src/object-io.test.ts +663 -0
- package/src/object-io.ts +782 -0
- package/src/s3.test.ts +24 -0
- package/src/s3.ts +277 -237
- package/src/vault-client.ts +101 -0
package/src/s3.test.ts
CHANGED
|
@@ -682,6 +682,30 @@ describe("downloadFile", () => {
|
|
|
682
682
|
expect(fs.readFileSync(localPath, "utf-8")).toBe("hi");
|
|
683
683
|
});
|
|
684
684
|
|
|
685
|
+
it("recovers a symlink from the body prefix when the metadata marker is lost (header-loss fallback)", async () => {
|
|
686
|
+
// Regression: a transport/replication/console-copy that drops user
|
|
687
|
+
// metadata — or a poisoned regular-file re-upload of a sentinel —
|
|
688
|
+
// leaves an object with NO hq-symlink-target marker but a body of
|
|
689
|
+
// `hq-symlink:<target>`. The read path must honor the body prefix as
|
|
690
|
+
// a fallback discriminator and rematerialize a real link, NOT write
|
|
691
|
+
// out the `hq-symlink:` text as a regular file (which poisons the key
|
|
692
|
+
// on the next push). See s3.ts downloadFile + SYMLINK_BODY_PREFIX doc.
|
|
693
|
+
const target = "../../../some/real/target.md";
|
|
694
|
+
nextGetObjectResponse = {
|
|
695
|
+
Body: (async function* () {
|
|
696
|
+
yield new TextEncoder().encode(SYMLINK_BODY_PREFIX + target);
|
|
697
|
+
})(),
|
|
698
|
+
Metadata: {}, // marker stripped / never set
|
|
699
|
+
};
|
|
700
|
+
|
|
701
|
+
const localPath = path.join(tmpRoot, "marker-lost-link.md");
|
|
702
|
+
await downloadFile(makeCtx(), "marker-lost-link.md", localPath);
|
|
703
|
+
|
|
704
|
+
const lstat = fs.lstatSync(localPath);
|
|
705
|
+
expect(lstat.isSymbolicLink()).toBe(true);
|
|
706
|
+
expect(fs.readlinkSync(localPath)).toBe(target);
|
|
707
|
+
});
|
|
708
|
+
|
|
685
709
|
it("replaces a stale local symlink with a regular file when remote transitions symlink → regular", async () => {
|
|
686
710
|
// Codex P2 follow-up: pre-fix, the regular-file branch went
|
|
687
711
|
// straight to writeFileSync. If localPath was a stale symlink from
|