This may need more research, but based on discussion in #2931883: Unneeded always_populate_raw_post_data requirements check while on CLI the REST module's always_populate_raw_post_data requirement check is possibly not necessary.
And at least, it appears to enforce a solution to the problem that may not be the best one (see #2931883-11: Unneeded always_populate_raw_post_data requirements check while on CLI).
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 2940417-2.patch | 1.19 KB | David_Rothstein |
Comments
Comment #2
David_Rothstein commentedHere is a patch for discussion purposes if nothing else.
Comment #3
David_Rothstein commentedComment #4
wim leersComment #5
wim leersI'd be tempted to stick to what we have for now and then remove this once Drupal 8 requires PHP 7, i.e. in Drupal 8.7 (see https://groups.drupal.org/node/518200). Minimize change for what clearly is a buggy edge case.
Comment #6
wim leersBased on #2485847: Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version, which #2456025-30: PHP warnings in PHP 5.6 because of always_populate_raw_post_data ini setting pointed to, this is necessary not just for REST but even just using
install.php, i.e. necessary to be able to install D8 on certain hosting environments.Therefore moving this to D9.
Comment #7
wim leersIncorporated the removal of
rest_requirements()in #2893804 — see #2893804-24: Remove rest.module BC layers.