can't get translations to update

henkabma

Joined: 2002-12-13
Posts: 15
Posted: Sat, 2009-08-01 21:31

Hello,
When trying to set my language to Nederlands (dutch) and pressing the update button, all I get is a window showing: scanning files.. The progress bar moves to about 15%, and then stops for ever. On my server I see no activity, and the logs show no information. I have tried this yesterday and today, in case the translation servers were down.

Anything I can do or try?

I'm using:
apache 2.2.11
php 5.2.10
gallery3 as pulled yesterday (today there were no updates so far)

Thanks for nay answer.

Kind regards, Henk.

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Mon, 2009-08-03 01:57

I have same problem.

 
bharat
bharat's picture

Joined: 2002-05-21
Posts: 7934
Posted: Mon, 2009-08-03 03:57

Any debug info in your gallery3/var/logs files? If not, try using Wireshark (or tcpdump, tcpflow, ethereal, etc) to watch the TCP traffic and you'll probably see an HTML file with an error go by (which the dialog is eating and not displaying). If you can post that here, we can fix it.
---
Problems? Check gallery3/var/logs
bugs/feature req's | upgrade to the latest code | use git | help! vote!

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Mon, 2009-08-03 10:52

Hello,

This is from my apache log:

192.168.2.15 - - [03/Aug/2009:12:12:43 +0200] "GET /gallery3/index.php/admin/maintenance/start/gallery_task::update_l10n?csrf=4669b504143cd3b41e8d0f0f79b36248 H
TTP/1.1" 200 1884
192.168.2.15 - - [03/Aug/2009:12:12:44 +0200] "GET /gallery3/index.php/admin/maintenance/run/12?csrf=4669b504143cd3b41e8d0f0f79b36248 HTTP/1.1" 200 88
192.168.2.15 - - [03/Aug/2009:12:12:45 +0200] "GET /gallery3/index.php/admin/maintenance/run/12?csrf=4669b504143cd3b41e8d0f0f79b36248 HTTP/1.1" 200 90
192.168.2.15 - - [03/Aug/2009:12:12:45 +0200] "GET /gallery3/index.php/admin/maintenance/run/12?csrf=4669b504143cd3b41e8d0f0f79b36248 HTTP/1.1" 500 -

I assume the 500 error should explain something.

I'm not sure about the right tcpdump switches to use. I tried:

tcpdump -i eth0 -w packets
tcpdum -A -r packets

however that gives incomplete packets that may not be very useful.

gallery3/var/logs doesn' contain anything except for:

2009-08-01 13:55:05 +02:00 --- error: Missing URL reference 'indicator.gif' in CSS file '/var/www/www.showdown.nl/htdocs/gallery3/lib/jquery.autocomplete.css'

which looks unrelated.

Kind regards,

Henk.

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Mon, 2009-08-03 12:50
bharat wrote:
Any debug info in your gallery3/var/logs files?

No.

bharat wrote:
If not, try using Wireshark (or tcpdump, tcpflow, ethereal, etc) to watch the TCP traffic and you'll probably see an HTML file with an error go by (which the dialog is eating and not displaying). If you can post that here, we can fix it.

I attach copy of my tcp stream.

AttachmentSize
tcp stream.txt27.24 KB
 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Mon, 2009-08-03 15:59

Hello,

thattached you fid the output from tcpflow (2 files in the zip). One with the requests made by the cclient, the other with responses from the server.

Hope this helps.

Kind regards,

Henk,

AttachmentSize
debugdata.zip2.06 KB
 
bharat
bharat's picture

Joined: 2002-05-21
Posts: 7934
Posted: Wed, 2009-08-05 01:54

That's pretty odd. I grepped the JSON responses out of the stream and they are:

{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":15,"status":"Scanning files: scanned 34 files","done":0}}
{"result":"in_progress","task":{"percent_complete":15,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Scanning files: scanned 52 files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Scanning files: scanned 52 files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Scanning files: scanned 52 files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Scanning files: scanned 52 files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Scanning files: scanned 52 files","done":0}}
{"result":"in_progress","task":{"percent_complete":18,"status":"Finding files","done":0}}
{"result":"in_progress","task":{"percent_complete":10,"status":"Scanning files","done":0}}

It's weird that the percent_complete is bouncing aronud like that. I thought maybe you ran the task multiple times, but the timestamps are very tightly clustered. I'm guessing this is a bug :-) I can't reproduce it, though. Are you savvy enough to step through the update_l10n() function in modules/gallery/helpers/gallery_task.php to see if you can figure out what's going wrong? If not, are you willing to share ssh access with me so that I can try debugging it?
---
Problems? Check gallery3/var/logs
bugs/feature req's | upgrade to the latest code | use git | help! vote!

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Wed, 2009-08-05 12:15

Found the erorr location and am assuming an error in my php installation:

token_get_all() returns an internal server error, no matter what I send to it. Recompiling php now with the tokenizer use flag (gentoo) enabled, to see if that helps.
..... It did!! So maybe the installer can check for this requirement?

Kind regards,

Henk.

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Wed, 2009-08-05 13:45
henkabma wrote:
Recompiling php now with the tokenizer use flag (gentoo) enabled, to see if that helps.
..... It did!! So maybe the installer can check for this requirement?

I think that this php library have enabled by default.

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Wed, 2009-08-05 14:19

I have checked on two gentoo installations. It looks as if the tokenizer flag is off by default there. On my system with drupal, wordpress, gallery 1, 2, and 3, the function is used in g2 and g3. I have never seen it cause problems on g2, however I don't know if I ever touched the part where it is used. I've seen others report that php says 'undefined function token_get_all()', and maybe that is what it should have done in sted of calling it an internal server error, however that's not gallery's 'fault'.

On the other hand, shouldn't gallery react to error 500?

Kind regards,

Henk.

Henk,

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 22892
Posted: Fri, 2009-08-07 04:16
Quote:
So maybe the installer can check for this requirement?

If G3 had to check every single little nuance of every server/php configuration, there would be 1000s of lines of code just for the installer and there would be little or no code written for the rest of the application.
Some checks are done now, but we are aiming for the 80% that most have.

Quote:
On the other hand, shouldn't gallery react to error 500?

If php dies though a fatal error I don't think that we can detect that other than looking at the servers error log.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16503
Posted: Fri, 2009-08-07 11:26

Yep, that's like a BSOD (Blue Screen of Death) (or a kernel panic in Linux land) there's no stopping it, there's no detecting it. Just checking some logs (hopefully) after the event.
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Fri, 2009-08-07 14:10
nivekiam wrote:
Yep, that's like a BSOD (Blue Screen of Death) (or a kernel panic in Linux land) there's no stopping it, there's no detecting it. Just checking some logs (hopefully) after the event.

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

Hmm? This 500 error is reported back to gallery by apache, so in contrast to a kernel pannic or a sudden death of php, gallery could be aware of a problem occurring, however it chooses to silently ignore it.
My problem is solved now, so I don't care if the installer checks for the tokenizer functions or not, however since they look to be off on gentoo systems by default, a check, a note in a README or some other form of notice could help avoid answering questions like mine.

Kind regards, and thanks for what looks like becoming a wonderful product.

Henk,

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Fri, 2009-08-07 14:59

My problem is not solved yet. My issue is not due to tokenizer because it is enabled by default in Debian based distros.

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 22892
Posted: Sat, 2009-08-08 00:03
Quote:
however since they look to be off on gentoo systems by default, a check, a note in a README or some other form of notice could help avoid answering questions like mine.

Feel free to add a page to to the codex or the G3 faq. The docs are for users like you by users like you.
Perhaps a gentoo specific page would help others? I don't have any experience with that so perhaps you can help?

The README never gets read anyway.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Sat, 2009-08-08 10:44

Thanks, however now i run into a problem:
I found an entry in the faq that mantions gentoo (1.3 some strange things just don't seem to work). When I want to addd the 'tokenizer' flag to this chapter, I have to type text from an image. Unfortunately my sight is too limited to read it. Maybe someone can add the word 'tokenizer' to the faq entry that mentions gentoo (that's the only change needed) .

Thanks!

Henk,

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16503
Posted: Sat, 2009-08-08 13:24

I don't see any image you're referring to. If you're talking about the text on the screen you can make it larger in your browser or change the resolution of your monitor. That FAQ you're referring to is:

Quote:
Perhaps you are using Gentoo? You may need to add the following USE flags and recompile PHP to make this work: filter, json, simplexml

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Sat, 2009-08-08 14:38
nivekiam wrote:
I don't see any image you're referring to. If you're talking about the text on the screen you can make it larger in your browser or change the resolution of your monitor. That FAQ you're referring to is:

Quote:
Perhaps you are using Gentoo? You may need to add the following USE flags and recompile PHP to make this work: filter, json, simplexml

Yes.
http://codex.gallery2.org/Gallery3:FAQ
Since I'm not a frequent contributor I have to type the text in an image (anti-spam check), however I am using braill and speech almost all the time, so enlarging the image doesn't help much ;-).

Kind regards, Henk.

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16503
Posted: Sat, 2009-08-08 15:06

Hi Henk, I understand what you're talking about now. You tried to create an account and update the FAQ and got one of those oh so friendly captcha images. I hate those things.

I've updated the FAQ, let me know if the change I made is correct:
http://codex.gallery2.org/Gallery3:FAQ#Strange_things_just_don.27t_seem_to_work

I'll look into what's being used there for the captcha and see if it can't get swapped out with something more friendly and accessible. The reCaptha project has a text option, it's better, but still leaves much to be desired.

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
henkabma

Joined: 2002-12-13
Posts: 15
Posted: Sat, 2009-08-08 16:18
nivekiam wrote:
Hi Henk, I understand what you're talking about now. You tried to create an account and update the FAQ and got one of those oh so friendly captcha images. I hate those things.

I've updated the FAQ, let me know if the change I made is correct:
http://codex.gallery2.org/Gallery3:FAQ#Strange_things_just_don.27t_seem_to_work

Thanks, this major change is what I had in mind....

Quote:
I'll look into what's being used there for the captcha and see if it can't get swapped out with something more friendly and accessible. The reCaptha project has a text option, it's better, but still leaves much to be desired.

I'll gladly test it, should you find some improvement. Wikipedia has the same problem when you add external links to an article. They appologize for it, but that's all. Google has an audeible version that is usable. Yahoo asks you to leave a note, then never calls back. So thanks for your help.

Kind regards,

Henk.

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Fri, 2009-10-30 05:05

I tried update translations today but this feature doens't work. I found some logs in task page:

Task Päivitä kielikäännökset started (task id 3)
exception 'ErrorException' with message 'unserialize() [<a href='function.unserialize'>function.unserialize</a>]: Error at offset 65520 of 65535 bytes' in /var/www/galleria.laatikko.biz/modules/gallery/models/task.php:22
Stack trace:
#0 [internal function]: gallery_error_Core::error_handler(8, 'unserialize() [...', '/var/www/galler...', 22, Array)
#1 /var/www/galleria.laatikko.biz/modules/gallery/models/task.php(22): unserialize('a:5:{s:4:"mode"...')
#2 /var/www/galleria.laatikko.biz/modules/gallery/helpers/gallery_task.php(123): Task_Model->get('dirs')
#3 [internal function]: gallery_task_Core::update_l10n(Object(Task_Model))
#4 /var/www/galleria.laatikko.biz/modules/gallery/helpers/task.php(81): call_user_func_array('gallery_task::u...', Array)
#5 /var/www/galleria.laatikko.biz/modules/gallery/controllers/admin_maintenance.php(185): task_Core::run('3')
#6 [internal function]: Admin_Maintenance_Controller->run('3')
#7 /var/www/galleria.laatikko.biz/modules/gallery/controllers/admin.php(50): call_user_func_array(Array, Array)
#8 [internal function]: Admin_Controller->__call('maintenance', Array)
#9 /var/www/galleria.laatikko.biz/system/core/Kohana.php(291): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#10 [internal function]: Kohana::instance()
#11 /var/www/galleria.laatikko.biz/system/core/Event.php(209): call_user_func(Array)
#12 /var/www/galleria.laatikko.biz/system/core/Bootstrap.php(55): Event::run('system.execute')
#13 /var/www/galleria.laatikko.biz/index.php(86): require('/var/www/galler...')
#14 {main}
unserialize() [<a href='function.unserialize'>function.unserialize</a>]: Error at offset 65520 of 65535 bytes
 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Sat, 2009-12-12 01:36

I move this gallery to another server. It seems that this problem has disappeared.

 
mrl586

Joined: 2009-05-07
Posts: 30
Posted: Thu, 2010-01-21 01:58

I have translation upgrade problem:

Task Päivitä kielikäännökset started (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
Task Päivitä kielikäännökset resumed (task id 6)
exception 'Exception' with message '@todo TRANSLATIONS_FETCH_REQUEST_FAILED HTTP/1.0 400 Bad Request' in /var/www/www.example.com/modules/gallery/helpers/l10n_client.php:103
Stack trace:
#0 /var/www/www.example.com/modules/gallery/helpers/gallery_task.php(191): l10n_client_Core::fetch_updates()
#1 [internal function]: gallery_task_Core::update_l10n(Object(Task_Model))
#2 /var/www/www.example.com/modules/gallery/helpers/task.php(81): call_user_func_array('gallery_task::u...', Array)
#3 /var/www/www.example.com/modules/gallery/controllers/admin_maintenance.php(189): task_Core::run('6')
#4 [internal function]: Admin_Maintenance_Controller->run('6')
#5 /var/www/www.example.com/modules/gallery/controllers/admin.php(50): call_user_func_array(Array, Array)
#6 [internal function]: Admin_Controller->__call('maintenance', Array)
#7 /var/www/www.example.com/system/core/Kohana.php(330): ReflectionMethod->invokeArgs(Object(Admin_Controller), Array)
#8 [internal function]: Kohana_Core::instance(NULL)
#9 /var/www/www.example.com/system/core/Event.php(208): call_user_func_array(Array, Array)
#10 /var/www/www.example.com/application/Bootstrap.php(67): Event_Core::run('system.execute')
#11 /var/www/www.example.com/index.php(90): require('/var/www/www...')
#12 {main}
@todo TRANSLATIONS_FETCH_REQUEST_FAILED HTTP/1.0 400 Bad Request
 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Fri, 2010-01-22 09:22

Please git pull / get the latest dev version and try again.

See:
http://github.com/gallery/gallery3/commit/120c9c749e175cc6c67ae628ee1a8a967a8ddbcc