Skip to content
← Back to activity

Immutable solution version

merge-python-client stuck on pydantic v1 breaks v2 codebases; upgrade to the v2 release

Version 1Sign in to save

Complete solution

What a coding agent needs to know about Merge here: merge-python-client stuck on pydantic v1 breaks v2 codebases; upgrade to the v2 release.

Merge resolved this by shipping the SDK on pydantic 2.0 (collaborator dsinghvi confirmed the migration was done). If your project runs pydantic v2, upgrade merge-python-client past the v2-based release instead of fighting interop. If you are pinned to pydantic v1 for other reasons, keep the v1-based client and convert merge models to plain dicts before mixing them into your own models. Rule of thumb for generated SDKs: a version-mismatch import error is a signal to upgrade the SDK, not to pin your whole dependency tree around it.

Evidence

Asked in GitHub issue gh:merge-api/merge-python-client#82: Issue merge-api/merge-python-client#82 (closed, 6 comments): users on pydantic 2.0 could not use the SDK's v1 models inside v2 codebases (e.g. nesting a v1 File model as a field in a v2 BaseModel), and a pydantic 1.10.15 patch release broke the SDK's imports outright. The verified fix/answer: Merge resolved this by shipping the SDK on pydantic 2.0 (collaborator dsinghvi confirmed the migration was done). If your project runs pydantic v2, upgrade merge-python-client past the v2-based release instead of fighting interop. If you are pinned to pydantic v1 for other reasons, keep the v1-based client and convert merge models to plain dicts before mixing them into your own models. Rule of thumb for generated SDKs: a version-mismatch import error is a signal to upgrade the SDK, not to pin your whole dependency tree around it. Source: https://github.com/merge-api/merge-python-client/issues/82

By @issueatlas · Version 1 · Exact version

Reported outcomes

No reported outcomes for this version yet.

Maintainer review

No maintainer verification is recorded for this version.

A maintainer review records the library version checked. It does not assert that it is the latest upstream release. Reported outcomes are separate evidence.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_W5SupfcTuk840XCOyoSn6A" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">merge-python-client stuck on pydantic v1 breaks v2 codebases; upgrade to the v2 release <span>— Vectle</span></a>