fix: repair the static-check failures on the default branch (#2895)
* fix: repair the static-check failures on the default branch
The default branch fails its own required `Static checks` job three ways, so
every pull request reports that job as failed regardless of its own change.
- `npm run format:check` reports `src/domain/functionComparison.test.ts` and
`src/ida/IdaOperationRunner.ts`.
- `npm run lint` reports a duplicate `import { join } from "node:path"` in
`tests/boundary/mcp/ghidraInventoryMcp.test.ts` (lines 4 and 17).
- `npm run typecheck` reports `format: "devin"` missing from the client format
union in `src/application/SupportedClients.ts`, and an unchecked index in
`tests/boundary/cli/clientProfileLifecycle.test.ts`, whose pair array is
inferred as `string[][]`.
Apply the pinned formatter, drop the duplicate import, list the `"devin"` format
that its own definition already uses, and mark the pair array `as const`.
Validation: `npm run check:fast` and `npm run format:check` pass.
* fix(setup): keep Devin on the JSON configuration dialect
---------
Co-authored-by: 吴佳浩 <wujiahao@supremind.com>
Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
This commit is contained in:
@@ -539,7 +539,7 @@ export const SUPPORTED_CLIENT_DEFINITIONS = [
|
|||||||
configPath: ({ home, platform, env }: ClientPathContext) =>
|
configPath: ({ home, platform, env }: ClientPathContext) =>
|
||||||
join(devinDirectory({ home, platform, env }), "mcp_config.json"),
|
join(devinDirectory({ home, platform, env }), "mcp_config.json"),
|
||||||
markerPath: devinDirectory,
|
markerPath: devinDirectory,
|
||||||
format: "devin",
|
format: "json",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "opencode",
|
name: "opencode",
|
||||||
|
|||||||
@@ -175,7 +175,9 @@ describe("function comparison normalized identity", () => {
|
|||||||
it("retains unresolved call details alongside missing facet coverage", () => {
|
it("retains unresolved call details alongside missing facet coverage", () => {
|
||||||
const value: Record<string, unknown> = {
|
const value: Record<string, unknown> = {
|
||||||
...dossier("return 0;", "0x1000"),
|
...dossier("return 0;", "0x1000"),
|
||||||
unresolved_calls: [{ address: "0x1010", reason: "Unknown indirect target" }],
|
unresolved_calls: [
|
||||||
|
{ address: "0x1010", reason: "Unknown indirect target" },
|
||||||
|
],
|
||||||
};
|
};
|
||||||
delete value.facet_availability;
|
delete value.facet_availability;
|
||||||
const legacy = observe("a", functionDossierSchema.parse(value), "ida");
|
const legacy = observe("a", functionDossierSchema.parse(value), "ida");
|
||||||
|
|||||||
@@ -503,7 +503,8 @@ export class IdaOperationRunner {
|
|||||||
items: [],
|
items: [],
|
||||||
availability: {
|
availability: {
|
||||||
available: false,
|
available: false,
|
||||||
reason: "Upstream xrefs do not establish direct caller relationships.",
|
reason:
|
||||||
|
"Upstream xrefs do not establish direct caller relationships.",
|
||||||
},
|
},
|
||||||
coverage: {
|
coverage: {
|
||||||
status: "unknown",
|
status: "unknown",
|
||||||
|
|||||||
@@ -290,7 +290,7 @@ cliTest("uninstall names each retained skill directory", async ({ cli }) => {
|
|||||||
for (const [client, directory] of [
|
for (const [client, directory] of [
|
||||||
["shared", shared],
|
["shared", shared],
|
||||||
["claude_code", claude],
|
["claude_code", claude],
|
||||||
]) {
|
] as const) {
|
||||||
expect(skill?.detail).toContain(
|
expect(skill?.detail).toContain(
|
||||||
`${client} (${directory}): retained (Skill manifest is not REA-owned.)`,
|
`${client} (${directory}): retained (Skill manifest is not REA-owned.)`,
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -14,7 +14,6 @@ import {
|
|||||||
} from "./ghidraMcpHarness.js";
|
} from "./ghidraMcpHarness.js";
|
||||||
import { spawn } from "node:child_process";
|
import { spawn } from "node:child_process";
|
||||||
import { mkdir } from "node:fs/promises";
|
import { mkdir } from "node:fs/promises";
|
||||||
import { join } from "node:path";
|
|
||||||
import { fileURLToPath } from "node:url";
|
import { fileURLToPath } from "node:url";
|
||||||
import { Client, InMemoryTransport } from "@modelcontextprotocol/client";
|
import { Client, InMemoryTransport } from "@modelcontextprotocol/client";
|
||||||
import { GhidraClient } from "../../../src/ghidra/GhidraClient.js";
|
import { GhidraClient } from "../../../src/ghidra/GhidraClient.js";
|
||||||
|
|||||||
Reference in New Issue
Block a user