From 4ea54aa147faf29731a47b1bded9493689be3121 Mon Sep 17 00:00:00 2001 From: Seth Battis Date: Fri, 3 Jan 2025 14:20:16 -0500 Subject: [PATCH] chore(msar): Issue tracking --- packages/msar/src/bin/commands/download.ts | 6 ++++++ .../src/workflows/Download/Downloader/AuthenticatedFetch.ts | 1 + 2 files changed, 7 insertions(+) diff --git a/packages/msar/src/bin/commands/download.ts b/packages/msar/src/bin/commands/download.ts index c6e6a7b..abf4c23 100644 --- a/packages/msar/src/bin/commands/download.ts +++ b/packages/msar/src/bin/commands/download.ts @@ -32,6 +32,11 @@ import * as Snapshot from '../../workflows/Snapshot.js'; const snapshotPath = path.resolve(process.cwd(), snapshotPathArg!); + /* + * TODO abstract as much of bin/download into workflow/Download as possible + * The basic design is that the bin scripts are just UI wrappers around + * real objects, not _part_ of the objects + */ if (!outputPath) { outputPath = path.join( path.dirname(snapshotPath!), @@ -113,6 +118,7 @@ import * as Snapshot from '../../workflows/Snapshot.js'; 'index.json' ); await common.output.writeJSON(indexPath, index, { pretty }); + // TODO output metadata.json of CLI arguments for downloads too if (quit) { await spider.quit(); diff --git a/packages/msar/src/workflows/Download/Downloader/AuthenticatedFetch.ts b/packages/msar/src/workflows/Download/Downloader/AuthenticatedFetch.ts index f9cfb6c..68e04ab 100644 --- a/packages/msar/src/workflows/Download/Downloader/AuthenticatedFetch.ts +++ b/packages/msar/src/workflows/Download/Downloader/AuthenticatedFetch.ts @@ -39,6 +39,7 @@ export class Downloader outputOptions: { outputPath }, ...options }: Options) { + // FIXME AuthenticatedFetch is instantiating headless super(`https://${host}`, options); if (!outputPath) { throw new common.output.OutputError(