Closed (duplicate)
Project:
Localization server
Version:
5.x-1.x-dev
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
13 Nov 2007 at 23:13 UTC
Updated:
18 Jan 2010 at 14:08 UTC
Jump to comment: Most recent file
Comments
Comment #1
psicomante commentedI missed to say that this bug breaks some file translation.
Comment #2
gábor hojtsyHm, strings recorded being on the 0.th line are:
- javascript strings, but this does not seem to be applicable here (would need a .js extension)
- .info files strings (again, would need .info extension)
- the file name itself (this is suspicious, but reused so many times in potx, that I don't think that this is the problem)
- special stuff, such as date formats, but only for common.inc which is again not a case here
I also looked into abuse.module and there are indeed very bad t() usage in this module, such as
t('Warn and '. ucfirst($op)). Although none of these should cause empty strings to be recorded, or least not under normal operation.Also downloaded the HEAD code of abuse.module, run the potx-cli.php script on it, and cannot reproduce the empty string.
Seems like we need more information.
Comment #3
gábor hojtsyBTW just as I closed my abuse.module CVS window, I realized it has a custom permission "handling system" (ie. uses constants instead of literal strings for permission names). But looking at the potx implementation, this should not be a problem. What is the exact version of the abuse.moduel causing these problems?
Comment #4
gábor hojtsyBTW I just committed an error condition report to the 6.x-2-dev version of potx which throws an error for such hook_perm() implementations (will probably backport to Drupal 5 later, see http://hojtsy.hu/blog/2007-nov-15/make-jump-ensure-your-drupal-modules-a...). Although I clearly believe that this should not cause empty strings appearing in the .pot.
Comment #5
psicomante commentedOk, i installed a l10n_server on a clean drupal installation.
I downloaded l10n_server (the last version, updated today), and potx (updated yesterday). I used the local_community module.
I downloaded abuse-5.x-dev.tar.gz. Put it in files folder. Scanned.
Strings: 100.
Empty Strings: 0.
I imported the italian translation => Empty strings: 0. It seems i can't reproduce anymore that bug!
Comment #6
psicomante commentedLocal Test: OK
Modules used: l10n_community, l10n_localepackages, potx
Module parsed: abuse-5.x-dev.
Strings Extracted: 100.
PHP: 5.2.2
MySQL: 5.0.41
Server: Apache/2.2.4 (Ubuntu) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.2
ModRewrite: Enabled
===========
Online (Hoster) Test: NOK (It misses some strings)
Modules used: l10n_community, l10n_localepackages, potx
Module parsed: abuse-5.x-dev.
Strings Extracted: 98
PHP: 5.1.2
MySQL: 5.0.38
Server: Apache/2.0.55 (Ubuntu) DAV/2 SVN/1.3.1 mod_ssl/2.0.55 OpenSSL/0.9.8a mod_perl/2.0.2 Perl/v5.8.7
The two not translated in "online" server are
Local server:
abuse-module.pot
#: abuse.module:0
msgid "abuse"
msgstr ""
wathlist-module.pot
#: watchlist.module:0
msgid "watchlist"
msgstr ""
Online server:
Those strings don't exist. L10n_server adds too an empty string, not extracted and misse a string from watchlist.module.
Both placed at bottom of po/pot files.
Same issue on admin-message project.
Comment #7
gábor hojtsyOK, so this is due to the import misbehaving. That's news :) I'll look into this later.
Comment #8
psicomante commentedi was wrong Gàbor, i had been edited the message (i hope this is meaningful!!). I thought that the problem was in importing translations, but i was in error.
Comment #9
gábor hojtsyPsicomante: could you please post follow ups instead of modifying what I got in the mail / I already answered... Duh.
How does this empty string look in the database? How is this "not extracted"? What string is "misse"?
Comment #10
psicomante commentedSorry Gàbor.
Comment #11
gábor hojtsyFrom the l10n_community_line data, it shows that sid 8 is recorded from fid (file) 1 on line 0. File 1 is
(1, 1, 'admin_message/admin_message.module', 'admin_message.module,v 1.1.2.2 2007/07/27 07:26:56 fajerstarter'),which is code: http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/admin_messa... I looked though this, but have no idea what might cause that empty string. Is still still happening in latest l10n_server?Comment #12
hass commentedhttp://drupal.org/node/231444 could be a duplicate of this... :-(
Comment #13
meba commentedCan you please check with 6.x-dev version of l10n_server?
Comment #14
gábor hojtsyThis was handled in #582008: Empty source strings should not be stored.