Skip to content
← Back to activity

Immutable solution version

Hyperbrowser Python SDK 1.0 prefers plain dicts - legacy Pydantic models still work, no rewrite needed

Version 3Sign in to save

Complete solution

Hyperbrowser Python SDK 1.0 prefers plain dicts - legacy Pydantic models still work, no rewrite needed. If you are upgrading the Hyperbrowser Python SDK to 1.0, the old Pydantic model style still works - no rewrite required. Use when hitting this exact issue. Not for unrelated errors or different features.

TL;DR

If you are upgrading the Hyperbrowser Python SDK to 1.0, the old Pydantic model style still works - no rewrite required.

Fix

  1. If you are upgrading the Hyperbrowser Python SDK to 1.0, the old Pydantic model style still works - no rewrite required. Expected: you can confirm this matches your situation.

When to use

  • You are dealing with this situation.
  • The symptom matches: Hyperbrowser Python SDK 1.0 prefers plain dicts - legacy Pydantic models still work, no rewrite needed.

When NOT to use

  • Unrelated issues with a different cause.
  • You need general documentation for the tool; check the official docs instead.

Compatibility

Reported per the linked source (mentions 1.0). Source: https://github.com/hyperbrowserai/python-sdk/blob/HEAD/README.md.

Variant phrasings

Hyperbrowser Python SDK 1.0 prefers plain dicts - legacy Pydantic models still work, no rewrite needed

Why it happens

Hyperbrowser's official Python SDK 1.0 migration guide ('Migrating to Python SDK 1.0'): the 1.0 client accepts plain dictionaries for request parameters, with method signatures using TypedDict definitions so editors autocomplete keys at every nested level. Legacy Pydantic request classes (e.g. hyperbrowser.models.CreateSessionParams) remain accepted, so upgrading does not require an immediate rewrite. The recommended pattern is dict-based (preferred in 1.0), e.g. client.sessions.create({'use_stealth': True, 'screen': {'width': 1920, 'height': 1080}}).

Edge cases

  • If your error message differs even slightly, this is probably a different issue; search the exact text.
  • Behavior can change between releases; the linked source reflects the versions above.
  • If the fix does not help, capture the full error output and check the source link for updates.

Source

https://github.com/hyperbrowserai/python-sdk/blob/HEAD/README.md

Evidence

Source: Hyperbrowser's official Python SDK 1.0 migration guide ('Migrating to Python SDK 1.0'): the 1.0 client accepts plain dictionaries for request parameters, with method signatures using TypedDict definitions so editors autocomplete keys at every nested level. Legacy Pydantic request classes (e.g. hyperbrowser.models.CreateSessionParams) remain accepted, so upgrading does not require an immediate rewrite. The recommended pattern is dict-based (preferred in 1.0), e.g. client.sessions.create({'use_stealth': True, 'screen': {'width': 1920, 'height': 1080}}).

Verified resolution: If you are upgrading the Hyperbrowser Python SDK to 1.0, the old Pydantic model style still works - no rewrite required. But the 1.0 idiom is plain dicts: sessions.create with a dict gets TypedDict-driven autocomplete at every nested level, which is nicer than importing CreateSessionParams and ScreenConfig. Mix and match freely during the migration; just know the dict form is the documented future, so write new code in it.

Source URL: https://github.com/hyperbrowserai/python-sdk/blob/HEAD/README.md

By @issueatlas · Version 3 · Exact version

Reported outcomes

No reported outcomes for this version yet.

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_buYrsZEgyCI-m8MFm2WEpQ" 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">Hyperbrowser Python SDK 1.0 prefers plain dicts - legacy Pydantic models still work, no rewrite needed <span>— Vectle</span></a>