Explicitly use a UTC timezone for Bazaar.
Review Request #9836 — Created March 27, 2018 and submitted — Latest diff uploaded
When working with Bazaar, we normalize all date-based revisions to UTC.
This works so long assettings.TIME_ZONE
isUTC
, but if it's
anything else, revision lookup will fail. This is because theTZ
environment variable gets set to the value insettings.TIME_ZONE
by
Django, and this gets inherited by Bazaar, causing all variable lookups
to be offset further by the timezone.By forcing
TZ=UTC
, we can ensure that Bazaar will be able to match up
any revisions we throw its way.Unit tests were updated to check for this case.
Tested that the unit tests failed without the fix both for the new tests
and for existing ones withsettings.TIME_ZONE = 'US/Pacific'
.Verified all tests are fixed with this change, with both
UTC
and
US/Pacific
set insettings_local.py
.