@hot-updater/aws 1.0.0-rc.27 → 1.0.0-rc.28
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.d.cts +2 -0
- package/dist/index.d.mts +2 -0
- package/dist/lambda/index.cjs +12 -2
- package/package.json +4 -4
package/dist/index.d.cts
CHANGED
|
@@ -84,6 +84,8 @@ type BundleEventFailure = DatabaseJsonObject & {
|
|
|
84
84
|
readonly transport?: "timeout" | "dns" | "tls" | "connection" | "offline" | "cancelled" | "unknown";
|
|
85
85
|
/** The storage origin's error code, such as `ExpiredToken`. */
|
|
86
86
|
readonly origin_code?: string;
|
|
87
|
+
readonly error_message?: string;
|
|
88
|
+
readonly error_stack?: string;
|
|
87
89
|
/** Android's `ApplicationExitInfo` reason for the process before this one. */
|
|
88
90
|
readonly previous_process_exit?: string;
|
|
89
91
|
};
|
package/dist/index.d.mts
CHANGED
|
@@ -84,6 +84,8 @@ type BundleEventFailure = DatabaseJsonObject & {
|
|
|
84
84
|
readonly transport?: "timeout" | "dns" | "tls" | "connection" | "offline" | "cancelled" | "unknown";
|
|
85
85
|
/** The storage origin's error code, such as `ExpiredToken`. */
|
|
86
86
|
readonly origin_code?: string;
|
|
87
|
+
readonly error_message?: string;
|
|
88
|
+
readonly error_stack?: string;
|
|
87
89
|
/** Android's `ApplicationExitInfo` reason for the process before this one. */
|
|
88
90
|
readonly previous_process_exit?: string;
|
|
89
91
|
};
|
package/dist/lambda/index.cjs
CHANGED
|
@@ -4570,7 +4570,7 @@ const createKvAdapter = ({ store, tablePrefix = "" }) => {
|
|
|
4570
4570
|
};
|
|
4571
4571
|
//#endregion
|
|
4572
4572
|
//#region ../../packages/server/dist/version.mjs
|
|
4573
|
-
const HOT_UPDATER_SERVER_VERSION = "1.0.0-rc.
|
|
4573
|
+
const HOT_UPDATER_SERVER_VERSION = "1.0.0-rc.28";
|
|
4574
4574
|
//#endregion
|
|
4575
4575
|
//#region ../../packages/server/dist/handlerVersionRoutes.mjs
|
|
4576
4576
|
/**
|
|
@@ -9791,7 +9791,7 @@ const apiKeys = (options = {}) => {
|
|
|
9791
9791
|
const isOptional = (value, key, valid) => !Object.hasOwn(value, key) || valid(value[key]);
|
|
9792
9792
|
const isString = (value) => typeof value === "string";
|
|
9793
9793
|
/** An `UPDATE_FAILED` report's stored failure: a stage and a reason, and what else the client knew. */
|
|
9794
|
-
const isDatabaseBundleEventFailure = (value) => isDatabaseJsonObject(value) && isString(value.stage) && isString(value.reason) && isOptional(value, "resource", isString) && isOptional(value, "http_status", (status) => Number.isSafeInteger(status)) && isOptional(value, "transport", isString) && isOptional(value, "origin_code", isString) && isOptional(value, "previous_process_exit", isString);
|
|
9794
|
+
const isDatabaseBundleEventFailure = (value) => isDatabaseJsonObject(value) && isString(value.stage) && isString(value.reason) && isOptional(value, "resource", isString) && isOptional(value, "http_status", (status) => Number.isSafeInteger(status)) && isOptional(value, "transport", isString) && isOptional(value, "origin_code", isString) && isOptional(value, "error_message", isString) && isOptional(value, "error_stack", isString) && isOptional(value, "previous_process_exit", isString);
|
|
9795
9795
|
const isDatabaseBundleEventMetadata = (value) => isDatabaseJsonObject(value) && typeof value.cohort === "string" && (value.update_strategy === null || value.update_strategy === "fingerprint" || value.update_strategy === "appVersion") && (value.fingerprint_hash === null || typeof value.fingerprint_hash === "string") && (value.sdk_version === null || typeof value.sdk_version === "string") && isOptional(value, "failure", isDatabaseBundleEventFailure) && isOptional(value, "delivery", isString) && isOptional(value, "patch_fallback", (flag) => typeof flag === "boolean") && isOptional(value, "previous_process_exit", isString);
|
|
9796
9796
|
const isRecord$2 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
9797
9797
|
const isIdentity$1 = (value) => typeof value === "string" && value.length > 0 && value.length <= 255;
|
|
@@ -10143,6 +10143,8 @@ function readFailure(value) {
|
|
|
10143
10143
|
const failure = isRecord$1(value) ? value : {};
|
|
10144
10144
|
const httpStatus = failure.httpStatus;
|
|
10145
10145
|
const originCode = readCode(failure.originCode);
|
|
10146
|
+
const errorMessage = typeof failure.errorMessage === "string" && failure.errorMessage.length <= 2048 ? failure.errorMessage : void 0;
|
|
10147
|
+
const errorStack = typeof failure.errorStack === "string" && failure.errorStack.length <= 4096 ? failure.errorStack : void 0;
|
|
10146
10148
|
const previousProcessExit = readCode(failure.previousProcessExit);
|
|
10147
10149
|
return {
|
|
10148
10150
|
stage: oneOf(STAGES, failure.stage),
|
|
@@ -10151,6 +10153,8 @@ function readFailure(value) {
|
|
|
10151
10153
|
...Number.isSafeInteger(httpStatus) && httpStatus >= 100 && httpStatus <= 599 ? { httpStatus } : {},
|
|
10152
10154
|
...failure.transport == null ? {} : { transport: oneOf(TRANSPORTS, failure.transport) },
|
|
10153
10155
|
...originCode === void 0 ? {} : { originCode },
|
|
10156
|
+
...errorMessage === void 0 ? {} : { errorMessage },
|
|
10157
|
+
...errorStack === void 0 ? {} : { errorStack },
|
|
10154
10158
|
...previousProcessExit === void 0 ? {} : { previousProcessExit }
|
|
10155
10159
|
};
|
|
10156
10160
|
}
|
|
@@ -10321,6 +10325,8 @@ function createBundleEventRow(input) {
|
|
|
10321
10325
|
failure: {
|
|
10322
10326
|
stage: failure.stage,
|
|
10323
10327
|
reason: failure.reason,
|
|
10328
|
+
...failure.errorMessage === void 0 ? {} : { error_message: failure.errorMessage },
|
|
10329
|
+
...failure.errorStack === void 0 ? {} : { error_stack: failure.errorStack },
|
|
10324
10330
|
...failure.resource === void 0 ? {} : { resource: failure.resource },
|
|
10325
10331
|
...failure.httpStatus === void 0 ? {} : { http_status: failure.httpStatus },
|
|
10326
10332
|
...failure.transport === void 0 ? {} : { transport: failure.transport },
|
|
@@ -10484,6 +10490,8 @@ const assertEventRows = (rows, input) => {
|
|
|
10484
10490
|
const toFailure = (failure) => ({
|
|
10485
10491
|
stage: failure.stage,
|
|
10486
10492
|
reason: failure.reason,
|
|
10493
|
+
...failure.error_message === void 0 ? {} : { errorMessage: failure.error_message },
|
|
10494
|
+
...failure.error_stack === void 0 ? {} : { errorStack: failure.error_stack },
|
|
10487
10495
|
...failure.resource === void 0 ? {} : { resource: failure.resource },
|
|
10488
10496
|
...failure.http_status === void 0 ? {} : { httpStatus: failure.http_status },
|
|
10489
10497
|
...failure.transport === void 0 ? {} : { transport: failure.transport },
|
|
@@ -10498,6 +10506,8 @@ const eventDetails = ({ type, metadata }) => ({
|
|
|
10498
10506
|
...type === "RECOVERED" && metadata.previous_process_exit !== void 0 ? { previousProcessExit: metadata.previous_process_exit } : {}
|
|
10499
10507
|
});
|
|
10500
10508
|
const toEventHistoryRow = (row) => ({
|
|
10509
|
+
...row.to_release_id == null ? {} : { toReleaseId: row.to_release_id },
|
|
10510
|
+
...row.metadata.sdk_version == null ? {} : { sdkVersion: row.metadata.sdk_version },
|
|
10501
10511
|
appVersion: row.app_version,
|
|
10502
10512
|
channel: row.channel,
|
|
10503
10513
|
cohort: row.metadata.cohort,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/aws",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.0-rc.
|
|
4
|
+
"version": "1.0.0-rc.28",
|
|
5
5
|
"description": "React Native OTA solution for self-hosted",
|
|
6
6
|
"main": "dist/index.cjs",
|
|
7
7
|
"module": "dist/index.mjs",
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"es-toolkit": "^1.32.0",
|
|
46
46
|
"execa": "9.5.2",
|
|
47
47
|
"mime": "^4.0.4",
|
|
48
|
-
"@hot-updater/mock": "1.0.0-rc.27",
|
|
49
48
|
"@hot-updater/protocol": "1.0.0-rc.27",
|
|
49
|
+
"@hot-updater/mock": "1.0.0-rc.27",
|
|
50
50
|
"@hot-updater/test-utils": "1.0.0-rc.27"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
@@ -62,8 +62,8 @@
|
|
|
62
62
|
"@aws-sdk/lib-storage": "3.1066.0",
|
|
63
63
|
"@aws-sdk/lib-dynamodb": "3.1066.0",
|
|
64
64
|
"hono": "4.12.34",
|
|
65
|
-
"@hot-updater/cli-tools": "1.0.0-rc.
|
|
66
|
-
"@hot-updater/server": "1.0.0-rc.
|
|
65
|
+
"@hot-updater/cli-tools": "1.0.0-rc.28",
|
|
66
|
+
"@hot-updater/server": "1.0.0-rc.28",
|
|
67
67
|
"@hot-updater/plugin-core": "1.0.0-rc.27"
|
|
68
68
|
},
|
|
69
69
|
"scripts": {
|