[{"data":1,"prerenderedAt":321},["ShallowReactive",2],{"blog-\u002Fblog\u002Fopen-claude-agent-sdk-0-50-0":3,"mp-\u002Fblog\u002Fopen-claude-agent-sdk-0-50-0":309,"more-posts-\u002Fblog\u002Fopen-claude-agent-sdk-0-50-0":315},{"id":4,"title":5,"body":6,"category":292,"date":293,"description":294,"draft":295,"extension":296,"meta":297,"navigation":298,"path":299,"project":300,"seo":301,"stem":302,"tags":303,"__hash__":308},"blog\u002Fblog\u002Fopen-claude-agent-sdk-0-50-0.md","open-claude-agent-sdk 0.50.0 fixes broken clean installs",{"type":7,"value":8,"toc":284},"minimark",[9,20,60,67,72,91,98,119,123,170,174,180,196,199,203,206,209,212,216,251,255,269,272,280],[10,11,12,19],"p",{},[13,14,18],"a",{"href":15,"rel":16},"https:\u002F\u002Fgithub.com\u002Ffoksa\u002Fopen-claude-agent-sdk\u002Freleases\u002Ftag\u002Fv0.50.0",[17],"nofollow","open-claude-agent-sdk v0.50.0"," came out on September 19. The headline is a bug fix: from v0.25.0 on, importing the package on a clean install failed with this error:",[21,22,27],"pre",{"className":23,"code":24,"language":25,"meta":26,"style":26},"language-ts shiki shiki-themes github-light github-dark","import { query } from 'open-claude-agent-sdk';\n\u002F\u002F Error: Cannot find package '@anthropic-ai\u002Fclaude-agent-sdk'\n","ts","",[28,29,30,53],"code",{"__ignoreMap":26},[31,32,35,39,43,46,50],"span",{"class":33,"line":34},"line",1,[31,36,38],{"class":37},"szBVR","import",[31,40,42],{"class":41},"sVt8B"," { query } ",[31,44,45],{"class":37},"from",[31,47,49],{"class":48},"sZZnC"," 'open-claude-agent-sdk'",[31,51,52],{"class":41},";\n",[31,54,56],{"class":33,"line":55},2,[31,57,59],{"class":58},"sJ8bj","\u002F\u002F Error: Cannot find package '@anthropic-ai\u002Fclaude-agent-sdk'\n",[10,61,62,63,66],{},"If you only installed this package, without the official SDK next to it, you were affected. The release also brings the API in line with the official ",[28,64,65],{},"@anthropic-ai\u002Fclaude-agent-sdk"," 0.3.276 and fixes several bugs found in a full review of the code.",[68,69,71],"h2",{"id":70},"how-to-upgrade","How to upgrade",[21,73,77],{"className":74,"code":75,"language":76,"meta":26,"style":26},"language-bash shiki shiki-themes github-light github-dark","npm install open-claude-agent-sdk@0.50.0\n","bash",[28,78,79],{"__ignoreMap":26},[31,80,81,85,88],{"class":33,"line":34},[31,82,84],{"class":83},"sScJk","npm",[31,86,87],{"class":48}," install",[31,89,90],{"class":48}," open-claude-agent-sdk@0.50.0\n",[10,92,93,94,97],{},"If you use TypeScript, also add the official SDK as a dev dependency. This package reuses its types but never loads it at runtime, and ",[28,95,96],{},"--omit=optional"," skips its bundled CLI binary:",[21,99,101],{"className":74,"code":100,"language":76,"meta":26,"style":26},"npm install -D @anthropic-ai\u002Fclaude-agent-sdk --omit=optional\n",[28,102,103],{"__ignoreMap":26},[31,104,105,107,109,113,116],{"class":33,"line":34},[31,106,84],{"class":83},[31,108,87],{"class":48},[31,110,112],{"class":111},"sj4cs"," -D",[31,114,115],{"class":48}," @anthropic-ai\u002Fclaude-agent-sdk",[31,117,118],{"class":111}," --omit=optional\n",[68,120,122],{"id":121},"breaking-changes","Breaking changes",[124,125,126,145],"ul",{},[127,128,129,136,137,140,141,144],"li",{},[130,131,132,135],"strong",{},[28,133,134],{},"abort()"," now stops for real."," It rejects the iteration with ",[28,138,139],{},"AbortError"," and kills the CLI, the same as the official SDK. Before, it only sent an interrupt, and you still got a final result. If you want a graceful stop, use ",[28,142,143],{},"q.interrupt()",".",[127,146,147,150,151,154,155,154,158,161,162,165,166,169],{},[130,148,149],{},"Some unsupported helpers are removed:"," ",[28,152,153],{},"startup",", ",[28,156,157],{},"resolveSettings",[28,159,160],{},"filterEscalatingDefaultMode"," and the ",[28,163,164],{},"sessionStore"," helpers. ",[28,167,168],{},"query()"," never supported them.",[68,171,173],{"id":172},"what-was-wrong","What was wrong",[10,175,176,177,179],{},"The package's entry point re-exported a few runtime values, such as ",[28,178,139],{}," and some constants, straight from the official SDK. The official SDK was only a dev dependency, so it wasn't there on a clean install, and the import failed.",[10,181,182,183,154,186,154,189,192,193,195],{},"Those values are now defined in this package. The session helpers (",[28,184,185],{},"listSessions",[28,187,188],{},"getSessionInfo",[28,190,191],{},"forkSession"," and others) are also its own code now instead of re-exports. That fixed two more bugs: ",[28,194,185],{}," returned nothing under Node, and sessions in long project paths were never found. The official SDK is now an optional peer dependency, used for types only.",[10,197,198],{},"To keep this from happening again, CI now packs the package, installs it in an empty project without the official SDK, and imports every entry point under Node.",[68,200,202],{"id":201},"how-it-slipped-through","How it slipped through",[10,204,205],{},"Honestly, I stopped paying close attention. At one point Anthropic decided the Claude Agent SDK could only be used through the API, and after that I lost a lot of my motivation to work on this project.",[10,207,208],{},"It kept going anyway. I have a Claude Code skill that updates the SDK to match each new official release, and for the most part it did the job well. But there was a stretch, around the later Opus 4.6 days and into Opus 4.7, when the models felt noticeably worse to me. They cut corners everywhere. The bug arrived in v0.25.0 on April 24, about a week after Opus 4.7 came out, so my guess is it came from that period: a re-export that looked fine, passed the tests on my machine (where the official SDK was always installed), and nobody double-checked.",[10,210,211],{},"What finally caught it was a full review of the code against the official SDK. That's also why this release has more fixes than usual.",[68,213,215],{"id":214},"other-fixes","Other fixes",[124,217,218,232,241],{},[127,219,220,223,224,227,228,231],{},[130,221,222],{},"Permissions:"," without a ",[28,225,226],{},"canUseTool"," callback, permission requests were quietly ",[130,229,230],{},"allowed",". They now fail, as they do in the official SDK.",[127,233,234,237,238,240],{},[130,235,236],{},"Hangs:"," a ",[28,239,226],{}," or hook callback that called a query method waited forever. It doesn't anymore.",[127,242,243,246,247,250],{},[130,244,245],{},"MCP:"," servers added mid-session with ",[28,248,249],{},"setMcpServers()"," were never registered. Now they are.",[68,252,254],{"id":253},"catching-up-with-the-official-sdk","Catching up with the official SDK",[10,256,257,258,261,262,264,265,268],{},"This release matches official SDK 0.3.276. It adds the ",[28,259,260],{},"projectConfigRoot"," option, passes more detail to ",[28,263,226],{}," callbacks (which MCP server a tool came from, its title and the matching ask rule), and improves how ",[28,266,267],{},"getSessionMessages"," handles messages queued during a tool call and parallel tool calls.",[10,270,271],{},"Each behavior change comes with a test that runs against both this package and the official SDK and compares the results.",[10,273,274,275,144],{},"The full list of changes is in the ",[13,276,279],{"href":277,"rel":278},"https:\u002F\u002Fgithub.com\u002Ffoksa\u002Fopen-claude-agent-sdk\u002Fcompare\u002Fv0.49.0...v0.50.0",[17],"v0.49.0...v0.50.0 comparison",[281,282,283],"style",{},"html pre.shiki code .szBVR, html code.shiki .szBVR{--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}",{"title":26,"searchDepth":55,"depth":55,"links":285},[286,287,288,289,290,291],{"id":70,"depth":55,"text":71},{"id":121,"depth":55,"text":122},{"id":172,"depth":55,"text":173},{"id":201,"depth":55,"text":202},{"id":214,"depth":55,"text":215},{"id":253,"depth":55,"text":254},"release","2026-09-22","Since v0.25.0 the package failed to import unless the official SDK was also installed. 0.50.0 fixes that and catches up with official SDK 0.3.276.",false,"md",{},true,"\u002Fblog\u002Fopen-claude-agent-sdk-0-50-0","open-claude-agent-sdk",{"title":5,"description":294},"blog\u002Fopen-claude-agent-sdk-0-50-0",[304,305,306,307],"typescript","ai","mcp","open source","WtpNmL-O_pqsR3R3ksNTe7ErwWQyK0j8T2WC7sTlfro",{"path":310,"title":300,"description":311,"image":312,"detailImage":313,"imageFit":314,"coverLabel":26},"\u002Fprojects\u002Fopen-claude-agent-sdk","Drop-in, open-source replacement for @anthropic-ai\u002Fclaude-agent-sdk. Readable TypeScript that runs on the Claude CLI you already have installed.","\u002Fimg\u002Fproducts\u002Fopen-claude-agent-sdk-home.webp","\u002Fimg\u002Fproducts\u002Fopen-claude-agent-sdk-detail.webp","contain",[316,317],{"path":299,"title":5,"date":293},{"path":318,"title":319,"date":320},"\u002Fblog\u002Fcamera-video-converter-is-on-play-store","Camera Video Converter is on the Play Store","2026-09-02",1790076223318]