This bug only appears to be a cosmetic one where the TZ offset
would be calculated on current_year/01/01 so would remain in
daylight saving offset when displaying the timezones list.
(Note by amotoki)
The minimum version of Babel is bumped to 2.6.0
as Babel 2.3.4 returns "New Zealand Time" instead of "New Zealand
(Auckland) Time" returned from the latest Babel (2.9.0).
It is not a good idea to handle such difference in Babel in our UT
and there is no reason to stick to Bump 2.3.4.
2.6.0 was chosen as it is available in Ubuntu Focal and there is
no more reason than this.
Change-Id: I0600086cc51cf5abcf1631565e75146114189667
Closes-bug: #1822849
Django provides safer ways to override settings.
We should avoid direct replacement of existing setting.
Change-Id: I1fbcb79d18baaae037536b180989cf69c198fa7d
(In Django 2.0) The django.core.urlresolvers module is removed
in favor of its new location, django.urls.
It was depreacted in Django 1.10:
https://docs.djangoproject.com/en/2.0/releases/1.10/#id3
blueprint django2-support
Change-Id: I46ab5c325491274b8eaffbf848e5d80f83c2fd26
This reverts commit a880926300.
The reverted implementation depends on LOCALE_PATHS but this assumption
turns out not correct. Django searches messages catalogs LOCALE_PATHS
and locale directory in individual INSTALLED_APPS, but the usage of
LOCALE_PATHS varies on deployers and we cannot assume the default value
of LOCALE_PATSH.
In addition, the logic of auto-generating the language list cannot
handle locale name alias ('fallback' in the Django code).
Django 1.9 or later perfers to zh-hant and zh-hans, and zh-cn and
zh-tw are now defined as fallback.
We can explore a better approach for auto-generation of the language
list, but we do not have more reliable way so far. Cconsidering the
timing of Pike release, the safest approach looks like to revert
the original patch back to the manula maintenance of the lang list.
Languages with over 50% progress (based on the number of translated
messages as total) are listed in settings.LANGUAGES.
(http://paste.openstack.org/show/618254/)
Closes-Bug: #1710131
Change-Id: I5133d6317aba6107fc37bd5f30388c130b1fdaac
Previously the available language list is maintained manually.
This commit change horizon to check translation message catalog
is available for each language and generate the language list
automatically. settings.LANGUAGES is still used to determines
the initial set of languages and now defaults to the list provided
by django.
Change-Id: I9d9c934beebd7a641e2feb0d5cdfa839e0efa3c3
Closes-Bug: #1675298
MOSCOW on October 26 has turned its clocks back one hour switching to permanent
"winter" time and ending the three-year experiment of living on permanent
"summer time." No seasonal time change is envisaged from now on.
For safety, we remove this timezone check
Change-Id: I1614f8f7adb56903816aa5a093d742925dd51ea8
Closes-Bug: #1407055
Use timezone info in Babel to translate timezones. Sort
timezones by offset. Update format to:
UTC -06:00: United States (Chicago) Time
Thanks amotoki for suggesting to use Babel to handle this!
Not updating environment_version in run_tests.sh because Babel isn't
a new requirement; it's just being made explicit.
Change-Id: I15d39b94d441e9e155870a0593d11e67e68f9bd9
Closes-Bug: #1333927
Remove vim setting:
comment - # vim: tabstop=4 shiftwidth=4 softtabstop=4
at the top of source code files, except for files in
openstack/common.
Change-Id: I9a5c6b17c6ef7ecec601f4503dfc7b31fc72e90a
Close-bug: #1229324
We have a lot of import with #noqa that is there to ignore h302,
because it's traditional to import and use a name directly, instead
of a whole module. This hides other errors and gives people the
impression that it's actually fine to import non-modules, you just
have to slap #noqa on those lines.
I went through the code and identified about a dozen names that are
most commonly imported this way. I remove the #noqa tag from them,
and added them to the list in import_exceptions.
I also removed a few unused imports that were revealed in the process.
Change-Id: I27afb8e2b1d4759ec974ded9464d8f010312ee78
Language preference form expects all languages in LANGUAGES in
openstack_dashboard/settings.py. This leads to an error when
adding a language not listed in django/conf/locale to LANGUAGES list.
This commit allows such language to LANGUAGES in the settings file.
Closes-Bug: #1229026
Change-Id: I37d7f4b089b0299942f25084f741a557467b3be7
This patch replaces some method imports with module imports and
makes H302 test enabled.
Fixes bug 1188531
Change-Id: Ibfbddeaa19cbbb244da58ffd5c918c41f03a0c65
Under some circumstances, Canada/Newfoundland (UTC -03:30)
can not be found as answer in tests. This patch improves
stability here by using cities with the same distances to
UTC and UTC DST.
Fixes bug 1184901
Change-Id: I7d5739a7c7a504c22cceebeaa3331637993e34ae
As noted in the reviews for the backport (20467), the initial patch
for bug 1103003 didn't account for timezones changing over time.
Change-Id: Iceab7deb803669c56aa21252561f650f8c4a601d
In the User Settings, indicate besides the timezone name what the
actual timezone/UTC offset is.
Fixes bug 1103003
Change-Id: I8070df2bc0380da1555c40dc9394895fbfde6848