| Comment | File | Size | Author |
|---|---|---|---|
| #31 | 3110296-31.patch | 2.8 KB | longwave |
| #23 | interdiff.3110296.20-23.txt | 8 KB | longwave |
| #23 | 3110296-23.patch | 11.01 KB | longwave |
| Comment | File | Size | Author |
|---|---|---|---|
| #31 | 3110296-31.patch | 2.8 KB | longwave |
| #23 | interdiff.3110296.20-23.txt | 8 KB | longwave |
| #23 | 3110296-23.patch | 11.01 KB | longwave |
Comments
Comment #2
hardik_patel_12 commentedKindly review a patch.
Comment #3
hardik_patel_12 commentedComment #4
longwaveComment #6
longwaveThis is covered in #3104307: Remove BC layers in various Drupal\Core components but it might be easier to break that down into multiple patches, not sure
Comment #7
hardik_patel_12 commentedKindly review a new patch.
Comment #8
hardik_patel_12 commentedComment #9
hardik_patel_12 commented@longwave , let me go through #3104307: [PP-1] Remove BC layers in various Drupal\Core components , and will check how much they have covered and will create patch accordingly . But I fill it's better to create component wise patch because in large patch all component will gone depend on each other. For example if we have successfully removed deprecated code from Access component but if we are facing some issue in other component then Access component code also stuck.
Comment #10
longwaveThis probably doesn't need to be an array now it only has one item.
This comment can be removed now, it's not helpful any more.
Comment #12
hardik_patel_12 commentedwill used by
and first argument is array.So can we can kept in array.
Comment #13
longwaveIt is much simpler to just say this than use array_intersect() on an array with one item:
Comment #14
hardik_patel_12 commentedKindly review a new patch.
Comment #15
hardik_patel_12 commentedComment #17
hardik_patel_12 commentedKindly review a new patch.
Comment #18
hardik_patel_12 commentedComment #20
hardik_patel_12 commentedI have checked logic that $requirement_keys = array_keys($requirements); returns array along with key value format. And if we use $applicable_requirements = '_csrf_request_header_token'; as string then we have to use inArray function to check "_csrf_request_header_token" present or not. So instead of using inArray dunction we can use exisitng array_intersect function which is already used overthere.
Comment #21
hardik_patel_12 commentedComment #23
longwaveComment #24
longwaveThis never used trigger_error() or had a test, are we still OK to remove it?
edit: it is used in contrib: http://grep.xnddx.ru/search?text=cacheUntilEntityChanges&filename=
Comment #25
longwave_access_rest_csrfwas never properly deprecated either and contrib still refers to that too: http://grep.xnddx.ru/search?text=_access_rest_csrf&filename=Comment #26
longwaveAs per @Wim Leers in #3104307-16: Remove BC layers in various Drupal\Core components we must properly deprecate
cacheUntilEntityChanges()and_access_rest_csrffor removal in D10 rather than removing them now in D9.Comment #27
berdirLets check with @catch on that before changing the patch. They have been deprecated for a long time and at least for cacheUntilEntityChanges(), that was fairly visible and drupal-check should be able to report that, the route access check might be different.
We've removed other things without @trigger_error() too.
Comment #28
berdirAnd for example at least one of the found usages of _access_rest_csrf is already broken anyway, because it doesn't define that on a route but checks for it on routes, so that's not going to show that output anymore, the BC layer can't work in that direction.
Comment #29
catchSo I would say ::cacheUntilEntityChanges() is definitely fine to remove. It has @deprecated and a change record. For example it shows up here #3042605: Drupal 9 Deprecated Code Report.
I'm less sure about _access_rest_csrf because there's no way to inform people otherwise, I think we should take that out of the patch and discuss it in a follow-up. Also the runtime support for it is one or two lines.
In both cases we'll need 8.8/8.9 patches to make the deprecation up to current standards - can be separate issues to this one.
Comment #30
longwaveOpened #3111504: Properly deprecate AccessResult::cacheUntilEntityChanges() and #3111506: Properly deprecate _access_rest_csrf route requirement
Comment #31
longwaveRemoved
_access_rest_csrfchanges from the patch. No interdiff as the patch is smaller than the interdiff itself.Comment #32
berdirThanks. This now matches what is in #3104307: Remove BC layers in various Drupal\Core components but that was always meant to deal with leftovers and needs more work and what's done is done.
Comment #33
catchCommitted 9f83de2 and pushed to 9.0.x. Thanks!
Comment #35
catchThanks for opening the spin-offs, committed #3111504: Properly deprecate AccessResult::cacheUntilEntityChanges() to 8.9.x and 8.8.x just before this one.
Comment #36
wim leersNice work here! :)