mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-11-25 10:25:09 +00:00
fix(api)!: send service and DRM errors as 422, not 502
Cloudflare replaces an origin 502 body with its own page, so clients got "502: Bad gateway" in place of the error and resent each failed licence. BREAKING CHANGE: SERVICE_ERROR and DRM_ERROR now return HTTP 422 instead of 502.
This commit is contained in:
@@ -5123,7 +5123,7 @@ def handle_proxy_license(
|
||||
)
|
||||
|
||||
# A service raises when the upstream licence server rejects the challenge.
|
||||
# Surface it as a structured licence error, not an uncaught 500 the edge turns into a 502.
|
||||
# Surface it as a structured licence error, not an uncaught 500.
|
||||
try:
|
||||
if drm_type == "widevine" and certificate:
|
||||
license_blob = service.get_widevine_service_certificate(
|
||||
|
||||
Reference in New Issue
Block a user