? Success

User tests: Successful: Unsuccessful:

avatar waader
waader
24 Oct 2014

I installed the current staging branch using postgresql successfully. Afterwards I tried to install an additional language in the backend but it failed with the following message:

0 Database query failed (error # %s): %s SQL=SELECT "update_id" FROM "aehqu_updates" WHERE element = 'de-DE' AND type = 'language' AND client_id = '' AND folder = ''

After applying this patch the installation went fine. I borrowed the idea from #1695.

avatar waader waader - open - 24 Oct 2014
avatar jissues-bot jissues-bot - change - 24 Oct 2014
Labels Added: ?
avatar Bakual
Bakual - comment - 24 Oct 2014

I think the issue comes from the fact that we didn't define a default value in the table for the client_id. But your patch will work as well.

avatar wilsonge
wilsonge - comment - 24 Oct 2014

I was wondering if we could remove the folder as well. It doesn't give an issue in postgres however it seems unnecessary.

test: patch works as expected!

@infograf768 any opinions?

avatar wilsonge wilsonge - test_item - 24 Oct 2014 - Tested successfully
avatar wilsonge
wilsonge - comment - 25 Oct 2014

Note testers need to test with staging rather than 3.3.6 so that another unrelated fix for postgres is applied.

avatar infograf768
infograf768 - comment - 27 Oct 2014

Tested the patch on mysqli:
Install new pack is fine
Update pack is fine too.
Can't test on postgres here.
@wilsonge What do you mean by "I was wondering if we could remove the folder as well."

avatar wilsonge
wilsonge - comment - 27 Oct 2014

I just meant about the 'folder' => ''

Doesn't matter. Let's just get this merged!

avatar wilsonge wilsonge - change - 27 Oct 2014
Category Postgresql
avatar wilsonge wilsonge - change - 27 Oct 2014
Status Pending Ready to Commit
avatar wilsonge
wilsonge - comment - 27 Oct 2014

RTC

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

avatar wilsonge wilsonge - alter_testresult - 27 Oct 2014 - infograf768: Tested successfully
avatar Bakual Bakual - close - 27 Oct 2014
avatar Bakual Bakual - change - 27 Oct 2014
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2014-10-27 10:18:14
avatar sovainfo
sovainfo - comment - 27 Oct 2014

You can see from line 378 what it should have been, for those interested in doing the right thing!

avatar infograf768
infograf768 - comment - 27 Oct 2014

The whole file is weird imho.
It contains some older 1.5 stuff (see the pdf fonts)
At the time this file was created (2009), we were still installing languages by folder and not as packs.

Looking at the _update table, one will see we now only use packs and not language zips per client.
The client is always 0 in the table and the folder is empty.
As you may know we forbid uninstalling languages, we only allow uninstalling language packs.

Technically I guess some one "could" install a site only or admin only language with some update server and that the client would be necessary. This confusion needs indeed clarification.

avatar wilsonge
wilsonge - comment - 27 Oct 2014

I did see 378 actually. Both lines were introduced at the same time as this both containing different codes (yes I did track this back before the PR to check because I saw that line) joomla/joomla-platform@78828a1#diff-4adc3c570aaac147ab74a2ad37f06b64R221

For that reason and not knowing what the original intention my opinion was that we should keep things as close together as possible.

If we want to do a larger refactoring then it should be done in a separate PR

avatar sovainfo
sovainfo - comment - 27 Oct 2014

Suggest to have install and update at least the same.
Surprised to see the update removed upon installation despite the type being package instead of language.
Line 378 proves the folder criteria is redundant. Suspect the client_id to be redundant as well.
Also expect the version to be checked, both on install and update. Updates should only be removed when the same or more recent version is installed.

Agree that this also should be done for file and component, in separate PR's. Don't see the need for folder, only used for plugins. Don't see a need to check on client_id if not appropriate.

Add a Comment

Login with GitHub to post a comment