mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2026-08-19 01:15:04 -05:00
The biganimal cloud-deployment module pickled the live BigAnimalProvider across 15 sites (verify, polling-for-token, projects, providers, regions, db_types, db_versions, instance_types, volume_types, volume_properties, deploy). Same pattern, same risk as the other cloud providers. Add BigAnimalProvider.to_state()/from_state() and _get_biganimal_from_session()/_save_biganimal_to_session() helpers. from_state uses cls.__new__(cls) to bypass __init__'s get_auth_provider() HTTP call -- the persisted `provider` dict already holds that data. Five new tests cover: round-trip preservation, helper construction, defaults for partial state, missing-session graceful return, and a regression assertion that pickle is gone.