mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-29 18:46:59 +00:00
fix(photon): tolerate SDK builds without the iMessage effect surface
imessage.effect.message crashed the sidecar at import against SDK stubs/
builds lacking the effect surface (caught by the patch-failure health test).
Optional-chain with {} fallback; /send-effect rejects cleanly instead.
This commit is contained in:
parent
cf550c0863
commit
402286fcff
1 changed files with 4 additions and 1 deletions
|
|
@ -278,7 +278,10 @@ const app = await Spectrum({
|
|||
telemetry,
|
||||
});
|
||||
|
||||
const MESSAGE_EFFECTS = imessage.effect.message;
|
||||
// Effect-name → native effect id map. Optional chaining: an SDK build
|
||||
// without the iMessage effect surface (or a test stub) must not crash the
|
||||
// sidecar at import — /send-effect then rejects with "unsupported effect".
|
||||
const MESSAGE_EFFECTS = imessage?.effect?.message || {};
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Inbound: forward `app.messages` (gRPC stream) to the Python consumer.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue