@secondlayer/cli 23.2.0 → 23.2.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/cli.js +5 -4
- package/dist/cli.js.map +3 -3
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -2360,7 +2360,7 @@ function ignoredEnvKeyNote(ignored) {
|
|
|
2360
2360
|
return ignored ? " INSTANCE_TOKEN was ignored: it unlocks this instance, not your account." : "";
|
|
2361
2361
|
}
|
|
2362
2362
|
async function httpArchiveOps(path, opts = {}) {
|
|
2363
|
-
const { bearer, ignoredEnvKey } = await resolveArchiveOpsBearer();
|
|
2363
|
+
const { bearer, source, ignoredEnvKey } = await resolveArchiveOpsBearer();
|
|
2364
2364
|
if (!bearer) {
|
|
2365
2365
|
throw new CliHttpError(401, "SESSION_EXPIRED", { error: "Not logged in" }, `This needs your Secondlayer account. ${ARCHIVE_AUTH_HINT}${ignoredEnvKeyNote(ignoredEnvKey)}`);
|
|
2366
2366
|
}
|
|
@@ -2371,7 +2371,8 @@ async function httpArchiveOps(path, opts = {}) {
|
|
|
2371
2371
|
});
|
|
2372
2372
|
} catch (err) {
|
|
2373
2373
|
if (err instanceof CliHttpError && err.status === 401) {
|
|
2374
|
-
|
|
2374
|
+
const remedy = source === "session" ? `Your saved login was rejected (${err.message}). Run \`secondlayer login\`, or \`secondlayer logout\` to use SECONDLAYER_API_KEY.` : `Your account rejected the credential (${err.message}). ${ARCHIVE_AUTH_HINT}${ignoredEnvKeyNote(ignoredEnvKey)}`;
|
|
2375
|
+
throw new CliHttpError(401, err.code, err.body, remedy);
|
|
2375
2376
|
}
|
|
2376
2377
|
throw err;
|
|
2377
2378
|
}
|
|
@@ -31891,7 +31892,7 @@ var {
|
|
|
31891
31892
|
// package.json
|
|
31892
31893
|
var package_default = {
|
|
31893
31894
|
name: "@secondlayer/cli",
|
|
31894
|
-
version: "23.2.
|
|
31895
|
+
version: "23.2.1",
|
|
31895
31896
|
description: "Run a Stacks index on your own hardware — set it up, restore verified history, and keep it current.",
|
|
31896
31897
|
repository: {
|
|
31897
31898
|
type: "git",
|
|
@@ -37780,5 +37781,5 @@ registerCreditsCommand(program);
|
|
|
37780
37781
|
registerArchiveCommand(program);
|
|
37781
37782
|
program.parse();
|
|
37782
37783
|
|
|
37783
|
-
//# debugId=
|
|
37784
|
+
//# debugId=F92A663889BDE04D64756E2164756E21
|
|
37784
37785
|
//# sourceMappingURL=cli.js.map
|