Joomla 3.8.0-Dev
I encountered this issue while trying to install Joomla 3.8 with the JoomlaBrowser
https://github.com/joomla-projects/joomla-browser
The following error is visible in the browser if you click the "next" button a second time:
Sure. I added the screenshot to the initial post.
Status | New | ⇒ | Discussion |
Just an addition. I checked the server return. My server had the error level pretty high so I see some notices which break the JSON response:
Notice: Undefined property: stdClass::$min_dev_level in /var/www/eventgallery/tests/joomla-cms3/libraries/src/Updater/Update.php on line 326
Call Stack
# Time Memory Function Location
1 0.2007 385760 {main}( ) .../index.php:0
2 0.2086 1077992 InstallationApplicationWeb->execute( ) .../index.php:32
3 0.2086 1077992 InstallationApplicationWeb->doExecute( ) .../CMSApplication.php:267
4 0.2092 1097856 InstallationApplicationWeb->dispatch( ) .../web.php:200
5 0.2118 1266008 InstallationControllerInstallLanguages->execute( ) .../web.php:161
6 0.2144 1278080 InstallationModelLanguages->install( ) .../languages.php:61
7 0.2196 1436200 InstallationModelLanguages->getPackageUrl( ) .../languages.php:164
8 0.2227 1441848 Joomla\CMS\Updater\Update->loadFromXml( ) .../languages.php:237
9 0.7021 1448488 xml_parse ( ) .../Update.php:483
10 0.7025 1453656 Joomla\CMS\Updater\Update->_endElement( ) .../Update.php:483
( ! ) Notice: Undefined property: stdClass::$max_dev_level in /var/www/eventgallery/tests/joomla-cms3/libraries/src/Updater/Update.php on line 327
Call Stack
# Time Memory Function Location
1 0.2007 385760 {main}( ) .../index.php:0
2 0.2086 1077992 InstallationApplicationWeb->execute( ) .../index.php:32
3 0.2086 1077992 InstallationApplicationWeb->doExecute( ) .../CMSApplication.php:267
4 0.2092 1097856 InstallationApplicationWeb->dispatch( ) .../web.php:200
5 0.2118 1266008 InstallationControllerInstallLanguages->execute( ) .../web.php:161
6 0.2144 1278080 InstallationModelLanguages->install( ) .../languages.php:61
7 0.2196 1436200 InstallationModelLanguages->getPackageUrl( ) .../languages.php:164
8 0.2227 1441848 Joomla\CMS\Updater\Update->loadFromXml( ) .../languages.php:237
9 0.7021 1448488 xml_parse ( ) .../Update.php:483
10 0.7025 1453656 Joomla\CMS\Updater\Update->_endElement( ) .../Update.php:483
Seems like this code is causing the notice messages:
$patchMinimumSupported = $this->get('jversion.dev_level', Version::PATCH_VERSION) >= $this->currentUpdate->targetplatform->min_dev_level;
$patchMaximumSupported = $this->get('jversion.dev_level', Version::PATCH_VERSION) <= $this->currentUpdate->targetplatform->max_dev_level;
```<hr /><sub>This comment was created with the <a href="https://github.com/joomla/jissues">J!Tracker Application</a> at <a href="https://issues.joomla.org/tracker/joomla-cms/17452">issues.joomla.org/tracker/joomla-cms/17452</a>.</sub>
@mbabker I guess this commit causes the issue: wilsonge/joomla-cms@e130087
Hope this helps. Seems like this is actually unrelated to the multilanguage category.
Ya, the isset
checks from the block below the $patchMinimumSupported
variable needs to be added to that line (same for the max).
I can confirm that there are PHP notices shown on a 3.7.4 updated to 3.8.0-beta in the Joomla Update view on "Undefined property: stdClass::$min_dev_level" and other stuff related to the change of the version number variables. So there seems to be something wrong with that on updated systems but as it looks like it does not happen on clean staging installation.
The old constants are still present so that in and of itself is not an issue.
The issue is when processing update XML files that do not have min_dev_level
and max_dev_level
attributes on the targetplatform
tag, the isset check needs to be moved up to be included in the $patch*
variables.
$patchMinimumSupported = !isset($this->currentUpdate->targetplatform->min_dev_level) || Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->min_dev_level
Based on @mbabker suggestion, I tested this patch and do not get errors anymore:
diff --git a/libraries/src/Updater/Adapter/ExtensionAdapter.php b/libraries/src/Updater/Adapter/ExtensionAdapter.php
index 63e3043..b6d645e 100644
--- a/libraries/src/Updater/Adapter/ExtensionAdapter.php
+++ b/libraries/src/Updater/Adapter/ExtensionAdapter.php
@@ -125,11 +125,11 @@
* Check for optional min_dev_level and max_dev_level attributes to further specify targetplatform (e.g., 3.0.1)
*/
- $patchMinimumSupported = Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->min_dev_level;
- $patchMaximumSupported = Version::PATCH_VERSION <= $this->currentUpdate->targetplatform->max_dev_level;
+ $patchMinimumSupported = !isset($this->currentUpdate->targetplatform->min_dev_level) || Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->min_dev_level;
+ $patchMaximumSupported = !isset($this->currentUpdate->targetplatform->max_dev_level) || Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->max_dev_level;
if ($product == $this->currentUpdate->targetplatform['NAME']
&& preg_match('/^' . $this->currentUpdate->targetplatform['VERSION'] . '/', JVERSION)
- && ((!isset($this->currentUpdate->targetplatform->min_dev_level)) || $patchMinimumSupported)
- && ((!isset($this->currentUpdate->targetplatform->max_dev_level)) || $patchMaximumSupported))
+ && $patchMinimumSupported
+ && $patchMaximumSupported)
{
// Check if PHP version supported via <php_minimum> tag, assume true if tag isn't present
diff --git a/libraries/src/Updater/Update.php b/libraries/src/Updater/Update.php
index 5a3dfb0..d342f84 100644
--- a/libraries/src/Updater/Update.php
+++ b/libraries/src/Updater/Update.php
@@ -324,12 +324,12 @@
* Check for optional min_dev_level and max_dev_level attributes to further specify targetplatform (e.g., 3.0.1)
*/
- $patchMinimumSupported = $this->get('jversion.dev_level', Version::PATCH_VERSION) >= $this->currentUpdate->targetplatform->min_dev_level;
- $patchMaximumSupported = $this->get('jversion.dev_level', Version::PATCH_VERSION) <= $this->currentUpdate->targetplatform->max_dev_level;
+ $patchMinimumSupported = !isset($this->currentUpdate->targetplatform->min_dev_level) || Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->min_dev_level;
+ $patchMaximumSupported = !isset($this->currentUpdate->targetplatform->max_dev_level) || Version::PATCH_VERSION >= $this->currentUpdate->targetplatform->max_dev_level;
if (isset($this->currentUpdate->targetplatform->name)
&& $product == $this->currentUpdate->targetplatform->name
&& preg_match('/^' . $this->currentUpdate->targetplatform->version . '/', $this->get('jversion.full', JVERSION))
- && ((!isset($this->currentUpdate->targetplatform->min_dev_level)) || $patchMinimumSupported)
- && ((!isset($this->currentUpdate->targetplatform->max_dev_level)) || $patchMaximumSupported))
+ && $patchMinimumSupported
+ && $patchMaximumSupported)
{
$phpMatch = false;
Would you do the patch please?
will do tmorrow
Just ping me when the PR is ready so I can help with testing.
@svenbluege @AlexRed @richard67
Please test patch #17481
Status | Discussion | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2017-08-11 06:42:43 |
Closed_By | ⇒ | infograf768 |
Can you check the browser's dev console to see if the network request is having any errors or if there's a JavaScript related issue?