From d39072b6370f884ac2d3551ce8296d8ee78760e2 Mon Sep 17 00:00:00 2001 From: Tom Boucher Date: Thu, 6 Aug 2026 04:51:21 -0400 Subject: [PATCH] fix(#3022): suppress spurious typebox fallback warning on Pi startup (#3111) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix(#3022): suppress spurious typebox fallback warning on Pi startup The Pi adapter's buildGsdInvokeParameters attempts require('typebox') and falls back to a plain JSON-Schema object when it's unavailable (typebox is NOT a gsd-core dependency). The fallback is the normal, expected path — typebox is never installed in a Pi extension context. But the code emitted a process.stderr.write warning on every startup, alarming users. Removed the warning; the catch comment now explains the fallback is normal. * chore(#3022): backfill changeset PR number 3111 --------- Co-authored-by: sim --- .changeset/daring-hawks-bark.md | 5 +++++ pi/gsd.cjs | 7 +++---- 2 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 .changeset/daring-hawks-bark.md diff --git a/.changeset/daring-hawks-bark.md b/.changeset/daring-hawks-bark.md new file mode 100644 index 000000000..d461728cb --- /dev/null +++ b/.changeset/daring-hawks-bark.md @@ -0,0 +1,5 @@ +--- +type: Fixed +pr: 3111 +--- +**Pi no longer emits a `typebox unavailable` warning at every startup** — the warning fired because the Pi adapter attempts to `require('typebox')` (not a gsd-core dependency) and falls back to a plain JSON-Schema object on every startup. The fallback is the normal path; the warning is now suppressed. (#3022) diff --git a/pi/gsd.cjs b/pi/gsd.cjs index 9a3fdc702..7b3bca182 100644 --- a/pi/gsd.cjs +++ b/pi/gsd.cjs @@ -148,11 +148,10 @@ function buildGsdInvokeParameters() { }); } } catch { - // typebox is not installed in this environment — fall through. + // typebox is not installed in this environment — fall through to the + // plain JSON-Schema fallback below. This is the normal path (typebox is + // NOT a gsd-core dependency), so no warning is emitted (#3022). } - process.stderr.write( - 'gsd: typebox unavailable — gsd_invoke "parameters" falling back to a plain JSON-schema object.\n', - ); return { type: 'object', properties: {