Skip to content

Update pi to 1.5.0 and patch vulnerable dependencies - #416

Merged
ilovepixelart merged 2 commits into
mainfrom
fix/lockfile-security-updates
Nov 2, 2026
Merged

ilovepixelart merged 2 commits into
mainfrom
fix/lockfile-security-updates

Conversation

@ilovepixelart

Copy link
Copy Markdown
Owner

Moves the pi packages to 1.5.0 and updates vulnerable transitive dependencies, clearing all open Dependabot alerts and every npm audit finding. pi 1.5.0 changes its published types and system prompt, so three extensions change with it. The published dependency ranges in package.json are unchanged.

Process crash from a malicious server

  • undici 8.10.2 to 8.12.3, through pi 1.5.0 (GHSA-xjj6-f33q-929c). A response with six content codings followed by an early close ended the process with an uncaught UND_ERR_SOCKET, even when the fetch() rejection was caught. MCP HTTP transports and HTTP hooks use global fetch, which pi routes through this copy. The same response now only rejects the fetch() call.

Lockfile-only updates

Package From To Advisory
body-parser 2.3.0 2.4.0 GHSA-27r3-jxmh-p828
ip-address 10.7.3 10.7.5 GHSA-rxp7-6hxx-x8q5
fast-uri 3.1.8 3.1.9 GHSA-w74x-v6f9-j3xg, GHSA-wjr9-j795-jxcr, GHSA-333x-w4r6-6crp, GHSA-xhq7-xmqj-769h
zod 4.6.5 4.6.7 GHSA-mrhx-c7xc-m3w5
qs 6.16.0 6.17.1 GHSA-6pq8-jhm2-2vcw
minimatch 10.2.6 11.0.3 GHSA-g3hv-75wg-m249

pi 1.5.0 compatibility

  • Output styles replace the instructions after an earlier extension forced the prompt (extensions/output-styles.ts). pi 1.5.0 reworded the prompt line the string fallback cuts at, so the style was appended and the default instructions stayed. The fallback now matches the current line and the line used before 1.5. The structured prompt path is unchanged.

  • Tool parameters keep their types (extensions/internal/string-enum.ts). pi-ai 1.5.0 types StringEnum as a pi-schema Schema, which TypeBox's Static reads as unknown, so todo and subagent failed tsc. A wrapper restores the type and emits the same { type: 'string', enum } schema.

  • gitShadow returns truncated (extensions/git-checkpoint.ts). ExecResult now requires the field.

  • npm run check passes (Biome, strict tsc, Vitest)

  • Tests cover the change

pi-ai 1.5 types StringEnum as a pi-schema Schema, which TypeBox's Static
reads as unknown, and ExecResult gains a required truncated field. The
emitted schema is unchanged, and hosts before 1.5 still compile.
pi 1.5.0 pins undici 8.12.3. On 8.10.2 a server sending more than five
content codings and closing early ended the process through global fetch,
which MCP HTTP transports and HTTP hooks use (GHSA-xjj6-f33q-929c).
Lockfile only: fast-uri 3.1.9, body-parser 2.4.0, ip-address 10.7.5,
zod 4.6.7, qs 6.17.1, minimatch 11.0.3.

pi 1.5.0 reworded the prompt line output styles cut at, so a style applied
after an earlier extension forced the prompt was appended instead of
replacing the instructions. Both the current and the older line now match.
@sonarqubecloud

sonarqubecloud Bot commented Nov 2, 2026

Copy link
Copy Markdown

@ilovepixelart
ilovepixelart merged commit 24ac209 into main Nov 2, 2026
13 checks passed
@ilovepixelart
ilovepixelart deleted the fix/lockfile-security-updates branch November 2, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant