By fago on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
2.x
Introduced in version:
2.8.0
Issue links:
Description:
On custom-elements requests, HTML responses are now converted to a 406 Not Acceptable only if they are successful (2xx). Other HTML responses keep their original status code and body.
Before
Every HTML response except redirects was replaced by a cacheable 406 custom-elements response. This included 4xx/5xx responses set without an exception, e.g. the 503 from redirect module's loop detection or maintenance mode, or a 403 set directly. Errors could be cached as 406.
After
- 2xx HTML responses still get a 406.
- Non-2xx responses (4xx, 5xx, and 1xx/3xx other than redirects) pass through with their status and are not made cacheable.
- 403/404 and other HTTP exceptions still get custom-elements error pages. That handling is unchanged.
Impact
API clients may now get an HTML or plain-text body for such error responses instead of a 406 JSON page.
The Nuxt frontend (nuxtjs-drupal-ce) shows its error page with the real status code. No change needed.
Impacts:
Site builders, administrators, editors
Site templates, recipes and distribution developers