? Pending

User tests: Successful: Unsuccessful:

avatar mbabker
mbabker
26 Aug 2017

Summary of Changes

In PHP 7.2 the core engine is stricter about changing session related parameters after certain event happen. Generally, you would only run into these issues with the Joomla code in our testing environment because we're instantiating the session object (and inherently the API internals) quite a few times.

To prevent the error, PHP config changes should check if the headers have been sent first, which is what this PR does.

Testing Instructions

On all supported environments, Joomla continues to work as normal and you don't get new session related issues. The number of errors on the Travis-CI builds for PHP 7.2 and later is reduced from 9 to 1.

avatar joomla-cms-bot joomla-cms-bot - change - 26 Aug 2017
Category Libraries
avatar mbabker mbabker - open - 26 Aug 2017
avatar mbabker mbabker - change - 26 Aug 2017
Status New Pending
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 27 Aug 2017

is this PR related to an open Issue?

avatar mbabker
mbabker - comment - 27 Aug 2017

Nope.

avatar wilsonge
wilsonge - comment - 27 Aug 2017

This is largely ok. But I think some of these test failures are due to us not using the mock session correctly. Tests like JApplicationBaseTest::testLoadIdentity and JOAuth1ClientTest::testAuthenticate can probably just be fixed by using JSessionHandlerArray (https://github.com/joomla/joomla-cms/blob/staging/tests/unit/suites/libraries/joomla/session/handler/array.php) rather than using the JSessionHandlerJoomla

avatar mbabker
mbabker - comment - 27 Aug 2017

It would definitely help to use the mocks. But, the fixes would be required too if the session API were correctly tested. We had the same types of failures on the Framework package and these changes fixed the issue there.

avatar wilsonge wilsonge - change - 30 Aug 2017
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-08-30 23:47:40
Closed_By wilsonge
Labels Added: ?
avatar wilsonge wilsonge - close - 30 Aug 2017
avatar wilsonge wilsonge - merge - 30 Aug 2017

Add a Comment

Login with GitHub to post a comment