- Issue created by @znerol
- Merge request !11803Issue #3518527: Deprecate direct access to $_SESSION β (Open) created by znerol
- π¨πSwitzerland znerol
Needs tests for the new deprecation. Also needs a CR for sure.
- First commit to issue fork.
- π«π·France andypost
Applied clean-up and D12, IMO looks RTBC and is not disruptive since D8
- π¨πSwitzerland znerol
In both
SessionTestController
andLegacySessionController
, the method documentation often declared a completely wrong return type:* @return string * A notification message.
Since this MR touches a couple of those methods, I fixed them all.
I agree that deprecating direct access to the
$_SESSION
is not disruptive. However, the next step will be to remove support for custom session keys completely. I.e.,SessionManager
would stop considering custom keys in$_SESSION
when deciding whether to start/save a session automatically.If contrib and custom code continue to access custom keys, this might or might not work depending on other circumstances (i.e., whether or not some unrelated part of the system is using the session as well). But problems will be hard to diagnose because custom keys are silently ignored when the deprecation and support for custom keys are dropped.
That was the reason I think a longer deprecation period could be worthwhile in this case.
- πΊπΈUnited States smustgrave
Letβs see what comes from the decision on the policy if some stuff will be pushed to 13
- πΊπΈUnited States smustgrave
Not sure I see the difference if we are still talking about waiting till 13
- π¨πSwitzerland znerol
That's for 11.3, not 11.2
Right, then there is no need to delay the deprecation, I guess.
- π¬π§United Kingdom catch
See π Defer disruptive 11.3 deprecations for removal until 13.0 Active , the Drupal 13 deprecations would start when the 11.3.x branch is open, which is not yet.
- π«π·France andypost
I find it good to go and let's discus disruption in π Deprecate custom keys in $_SESSION Active
- π«π·France andypost
I mean π Implement Symfony SessionListener Active