[openstack-dev] [sahara][horizon] translation support in sahara-dashboard and INSTALLED_APPS

Chad Roberts croberts at redhat.com
Mon Feb 22 13:53:16 UTC 2016


My best guess is that the current setting for INSTALLED_APPS wound-up being
derived from the slightly nomadic history (moving from its own repo, then
into horizon, then into contrib, then back to its own repo).  I most likely
didn't think much it other than to shorten the way that we reference our
templates.
I will take a look at your patch (thanks).  Looks like the tests all
passed, so I suspect it will be just fine for us.  Thanks for the
explanation too.  Your help is always welcomed.

Chad

On Sun, Feb 21, 2016 at 12:22 PM, Akihiro Motoki <amotoki at gmail.com> wrote:

> Hi sahara-dashaboard team (perhaps horizon and sahara dev team),
>
> I am working on translation support in sahara-dashboard for feature
> parity of Liberty horizon.
>
> TL;DR: Why does not sahara-dashboard use 'sahara_dashboard' as
> INSTALLED_APPS?
> Can't we add 'sahara_dashboard' as INSTALLED_APPS?
>
> Long version:
>
> sahara-dashboard now uses
>
>   ADD_INSTALLED_APPS = \
>       ["sahara_dashboard.content.data_processing",
>        "sahara_dashboard.content.data_processing.clusters", ]
>
> instead of 'sahara_dashboard' as most horizon plugins do.
>
> On the other hand, the translation setup infra scripts uses
> sahara_dashboard.locale as the locale directory
> and django searches $apps/locale for each directory specified in
> $INSTALLED_APPS.
>
> To make translation work for sahara-dashboard, we need to place the
> 'locale' directory
> in one of $INSTALLED_APPS directories.
> It seems the easiest way is to add INSTALLED_APPS to 'sahara_dashoard'
> without changing others.
> As far as I checked sahara-dashboard repo, adding INSTALLED_APPS has no
> problem.
> I proposed https://review.openstack.org/282883 based on my
> investigation results.
>
> Note: I am not sure why the current ADD_INSTALLED_APPS were chosen.
> However, changing all of them seems a problem because template paths
> seem to depend
> on INSTALLED_APPS.
>
> If it does not work, I would like to have more ideas from sahara-dashboard
> team
> on how to support translation in Mitaka.
>
> Thanks in advance!
>
> Akihiro
>
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20160222/02b4f558/attachment.html>


More information about the OpenStack-dev mailing list