Bump version to 3.8.2

This commit is contained in:
glomatico
2026-07-09 12:32:16 -03:00
parent 62c6c51f74
commit c8e6763a91
4 changed files with 19 additions and 3 deletions
+1 -1
View File
@@ -1 +1 @@
__version__ = "3.8.1"
__version__ = "3.8.2"
+16
View File
@@ -11,6 +11,8 @@ from .exceptions import GamdlApiResponseError
logger = structlog.get_logger(__name__)
TARGET_WRAPPER_API_VERSION = "0.0.2"
T = TypeVar("T")
CredentialsFunc = (
@@ -57,6 +59,7 @@ class WrapperApi:
base_url = base_url.rstrip("/")
me = await cls.get_me(client, base_url)
cls.validate_api_version(me)
if get_credentials_func is not None and me["auth"]["state"] == "logged_out":
username, password = await _invoke(get_credentials_func)
await cls.login(
@@ -67,6 +70,7 @@ class WrapperApi:
get_2fa_code,
)
me = await cls.get_me(client, base_url)
cls.validate_api_version(me)
if me.get("auth", {}).get("state") == "logged_out":
raise GamdlApiResponseError(
@@ -76,6 +80,18 @@ class WrapperApi:
return cls(base_url, decrypt_host, decrypt_port, client, me)
@staticmethod
def validate_api_version(me: dict) -> None:
version = me.get("version")
if version == TARGET_WRAPPER_API_VERSION:
return
raise GamdlApiResponseError(
f"Unsupported wrapper-v2 API version. "
f"gamdl requires wrapper-v2 {TARGET_WRAPPER_API_VERSION}",
content={"detected_version": version},
)
@staticmethod
async def login(
client: httpx.AsyncClient,
+1 -1
View File
@@ -4,7 +4,7 @@ build-backend = "maturin"
[project]
name = "gamdl"
version = "3.8.1"
version = "3.8.2"
description = "A command-line app for downloading Apple Music songs, music videos and post videos."
readme = "README.md"
license = "MIT"
Generated
+1 -1
View File
@@ -223,7 +223,7 @@ wheels = [
[[package]]
name = "gamdl"
version = "3.8.1"
version = "3.8.2"
source = { editable = "." }
dependencies = [
{ name = "async-lru" },