codex-plugin-doctor 1.49.0 → 1.50.0
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/README.md
CHANGED
|
@@ -427,9 +427,9 @@ jobs:
|
|
|
427
427
|
runs-on: ubuntu-latest
|
|
428
428
|
steps:
|
|
429
429
|
- uses: actions/checkout@v5
|
|
430
|
-
- uses: Esquetta/CodexPluginDoctor@v1.
|
|
430
|
+
- uses: Esquetta/CodexPluginDoctor@v1.50.0
|
|
431
431
|
with:
|
|
432
|
-
version: "1.
|
|
432
|
+
version: "1.50.0"
|
|
433
433
|
path: .
|
|
434
434
|
runtime: "true"
|
|
435
435
|
policy: codex-publish
|
|
@@ -441,7 +441,7 @@ jobs:
|
|
|
441
441
|
review-bundle-verify: "true"
|
|
442
442
|
```
|
|
443
443
|
|
|
444
|
-
The action writes `codex-plugin-doctor-summary.md`, `codex-plugin-doctor-report.json`, `codex-plugin-doctor-action-manifest.json`, optional `codex-plugin-doctor.sarif`, optional
|
|
444
|
+
The action writes `codex-plugin-doctor-summary.md`, `codex-plugin-doctor-report.json`, `codex-plugin-doctor-action-manifest.json`, optional `codex-plugin-doctor.sarif`, optional validation corpus and quality metrics reports, optional `output-contract.json`, and optional signed `review-bundle/` files to `codex-plugin-doctor-reports`, appends the Markdown report to the GitHub Actions step summary, uploads the report directory as an artifact, and then returns the real validation exit code. Review bundle generation requires a signing key environment variable such as `CODEX_PLUGIN_DOCTOR_SIGNING_KEY`. For runtime probing, SARIF output, corpus quality regression gates, corpus and contract artifacts, review bundle artifacts, installed plugin cache checks, CI policy presets, and pinned release examples, see [GitHub Action Usage](./docs/guides/github-action.md).
|
|
445
445
|
|
|
446
446
|
To self-test this repository after cloning it:
|
|
447
447
|
|
|
@@ -38,6 +38,17 @@ export interface DoctorNpmPackageReport {
|
|
|
38
38
|
export interface BuildDoctorNpmPackageReportOptions {
|
|
39
39
|
environment?: CompatibilityEnvironment;
|
|
40
40
|
}
|
|
41
|
+
export interface NpmPackEntry {
|
|
42
|
+
filename?: string;
|
|
43
|
+
name?: string;
|
|
44
|
+
version?: string;
|
|
45
|
+
files?: unknown[];
|
|
46
|
+
integrity?: string;
|
|
47
|
+
shasum?: string;
|
|
48
|
+
size?: number;
|
|
49
|
+
unpackedSize?: number;
|
|
50
|
+
}
|
|
51
|
+
export declare function parseNpmPackOutput(stdout: string): NpmPackEntry[];
|
|
41
52
|
export declare function buildDoctorNpmPackageReport(packageSpec: string, options?: BuildDoctorNpmPackageReportOptions): Promise<DoctorNpmPackageReport>;
|
|
42
53
|
export declare function renderDoctorNpmPackageReportJson(report: DoctorNpmPackageReport): string;
|
|
43
54
|
export declare function renderDoctorNpmPackageReport(report: DoctorNpmPackageReport, options?: {
|
|
@@ -7,6 +7,16 @@ import { gunzip } from "node:zlib";
|
|
|
7
7
|
import { buildDoctorRecommendationsFromAnalysis, buildPackageAnalysis } from "./package-analysis.js";
|
|
8
8
|
const execFileAsync = promisify(execFile);
|
|
9
9
|
const gunzipAsync = promisify(gunzip);
|
|
10
|
+
export function parseNpmPackOutput(stdout) {
|
|
11
|
+
const parsed = JSON.parse(stdout);
|
|
12
|
+
if (Array.isArray(parsed)) {
|
|
13
|
+
return parsed.filter((entry) => typeof entry === "object" && entry !== null);
|
|
14
|
+
}
|
|
15
|
+
if (typeof parsed === "object" && parsed !== null) {
|
|
16
|
+
return Object.values(parsed).filter((entry) => typeof entry === "object" && entry !== null);
|
|
17
|
+
}
|
|
18
|
+
return [];
|
|
19
|
+
}
|
|
10
20
|
function npmCommand(args) {
|
|
11
21
|
if (process.platform === "win32") {
|
|
12
22
|
const npmCliPath = process.env.npm_execpath ??
|
|
@@ -108,8 +118,8 @@ async function packNpmPackage(packageSpec, destinationPath) {
|
|
|
108
118
|
env: npmPackEnvironment(),
|
|
109
119
|
maxBuffer: 10 * 1024 * 1024
|
|
110
120
|
});
|
|
111
|
-
const packEntries =
|
|
112
|
-
const metadata = packEntries
|
|
121
|
+
const packEntries = parseNpmPackOutput(stdout);
|
|
122
|
+
const metadata = packEntries.find((entry) => typeof entry.filename === "string");
|
|
113
123
|
if (!metadata?.filename) {
|
|
114
124
|
throw new Error(`npm pack did not return a tarball for ${packageSpec}`);
|
|
115
125
|
}
|
package/package.json
CHANGED