User tests: Successful: Unsuccessful:
Copy description from http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=34035&start=0
Errors uninstalling partially a package & reinstallint it (see how to reproduce) :
Into the Backend you will have the Warning messages :
Warning
JFolder: :files: Path is not a folder. Path: /administrator/components/com_mycomponent
JFolder: :files: Path is not a folder. Path: /administrator/components/com_ mycomponent
JInstaller: :Install: Cannot find XML setup file
JFolder: :files: Path is not a folder. Path: /components/com_ mycomponent
JFolder: :files: Path is not a folder. Path: /components/com_ mycomponent
JInstaller: :Install: Cannot find XML setup file
And into the apache error log :
Warning: array_unique() expects parameter 1 to be array, null given in \site-joomla33\libraries\cms\installer\installer.php on line 1873, referer: http://localhost/site-joomla33/administrator/index.php?option=com_installer
Have a Joomla package with a component and plugin
Uninstall the component ‘only’ (not the package) using Extensions/Manager (you will keep the package and plugin)
Reinstall the whole package (which include the extension: component & plugin)
You will have the error (displayed & error log)
Title |
|
Title |
|
||||||
Labels |
Added:
?
?
|
Title |
|
3 proposals
*With transtipage
Into the merge
$xmlfiles = array_unique(array_merge((array)$parentXmlfiles, (array)$allXmlFiles)) : false;
Or better when setting the 2 variables
$parentXmlfiles = (array) JFolder::files($this->getPath('source'), '.xml$', false, true);
$allXmlFiles = (array) JFolder::files($this->getPath('source'), '.xml$', 1, true);
Let me know which of the 3 solutions is your favorite, or may be another one.
I'd use
$parentXmlfiles = (array) JFolder::files($this->getPath('source'), '.xml$', false, true);
$allXmlFiles = (array) JFolder::files($this->getPath('source'), '.xml$', 1, true);
It actually looks like JFolder::files()
has a bug in that it returns false
when it fails. It should always return an array according to docblock (http://api.joomla.org/cms-3/classes/JFolder.html#method_files).
So may be it's better to fix it ? and change into /libraries/joomla/filesystem/folder.php line 510
return false;
with
return array();
no (but risk of compatibility if there some test with null instead of empty(), I didn't found but ... ) ?
Imho, it would be the best fix. There is a small backward compatibility risk if someone explicitely checks for false
. However I'd say most developers just use a boolean check or empty()
and that would give the same result with an empty array.
Title |
|
Title |
|
deleted the @ into libraries/cms/installer/installer.php
return array() into /libraries/joomla/filesystem/folder.php line 510
I like that! Thanks!
Title |
|
||||||
Labels |
Removed:
?
|
Status | New | ⇒ | Pending |
Title |
|
Title |
|
Category | ⇒ | Installation Libraries Updating |
Title |
|
The actuel status for this error is 'pending' Error (into red)! Is there anything to do?
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/4057.
Try adding good testing instructions so people know how and what to test.
Hi, the question was: what is the cause of Error — 'The Travis CI build could not complete due to an error · Details', (this is 'new') how to fix it?
For the error itself you said about 2 months ago 'I like that! Thanks!'. If you want more or something else, please details ('due to an error' is not really detailles) !!) (reproduce the issue is simple & I can't explain more: see the original text). Else close the case and keep the issue!?
Guess that the problem with travis is not to do with your PR. Haven't been able to find how to restart is on your PR. It should be possible, but nobody cares to document it. The only way I know is changing something to your PR.
In my opinion your PR can't be accepted because it breaks BC. Suggest you find a better solution for the issue than breaking BC. Considering the original issue is an administrator doing something wrong, suggest you find a solution to stop him making that mistake. Document the manual labour once you made the mistake. Nothing against making Joomla more robust, but only in a BC way!
OK it's more efficient, to say it instead if change a status!
So for the issue, back to my 2° proposal with:
$parentXmlfiles = (array) JFolder::files($this->getPath('source'), '.xml$', false, true);
$allXmlFiles = (array) JFolder::files($this->getPath('source'), '.xml$', 1, true);
ok ?
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/4057.
Ah sorry, misunderstood then.
Usually you can retrigger Travis by adding a new commit. Maintainers can also do it on Travis itself.
I just did that but it still errors. But it's indeed unrelated to your PR except that the branch likely is outdated by now.
As for the fix, personally I would merge it since I don't think it will cause an issue. However since I suggested the fix, I let someone else decide on that :)
I added the issue description from JoomlaCode to the intial PR.
Hi guy,
I could not test this issue. I tried the testing instructions with the packages K2_v2.6.9, virtuemart.3.0.9 and jce_252 on joomla 3.4.4 dev, but I did not have any error. May be you can tell us with which package you tested it. It could be that this issue have been already treated on the core.
Status | Pending | ⇒ | Information Required |
For the test, you need to use a Joomla package witch use the Joomla mechanism for the package to install the component, plugin, component... referenced into the xml file (for the package), not installing a first component, which install itself the plugin like K2.
Take a look at: Zoo, BS MyJspace for example.
Hello
We have tested installing and uninstalling both packages the Zoo and the BS MySpace package. In both cases the installation and uninstall goes allright. We couldn't encounter the errors related to JFolder and Jinstaller. Looking at the history of this issue I see it started in aug 2014.
The Joomla version is 3.5.0 beta. Probably this error is fixed in meantime
Hello
We have tested installing and uninstalling both packages the Zoo and the BS MySpace package. In both cases the installation and uninstall goes allright. We couldn't encounter the errors related to JFolder and Jinstaller. Looking at the history of this issue I see it started in aug 2014.
The Joomla version tested on is 3.5.0 beta. Probably this error is fixed in meantime
Status | Information Required | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2015-12-12 13:30:54 |
Closed_By | ⇒ | roland-d |
@b92 Thank you for your contribution. As there have been multiple tests that can no longer confirm the issue and it is an older PR, I am going to close this PR. If you feel the issue still exists, feel free to open this PR with updated information.
Title |
|
Title |
|
I don't like having errors suppressed in the code. There must be a better way doing that.