No Code Attached Yet
avatar DebasisDa
DebasisDa
24 Jan 2023

Steps to reproduce the issue

Install joomla application (4.2.6/ 3.10.11) with php 8.1

Expected result

No error message

Actual result

Error : Deprecated: md5(): Passing null to parameter #1 ($string) of type string is deprecated in /home/bVOWdNvW/iibcdegf-1674533169466.stackwaysapps.com/public_html/libraries/src/Cache/CacheStorage.php on line 100

System information (as much as possible)

Additional comments

avatar DebasisDa DebasisDa - open - 24 Jan 2023
avatar joomla-cms-bot joomla-cms-bot - change - 24 Jan 2023
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 24 Jan 2023
avatar harsitagarwalla187
harsitagarwalla187 - comment - 25 Jan 2023

I am new to here. Could you please elaborate what type of changes should i make. I have setup it locally.

Screenshot 2023-01-25 211621

avatar alikon
alikon - comment - 25 Jan 2023

reading the issue, the problem should arise on this line and not where you are looking
https://github.com/joomla/joomla-cms/blob/4.2-dev/libraries/src/Cache/CacheStorage.php#L100

avatar harsitagarwalla187
harsitagarwalla187 - comment - 26 Jan 2023

@alikon Is it the right way ?
md5($app->get('secret') ?? ' ' )

avatar alikon
alikon - comment - 26 Jan 2023

did you have been able to replicate the issue ?

btw
$app->get('secret',' ') sounds better imho

avatar harsitagarwalla187
harsitagarwalla187 - comment - 26 Jan 2023

did you have been able to replicate the issue ?
No but by doing some research i found that the newer version of PHP doesn't allow null as parameters implicitly.
btw $app->get('secret',' ') sounds better imho
Should i make the PR.

avatar alikon
alikon - comment - 26 Jan 2023

yes please
better you should do 2 pr
1 x 4
1 x 3
?

avatar harsitagarwalla187
harsitagarwalla187 - comment - 26 Jan 2023

@alikon Sorry, I am confused. Can you please tell me what you mean by two PR and also by 1x4 and 1x3?

avatar alikon
alikon - comment - 27 Jan 2023

as per issue

(4.2.6/ 3.10.11) with php 8.1

you need a pr for j4 branch as you already did #39720
and one pr for for j3 branch

avatar laoneo
laoneo - comment - 30 Jan 2023

We don't need a pr for the 3 branch as we didn't fix the 8.x deprecation's there.

avatar HLeithner HLeithner - change - 30 Jan 2023
Status New Closed
Closed_Date 0000-00-00 00:00:00 2023-01-30 08:11:03
Closed_By HLeithner
avatar HLeithner HLeithner - close - 30 Jan 2023
avatar HLeithner
HLeithner - comment - 30 Jan 2023

Closed since we have a pr #39720 Joomla 3 will not be patched for php 8.1

Add a Comment

Login with GitHub to post a comment