Commit 1ed8611
fix: bind the code-interpreter image type across the openrouter 1.1.40 rename (#27)
openrouter 1.1.40 renamed components.OutputImage to
components.CodeInterpreterImageOutput with no back-compat alias. This package
re-exports that symbol by name from __init__.py and declares
`openrouter>=1.1,<2`, so any resolution at or above 1.1.40 raises ImportError
on `import openrouter_agent` — the whole package, not just the renamed type.
That is the state of the published 0.8.0 wheel today: a plain
`pip install openrouter-agent-sdk` resolves the newest 1.1.x and cannot be
imported. CI missed it because every job except `build` runs through uv.lock,
which pins 1.1.22; `build` installs the wheel unpinned and is the one job that
sees what users get.
Bind whichever name the installed SDK provides. The two models are
structurally identical (type, url) and this package only re-exports the type,
so OutputImage and OutputInputImage stay stable for consumers on both sides of
the boundary.
Verified against 1.1.22, 1.1.39, 1.1.40 and 1.1.90; the full unit suite also
passes against 1.1.90, so the rename was the only incompatibility in the range.
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>1 parent f060a49 commit 1ed8611
2 files changed
Lines changed: 43 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | 42 | | |
44 | 43 | | |
45 | 44 | | |
| |||
235 | 234 | | |
236 | 235 | | |
237 | 236 | | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
238 | 252 | | |
239 | 253 | | |
240 | 254 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
0 commit comments