{"version":"2.1.287","anchor":"sdk-stream-holds-frames-until-init-writeafterinit","canonical_anchor":"sdk-stream-holds-frames-until-init-writeafterinit","heading":"SDK output can hold messages back until the session start message is sent","tier":"notice","area":"SDK","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.287\/e\/sdk-stream-holds-frames-until-init-writeafterinit","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.287","markdown":"### SDK output can hold messages back until the session start message is sent\n\nWhen Claude Code streams structured output for the SDK, some messages can now wait until the start-up message has gone out\n\n**Unclear.** What causes a message to be held back is not known.\n\n**What**\n\nWhen Claude Code is driven from a program through the Agent SDK, it writes a stream of structured messages. It can now hold some of those messages back and send them in order around the start-up message that opens the session:\n\n- If the start-up message is sent, held messages follow straight after it.\n\n- If it never arrives, held messages are sent just before the final result.\n\nIf writing a held message fails, Claude Code logs \"held frame write failed\". It also now emits a signal when a control request, a request from the controlling program, is registered.\n\n**Why**\n\nPrograms that read this stream may see messages in a different order than before, with the start-up message coming first.\n\n- Area: SDK\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 2\/5"}