@timurproko/a1 0.1.8-dev.0aceebe → 0.1.8-dev.3b54f21
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/native/darwin-arm64/manifest.json +1 -1
- package/dist/native/linux-x64/manifest.json +1 -1
- package/dist/native/win32-x64/manifest.json +2 -2
- package/dist/native/win32-x64/process-guardian.exe +0 -0
- package/dist/src/foundation/release/index.d.ts +0 -1
- package/dist/src/foundation/release/index.js +0 -1
- package/package.json +1 -1
- package/dist/src/foundation/release/development-preview-release.d.ts +0 -49
- package/dist/src/foundation/release/development-preview-release.js +0 -114
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"platform": "darwin",
|
|
6
6
|
"architecture": "arm64",
|
|
7
7
|
"capability": "unsupported",
|
|
8
|
-
"builtAt": "2026-08-24T07:
|
|
8
|
+
"builtAt": "2026-08-24T07:13:11.159Z",
|
|
9
9
|
"artifact": {
|
|
10
10
|
"filename": "process-guardian",
|
|
11
11
|
"sha256": "7524bf568992517f50ed53196c861c5edeba0d7275633bb4735ab45bd5963a28",
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"platform": "linux",
|
|
6
6
|
"architecture": "x64",
|
|
7
7
|
"capability": "supported",
|
|
8
|
-
"builtAt": "2026-08-24T07:
|
|
8
|
+
"builtAt": "2026-08-24T07:13:11.090Z",
|
|
9
9
|
"artifact": {
|
|
10
10
|
"filename": "process-guardian",
|
|
11
11
|
"sha256": "29e22fe29de2828982bc67ef418c4adcaab1490281477b7bea592ec6fe621bcd",
|
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
"platform": "win32",
|
|
6
6
|
"architecture": "x64",
|
|
7
7
|
"capability": "supported",
|
|
8
|
-
"builtAt": "2026-08-24T07:
|
|
8
|
+
"builtAt": "2026-08-24T07:13:46.176Z",
|
|
9
9
|
"artifact": {
|
|
10
10
|
"filename": "process-guardian.exe",
|
|
11
|
-
"sha256": "
|
|
11
|
+
"sha256": "e9d61d614aa418c84bff93abb65342f0c05c1a670b77e22a88d01d2d61eba9b7",
|
|
12
12
|
"size": 172544
|
|
13
13
|
},
|
|
14
14
|
"provenance": {
|
|
Binary file
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export * from "./bootstrap.js";
|
|
2
2
|
export * from "./cohort-selection.js";
|
|
3
3
|
export * from "./cohort-state.js";
|
|
4
|
-
export * from "./development-preview-release.js";
|
|
5
4
|
export * from "./process-cleanup.js";
|
|
6
5
|
export * from "./release.js";
|
|
7
6
|
export * from "./release-gc.js";
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export * from "./bootstrap.js";
|
|
2
2
|
export * from "./cohort-selection.js";
|
|
3
3
|
export * from "./cohort-state.js";
|
|
4
|
-
export * from "./development-preview-release.js";
|
|
5
4
|
export * from "./process-cleanup.js";
|
|
6
5
|
export * from "./release.js";
|
|
7
6
|
export * from "./release-gc.js";
|
package/package.json
CHANGED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
export declare const PREVIEW_RELEASE_SCHEMA: string;
|
|
2
|
-
export interface DevelopmentPreviewCandidate {
|
|
3
|
-
readonly version: string;
|
|
4
|
-
readonly requiresVersionCommit: boolean;
|
|
5
|
-
}
|
|
6
|
-
export interface DevelopmentPreviewRegistryState {
|
|
7
|
-
readonly published: boolean;
|
|
8
|
-
readonly nextVersion: string | null;
|
|
9
|
-
}
|
|
10
|
-
export interface DevelopmentPreviewVerificationOptions {
|
|
11
|
-
readonly attempts?: number;
|
|
12
|
-
readonly delayMs?: number;
|
|
13
|
-
readonly delay?: (milliseconds: number) => Promise<void>;
|
|
14
|
-
}
|
|
15
|
-
export interface DevelopmentPreviewPublishResult {
|
|
16
|
-
readonly published: boolean;
|
|
17
|
-
readonly recoveredPublishError: unknown | null;
|
|
18
|
-
}
|
|
19
|
-
export interface UncertifiedDevelopmentPreviewEvidenceInput {
|
|
20
|
-
readonly packageName: string;
|
|
21
|
-
readonly version: string;
|
|
22
|
-
readonly commit: string;
|
|
23
|
-
readonly tarball: string;
|
|
24
|
-
readonly integrity: string;
|
|
25
|
-
readonly shasum: string;
|
|
26
|
-
readonly platform: NodeJS.Platform;
|
|
27
|
-
readonly architecture: string;
|
|
28
|
-
readonly recordedAt: string;
|
|
29
|
-
}
|
|
30
|
-
export interface UncertifiedDevelopmentPreviewEvidence extends UncertifiedDevelopmentPreviewEvidenceInput {
|
|
31
|
-
readonly schema: typeof PREVIEW_RELEASE_SCHEMA;
|
|
32
|
-
readonly channel: "next";
|
|
33
|
-
readonly certificationStatus: "uncertified-development-preview";
|
|
34
|
-
readonly terminalCapability: "owned-ui";
|
|
35
|
-
readonly manualAcceptance: "accepted";
|
|
36
|
-
readonly physicalHostCertification: "deferred";
|
|
37
|
-
readonly crossPlatformCertification: "deferred";
|
|
38
|
-
readonly stableReleaseEligible: false;
|
|
39
|
-
}
|
|
40
|
-
export declare function createUncertifiedDevelopmentPreviewEvidence(input: UncertifiedDevelopmentPreviewEvidenceInput): UncertifiedDevelopmentPreviewEvidence;
|
|
41
|
-
export declare function requireManuallyAcceptedDevelopmentPreview(version: string, acceptedVersion: string): void;
|
|
42
|
-
export declare function selectDevelopmentPreviewCandidate(currentVersion: string, publishedVersions: readonly string[]): DevelopmentPreviewCandidate;
|
|
43
|
-
/**
|
|
44
|
-
* Treats npm's process result as provisional: browser-auth completion can fail
|
|
45
|
-
* after the immutable upload succeeds. Registry identity remains authoritative.
|
|
46
|
-
*/
|
|
47
|
-
export declare function publishDevelopmentPreviewWithRecovery(publish: () => Promise<void>, verify: () => Promise<void>): Promise<DevelopmentPreviewPublishResult>;
|
|
48
|
-
export declare function verifyDevelopmentPreviewRegistry(version: string, observe: () => Promise<DevelopmentPreviewRegistryState>, repairNextTag: () => Promise<void>, options?: DevelopmentPreviewVerificationOptions): Promise<void>;
|
|
49
|
-
export declare function developmentPreviewTarballName(packageName: string, version: string): string;
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
import { compare, inc, prerelease, valid } from "semver";
|
|
2
|
-
import { PRODUCT_IDENTITY } from "../../product-identity.js";
|
|
3
|
-
export const PREVIEW_RELEASE_SCHEMA = PRODUCT_IDENTITY.evidence.previewReleaseSchema;
|
|
4
|
-
export function createUncertifiedDevelopmentPreviewEvidence(input) {
|
|
5
|
-
const prereleaseParts = prerelease(input.version);
|
|
6
|
-
if (valid(input.version) === null || prereleaseParts?.[0] !== "dev") {
|
|
7
|
-
throw new Error(`uncertified preview requires a development prerelease: ${input.version}`);
|
|
8
|
-
}
|
|
9
|
-
return {
|
|
10
|
-
schema: PREVIEW_RELEASE_SCHEMA,
|
|
11
|
-
channel: "next",
|
|
12
|
-
certificationStatus: "uncertified-development-preview",
|
|
13
|
-
terminalCapability: "owned-ui",
|
|
14
|
-
manualAcceptance: "accepted",
|
|
15
|
-
physicalHostCertification: "deferred",
|
|
16
|
-
crossPlatformCertification: "deferred",
|
|
17
|
-
stableReleaseEligible: false,
|
|
18
|
-
...input,
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
export function requireManuallyAcceptedDevelopmentPreview(version, acceptedVersion) {
|
|
22
|
-
const acceptedPrerelease = prerelease(acceptedVersion);
|
|
23
|
-
if (valid(acceptedVersion) === null || acceptedPrerelease?.[0] !== "dev") {
|
|
24
|
-
throw new Error(`invalid manually accepted development preview: ${acceptedVersion}`);
|
|
25
|
-
}
|
|
26
|
-
if (version !== acceptedVersion) {
|
|
27
|
-
throw new Error(`development preview ${version} has no exact manual acceptance; accepted version is ${acceptedVersion}`);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
export function selectDevelopmentPreviewCandidate(currentVersion, publishedVersions) {
|
|
31
|
-
if (valid(currentVersion) === null)
|
|
32
|
-
throw new Error(`invalid current package version: ${currentVersion}`);
|
|
33
|
-
const published = publishedVersions.map(version => {
|
|
34
|
-
if (valid(version) === null)
|
|
35
|
-
throw new Error(`invalid published package version: ${version}`);
|
|
36
|
-
return version;
|
|
37
|
-
});
|
|
38
|
-
const publishedSet = new Set(published);
|
|
39
|
-
const highestPublished = published.reduce((highest, version) => highest === null || compare(version, highest) > 0 ? version : highest, null);
|
|
40
|
-
const currentPrerelease = prerelease(currentVersion);
|
|
41
|
-
const currentIsUnpublishedLeadingDev = currentPrerelease?.[0] === "dev"
|
|
42
|
-
&& !publishedSet.has(currentVersion)
|
|
43
|
-
&& (highestPublished === null || compare(currentVersion, highestPublished) > 0);
|
|
44
|
-
if (currentIsUnpublishedLeadingDev)
|
|
45
|
-
return { version: currentVersion, requiresVersionCommit: false };
|
|
46
|
-
const base = highestPublished === null || compare(currentVersion, highestPublished) > 0
|
|
47
|
-
? currentVersion
|
|
48
|
-
: highestPublished;
|
|
49
|
-
const basePrerelease = prerelease(base);
|
|
50
|
-
let candidate = basePrerelease?.[0] === "dev"
|
|
51
|
-
? inc(base, "prerelease", "dev")
|
|
52
|
-
: inc(base, "prepatch", "dev");
|
|
53
|
-
if (candidate === null)
|
|
54
|
-
throw new Error(`could not increment development preview from ${base}`);
|
|
55
|
-
while (publishedSet.has(candidate)) {
|
|
56
|
-
candidate = inc(candidate, "prerelease", "dev");
|
|
57
|
-
if (candidate === null)
|
|
58
|
-
throw new Error(`could not increment development preview from ${base}`);
|
|
59
|
-
}
|
|
60
|
-
return { version: candidate, requiresVersionCommit: candidate !== currentVersion };
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Treats npm's process result as provisional: browser-auth completion can fail
|
|
64
|
-
* after the immutable upload succeeds. Registry identity remains authoritative.
|
|
65
|
-
*/
|
|
66
|
-
export async function publishDevelopmentPreviewWithRecovery(publish, verify) {
|
|
67
|
-
let publishError = null;
|
|
68
|
-
try {
|
|
69
|
-
await publish();
|
|
70
|
-
}
|
|
71
|
-
catch (error) {
|
|
72
|
-
publishError = error;
|
|
73
|
-
}
|
|
74
|
-
try {
|
|
75
|
-
await verify();
|
|
76
|
-
return { published: true, recoveredPublishError: publishError };
|
|
77
|
-
}
|
|
78
|
-
catch (verificationError) {
|
|
79
|
-
if (publishError !== null)
|
|
80
|
-
throw new AggregateError([publishError, verificationError], "npm publish failed and the exact version could not be verified in the registry");
|
|
81
|
-
throw verificationError;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
export async function verifyDevelopmentPreviewRegistry(version, observe, repairNextTag, options = {}) {
|
|
85
|
-
const attempts = options.attempts ?? 12;
|
|
86
|
-
const delayMs = options.delayMs ?? 2_000;
|
|
87
|
-
const delay = options.delay ?? (async (milliseconds) => await new Promise(resolvePromise => setTimeout(resolvePromise, milliseconds)));
|
|
88
|
-
if (!Number.isInteger(attempts) || attempts < 1)
|
|
89
|
-
throw new Error(`invalid registry verification attempts: ${attempts}`);
|
|
90
|
-
let repaired = false;
|
|
91
|
-
let last = { published: false, nextVersion: null };
|
|
92
|
-
for (let attempt = 1; attempt <= attempts; attempt += 1) {
|
|
93
|
-
last = await observe();
|
|
94
|
-
if (last.published && last.nextVersion === version)
|
|
95
|
-
return;
|
|
96
|
-
if (last.published && !repaired) {
|
|
97
|
-
await repairNextTag();
|
|
98
|
-
repaired = true;
|
|
99
|
-
}
|
|
100
|
-
if (attempt < attempts)
|
|
101
|
-
await delay(delayMs);
|
|
102
|
-
}
|
|
103
|
-
if (!last.published)
|
|
104
|
-
throw new Error(`npm registry did not expose published version ${version} after ${attempts} attempts`);
|
|
105
|
-
throw new Error(`npm next resolved ${last.nextVersion ?? "nothing"}; expected ${version} after ${attempts} attempts`);
|
|
106
|
-
}
|
|
107
|
-
export function developmentPreviewTarballName(packageName, version) {
|
|
108
|
-
if (valid(version) === null)
|
|
109
|
-
throw new Error(`invalid development preview version: ${version}`);
|
|
110
|
-
const unscopedName = packageName.startsWith("@") ? packageName.slice(1).replace("/", "-") : packageName;
|
|
111
|
-
if (!/^[a-z0-9._-]+$/i.test(unscopedName))
|
|
112
|
-
throw new Error(`invalid package name: ${packageName}`);
|
|
113
|
-
return `${unscopedName}-${version}.tgz`;
|
|
114
|
-
}
|