playcademy 0.14.31-alpha.1 → 0.14.32-alpha.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 +4 -1
- package/dist/db.js +3 -0
- package/dist/index.js +21 -4
- package/dist/utils.js +14 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -1269,6 +1269,9 @@ function hasPackageJson(dir) {
|
|
|
1269
1269
|
return existsSync3(resolve2(dir || getWorkspace(), "package.json"));
|
|
1270
1270
|
}
|
|
1271
1271
|
|
|
1272
|
+
// src/lib/core/errors.ts
|
|
1273
|
+
import { ApiError as ApiError2 } from "@playcademy/sdk/internal";
|
|
1274
|
+
|
|
1272
1275
|
// src/lib/core/gitignore.ts
|
|
1273
1276
|
function normalizeGitignoreEntry(entry) {
|
|
1274
1277
|
return entry.replace(/^\/+/, "").replace(/\/+$/, "");
|
|
@@ -2754,7 +2757,7 @@ import { join as join13 } from "path";
|
|
|
2754
2757
|
// package.json with { type: 'json' }
|
|
2755
2758
|
var package_default2 = {
|
|
2756
2759
|
name: "playcademy",
|
|
2757
|
-
version: "0.14.
|
|
2760
|
+
version: "0.14.32",
|
|
2758
2761
|
type: "module",
|
|
2759
2762
|
exports: {
|
|
2760
2763
|
".": {
|
package/dist/db.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -1411,7 +1411,20 @@ function printDebugInfo() {
|
|
|
1411
1411
|
}
|
|
1412
1412
|
|
|
1413
1413
|
// src/lib/core/errors.ts
|
|
1414
|
+
import { ApiError as ApiError2 } from "@playcademy/sdk/internal";
|
|
1414
1415
|
function getErrorMessage(error) {
|
|
1416
|
+
if (error instanceof ApiError2 && error.details) {
|
|
1417
|
+
const details = error.details;
|
|
1418
|
+
if (details.error && typeof details.error === "object") {
|
|
1419
|
+
const errorObj = details.error;
|
|
1420
|
+
if (typeof errorObj.message === "string") {
|
|
1421
|
+
return errorObj.message;
|
|
1422
|
+
}
|
|
1423
|
+
}
|
|
1424
|
+
if (typeof details.message === "string") {
|
|
1425
|
+
return details.message;
|
|
1426
|
+
}
|
|
1427
|
+
}
|
|
1415
1428
|
if (error instanceof Error) return error.message;
|
|
1416
1429
|
if (typeof error === "string") return error;
|
|
1417
1430
|
if (error && typeof error === "object" && "message" in error) {
|
|
@@ -1424,6 +1437,10 @@ function logAndExit(error, options = {}) {
|
|
|
1424
1437
|
const message = getErrorMessage(error);
|
|
1425
1438
|
const fullMessage = prefix ? `${prefix}: ${message}` : message;
|
|
1426
1439
|
logger.error(fullMessage);
|
|
1440
|
+
if (process.env.DEBUG && error instanceof ApiError2 && error.details) {
|
|
1441
|
+
logger.newLine();
|
|
1442
|
+
logger.json(error.details, 1);
|
|
1443
|
+
}
|
|
1427
1444
|
logger.newLine();
|
|
1428
1445
|
process.exit(code);
|
|
1429
1446
|
}
|
|
@@ -3539,7 +3556,7 @@ import { join as join12 } from "path";
|
|
|
3539
3556
|
// package.json with { type: 'json' }
|
|
3540
3557
|
var package_default2 = {
|
|
3541
3558
|
name: "playcademy",
|
|
3542
|
-
version: "0.14.
|
|
3559
|
+
version: "0.14.32",
|
|
3543
3560
|
type: "module",
|
|
3544
3561
|
exports: {
|
|
3545
3562
|
".": {
|
|
@@ -7544,7 +7561,7 @@ var INTERACTION_TYPE = Object.fromEntries(
|
|
|
7544
7561
|
);
|
|
7545
7562
|
|
|
7546
7563
|
// src/lib/deploy/secrets.ts
|
|
7547
|
-
import { ApiError as
|
|
7564
|
+
import { ApiError as ApiError3 } from "@playcademy/sdk/internal";
|
|
7548
7565
|
function compareSecrets(current, previous) {
|
|
7549
7566
|
const currentKeys = Object.keys(current);
|
|
7550
7567
|
const changes = [];
|
|
@@ -7570,7 +7587,7 @@ async function fetchSecretsForDeployment(slug) {
|
|
|
7570
7587
|
const keys = Object.keys(secrets);
|
|
7571
7588
|
return { secrets, keys };
|
|
7572
7589
|
} catch (error) {
|
|
7573
|
-
if (error instanceof
|
|
7590
|
+
if (error instanceof ApiError3 && error.status === 404) {
|
|
7574
7591
|
logger.debug(`[Secrets] No secrets configured for project (404)`);
|
|
7575
7592
|
return { secrets: {}, keys: [] };
|
|
7576
7593
|
}
|
|
@@ -9726,7 +9743,7 @@ var getStatusCommand = new Command12("status").description("Check your developer
|
|
|
9726
9743
|
});
|
|
9727
9744
|
|
|
9728
9745
|
// package.json
|
|
9729
|
-
var version2 = "0.14.
|
|
9746
|
+
var version2 = "0.14.32";
|
|
9730
9747
|
|
|
9731
9748
|
// src/commands/dev/server.ts
|
|
9732
9749
|
function setupCleanupHandlers(workspace, getServer) {
|
package/dist/utils.js
CHANGED
|
@@ -1303,7 +1303,20 @@ Stop the other server or specify a different port with --port <number>.`
|
|
|
1303
1303
|
import { PlaycademyClient } from "@playcademy/sdk/internal";
|
|
1304
1304
|
|
|
1305
1305
|
// src/lib/core/errors.ts
|
|
1306
|
+
import { ApiError as ApiError2 } from "@playcademy/sdk/internal";
|
|
1306
1307
|
function getErrorMessage(error) {
|
|
1308
|
+
if (error instanceof ApiError2 && error.details) {
|
|
1309
|
+
const details = error.details;
|
|
1310
|
+
if (details.error && typeof details.error === "object") {
|
|
1311
|
+
const errorObj = details.error;
|
|
1312
|
+
if (typeof errorObj.message === "string") {
|
|
1313
|
+
return errorObj.message;
|
|
1314
|
+
}
|
|
1315
|
+
}
|
|
1316
|
+
if (typeof details.message === "string") {
|
|
1317
|
+
return details.message;
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1307
1320
|
if (error instanceof Error) return error.message;
|
|
1308
1321
|
if (typeof error === "string") return error;
|
|
1309
1322
|
if (error && typeof error === "object" && "message" in error) {
|
|
@@ -2208,7 +2221,7 @@ import { join as join12 } from "path";
|
|
|
2208
2221
|
// package.json with { type: 'json' }
|
|
2209
2222
|
var package_default2 = {
|
|
2210
2223
|
name: "playcademy",
|
|
2211
|
-
version: "0.14.
|
|
2224
|
+
version: "0.14.32",
|
|
2212
2225
|
type: "module",
|
|
2213
2226
|
exports: {
|
|
2214
2227
|
".": {
|
package/dist/version.js
CHANGED