← Back to team overview

ubuntu-appstore-developers team mailing list archive

Re: Translations of metadata

 

On Fri, Jun 21, 2013 at 5:05 PM, Martin Albisetti <
martin.albisetti@xxxxxxxxxxxxx> wrote:

> So, translations. I've been talking a bit with the people closer to
> the potential customers for the Ubuntu Phone, and it seems we will
> need to have a basic i8n story in place after all.
>
> Thinking about the simplest way possible, and since the relevant
> metadata (description, etc) will be entered and live on the server,
> I'd like to explore us just having a simple toggle on the web ui that
> switches between languages and people can type in (or paste) the text
> for each language.
> I'd like to explicitly exclude any automation for metadata
> translations for the moment as that would be much more complex. Also,
> this discussion excludes the actual application's translations.
>
> So, Matias, Ricardo, Michael, James, what would we need to do in order
> to support this both on the MyApps side and on the search index side
> of things?
>


On the MyApps side, we were asked for this once before and lukasz wrote the
multiling app which is still there in trunk. It was until recently hooked
up with Application.description and Application.name, but we checked the
production db and it had zero records, so we pulled it out.

So depending on which metadata you need translated, if it is only a few
fields (name, description etc.) it could/should be straight-forward in
myapps (if those fields are straight attributes of the Application model,
not sure about 1-M fields). But the UI suggestion you've made above makes
it sound like all metadata would be localizable - I've not thought about
that case (and I'm not sure that the multiling helper would be the best
option in that case - it'll create a record per-lang-per-appfield, as
opposed to a record per-lang-per-app), but it sounds initially scary. I'd
think it would be simpler to just have an extra tab/step during the app
creation workflow where you can enter translations for a limited set of
fields (ie. choose a language to add, enter the data and update, later you
can always pull up that language and update etc.).


As for getting that info to the index outside of the pushed changes from
Ricardo's existing work, I've been assuming that some process on the index
will be able to pull:

http://software-center.ubuntu.com/api/2.0/applications/en/ubuntu/any/any/

and populate from that existing data. In the same way that the series and
arch there accept the 'any' value (and so the json includes all available
series/arches in the dict), we could possibly support 'any' for the 'en'
there above, and in that case, include something like:
'translations': {
  'de': {
    'name': 'Das beste spiel',
    'description': 'Whatever'
  },
}

in the output for each app.

Just thoughts - happy to see better alternatives :)

Follow ups

References