? Success

User tests: Successful: Unsuccessful:

avatar mbabker
mbabker
4 Apr 2016

Summary of Changes

This PR proxies the phputf8 library files located at libraries/phputf8 to their counterparts at libraries/vendor/joomla/string/src/phputf8 and removes all of the declared functions from these files. Short of someone including this library themselves in yet another location, this should solve any reports dealing with its functions being redeclared.

Testing Instructions

To validate the proxy, add the following line to your template's index.php file:

require_once JPATH_PLATFORM . '/phputf8/mbstring/core.php';

This will import the file from the old location and should cause a deprecation log message telling you to use the new location.

Otherwise as there are no core uses of the old file path, things should just work.

Why class_exists() Checks on Logging?

This is a third party API and is 100% usable outside the context of Joomla. The class_exists() checks keep it this way.

avatar mbabker mbabker - open - 4 Apr 2016
avatar mbabker mbabker - change - 4 Apr 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 4 Apr 2016
Labels Added: ?
avatar andrepereiradasilva andrepereiradasilva - test_item - 4 Apr 2016 - Tested successfully
avatar andrepereiradasilva
andrepereiradasilva - comment - 4 Apr 2016

I have tested this item :white_check_mark: successfully on ccfad9a

Applied patch, turned debug on (in system config), turned debug plugin on with deprecated logs.
Edit a category, then edit a content.
Checked logs/deprecated.php and there are Using the phputf8 library through ... deprecated messages there.

So, tested successfully.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar brianteeman brianteeman - change - 5 Apr 2016
Category External Library Libraries
avatar brianteeman brianteeman - test_item - 5 Apr 2016 - Tested unsuccessfully
avatar brianteeman
brianteeman - comment - 5 Apr 2016

I have tested this item :red_circle: unsuccessfully on ccfad9a

Applied patch, turned debug on (in system config), turned debug plugin on with deprecated logs.
Edit a category, then edit a content.
Checked logs/deprecated.php and there are Using the phputf8 library through ... deprecated messages NOT there.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar andrepereiradasilva
andrepereiradasilva - comment - 5 Apr 2016

@brianteeman how did you have phputf8 messages in the deprecated.php log and they are not deprecated messages?!

Don't you have something like this?
2016-04-04T16:04:32+00:00 WARNING ::ffff:XXX.XXX.XXX.XXX deprecated Using the phputf8 library through files located in /path/to/joomla-staging/libraries/phputf8 is deprecated, load the files from /path/to/joomla-staging/libraries/vendor/joomla/string/src/phputf8 instead.

avatar brianteeman
brianteeman - comment - 5 Apr 2016

No - I will test again

On 5 April 2016 at 11:20, andrepereiradasilva notifications@github.com
wrote:

@brianteeman https://github.com/brianteeman how did you have phputf8
messages in the deprecated.php log and they are not deprecated messages?!

Don't you have something like this?
2016-04-04T16:04:32+00:00 WARNING ::ffff:XXX.XXX.XXX.XXX deprecated Using
the phputf8 library through files located in
/path/to/joomla-staging/libraries/phputf8 is deprecated, load the files
from /path/to/joomla-staging/libraries/vendor/joomla/string/src/phputf8
instead.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#9731 (comment)

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar brianteeman
brianteeman - comment - 5 Apr 2016

Tested again - enabled deprecated logging
Applied patch
Edit article
Edit category
Nothing about utf8 in deprecate log

avatar brianteeman
brianteeman - comment - 5 Apr 2016

Sorry for confusion my first message should have said there are NO....

avatar polakluk
polakluk - comment - 5 Apr 2016

I just tested this PR on my localhost and it is working :white_check_mark: . In my depreciated.php log, I can see the line advising users to load phputf8 from composer directory.

test

avatar mbabker
mbabker - comment - 5 Apr 2016

@brianteeman If you have #9704 applied also that would cause log messages to not show. The web application's redirect method is direct importing from the libraries/phputf8 directory without that PR applied, so even if you're not getting the log messages but still able to navigate the UI when redirects happen this is "working", just can't explain why you're not getting the log messages.

avatar brianteeman
brianteeman - comment - 5 Apr 2016

No i dont have 9704 applied

avatar joomla-cms-bot
joomla-cms-bot - comment - 8 Apr 2016

This PR has received new commits.

CC: @andrepereiradasilva, @brianteeman


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar mbabker mbabker - change - 19 Apr 2016
The description was changed
avatar mbabker mbabker - change - 19 Apr 2016
The description was changed
avatar mbabker
mbabker - comment - 19 Apr 2016

With #9704 merged testing instructions are changed.

avatar andrepereiradasilva andrepereiradasilva - test_item - 19 Apr 2016 - Tested successfully
avatar andrepereiradasilva
andrepereiradasilva - comment - 19 Apr 2016

I have tested this item :white_check_mark: successfully on 449ceb7

Fatal error: Cannot redeclare utf8_strlen() (previously declared in /path/to/joomla-staging/libraries/vendor/joomla/string/src/phputf8/mbstring/core.php:23) in /path/to/joomla-staging/libraries/phputf8/mbstring/core.php on line 28

With patch in deprecated.php log (global config debug = yes; debug plugin enabled with all logging)

2016-04-19T15:32:07+00:00 WARNING [...] deprecated Using the phputf8 library through files located in /path/to/joomla-staging/libraries/phputf8 is deprecated, load the files from /path/to/oomla-staging/libraries/vendor/joomla/string/src/phputf8 instead.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar mbabker
mbabker - comment - 2 May 2016

@joomla/cms-maintainers this becomes more urgent to merge with the String package bumped to 1.4.0 because of autoloading of several of its files by the Framework's autoload definition.

avatar brianteeman brianteeman - test_item - 4 May 2016 - Tested successfully
avatar brianteeman
brianteeman - comment - 4 May 2016

I have tested this item :white_check_mark: successfully on 449ceb7

Tried again and tested ok - no idea what I did wrong before


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar brianteeman brianteeman - change - 4 May 2016
Status Pending Ready to Commit
avatar brianteeman
brianteeman - comment - 4 May 2016

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9731.

avatar joomla-cms-bot joomla-cms-bot - change - 4 May 2016
Labels Added: ?
avatar brianteeman brianteeman - change - 4 May 2016
Milestone Added:
avatar rdeutz rdeutz - change - 4 May 2016
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2016-05-04 14:32:22
Closed_By rdeutz
avatar rdeutz rdeutz - close - 4 May 2016
avatar rdeutz rdeutz - merge - 4 May 2016
avatar joomla-cms-bot joomla-cms-bot - close - 4 May 2016
avatar joomla-cms-bot joomla-cms-bot - change - 4 May 2016
Labels Removed: ?

Add a Comment

Login with GitHub to post a comment