Simple scan needs to generate a POT template on build

Bug #551470 reported by David Planella on 2010-03-30
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Translations
Medium
Unassigned
simple-scan (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: simple-scan

Simple scan needs to generate a POT template on build for its translatable messages to be exposed in Launchpad.

In this way, on every upload the template will be refreshed in Launchpad. Right now, the template is present (probably a manual upload at some point?), but it's outdated, making it impossible to translate e.g. the Scan (well, Sc_an) message from the Document menu, because it's not in Launchpad.

In the meantime, I'll manually upload the template created from the current package.

For more info on this:

* https://wiki.ubuntu.com/UbuntuDevelopment/Internationalisation/Packaging#Translation%20templates
* https://wiki.ubuntu.com/UbuntuDevelopment/Internationalisation/RecipeVerifyingTranslationUploads

David Planella (dpm) on 2010-03-30
Changed in ubuntu-translations:
status: New → Triaged
importance: Undecided → Medium
Robert Ancell (robert-ancell) wrote :

David, I thought LP was getting the template from bzr (where I checked it in). Is that not working anymore?

Gabor Kelemen (kelemeng) wrote :

That works only for the upstream project, which has the "Sc_an" string (and 107 strings in total):
https://translations.launchpad.net/simple-scan/trunk/+pots/simple-scan/hu/+translate?batch=10&show=all&search=sc_an

The package in Ubuntu however, does not (and this contains only 104 strings in total):
https://translations.launchpad.net/ubuntu/lucid/+source/simple-scan/+pots/simple-scan/hu/+translate?batch=10&show=all&search=sc_an

Robert Ancell (robert-ancell) wrote :

Is it because the simple-scan packaging doesn't have some dpkg magic, e.g.:
/usr/share/cdbs/1/class/gnome.mk
?

Because the simple-scan tarball is exactly the same as any other GNOME project.

David Planella (dpm) wrote :

The template for the Ubuntu package I uploaded manually has now been imported, so we should be covered for now.

However, the Ubuntu package needs to create a POT template on build, so that this template can be imported in the distro space in Launchpad (translations.launchpad.net/ubuntu) and it does not need to be done manually.

> Is it because the simple-scan packaging doesn't have some dpkg magic, e.g.: /usr/share/cdbs/1/class/gnome.mk?

Yeah, it's exactly that. You can either use a CDBS class for that (the langpack rule included in gnome.mk should be enough if you don't need all the rest) or call 'cd po; intltool-update -p' in debian/rules. The only thing necessary for the Ubuntu template to be up-to-date is that the package creates the template while building.

> David, I thought LP was getting the template from bzr (where I checked it in). Is that not working anymore?

As Gabor is explaining, that works fine for the upstream project, but the Ubuntu package needs this one modification to update the template on every upload.

There are currently two sources of translation for simple-scan: upstream and Ubuntu. I acknowledge that this is not optimal, neither from the maintaner nor from the translator point of view, but it is the current situation. There is work being done on this front by the Launchpad Translations team, and soon enough there will be big improvements: better synchronisation between the upstream projects and the Ubuntu source packages, and direct translation import from bzr branches (either native or mirrored) into Ubuntu, instead of import from the packages.

More info: https://wiki.ubuntu.com/Translations/Upstream#Upstream

Robert Ancell (robert-ancell) wrote :

Thanks David, will fix for Lucid+1

David Planella (dpm) wrote :

> Thanks David, will fix for Lucid+1

Robert, just a quick note: would it be possible to fix it for Lucid by simply adding a 'cd po; intltool-update -p' statement to debian/rules or something along these lines? This could then perhaps be refined for Maverick if necessary.

The reason I'm mentioning this is because although we're fine for now with the manual upload, any subsequent package uploads with an outdated template will overwrite whatever is in Launchpad with this outdated template. Actually, if you don't want to touch the debian/rules file, you could perhaps add a patch to include an updated POT file in the package as an alternative.

I'm not sure if it's too late now, but I felt I should mention it. Thanks!

Alessio Treglia (quadrispro) wrote :
Alessio Treglia (quadrispro) wrote :

Ehy folks, can you take a look at the patch above?

What do you think about it?

Robert Ancell (robert-ancell) wrote :

Thanks Alessio! Will apply later today when I release 1.0.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package simple-scan - 1.0.0-0ubuntu1

---------------
simple-scan (1.0.0-0ubuntu1) lucid; urgency=low

  * New upstream release:
    - Don't put dashes in temporary filenames used when emailing to workaround a
      Thunderbird bug
    - Add 32x32 crop icon
    - Don't replace scanner provided on the command-line with detected devices
    - Handle ImageMagick process failing (LP: #539381)
    - Fix incorrect dimensions for A4 and A6 paper (LP: #536882)
  * debian/source_simple-scan.py:
    - Attach versions of SANE driver packages
  * debian/patches/11_thunderbird_workaround.patch:
  * debian/patches/10_save_toolbar_tooltip.patch:
    - Applied upstream

  [ Alessio Treglia ]
  * debian/rules:
    - Call intltool-update to generate a PO template (LP: #551470)
 -- Robert Ancell <email address hidden> Wed, 14 Apr 2010 17:59:28 +0800

Changed in simple-scan (Ubuntu):
status: New → Fix Released
David Planella (dpm) on 2010-08-02
Changed in ubuntu-translations:
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers