Explicitly use a UTC timezone for Bazaar.

Review Request #9836 — Created March 27, 2018 and submitted — Latest diff uploaded

Information

Review Board
release-3.0.x
d03c4a4...

Reviewers

When working with Bazaar, we normalize all date-based revisions to UTC.
This works so long as settings.TIME_ZONE is UTC, but if it's
anything else, revision lookup will fail. This is because the TZ
environment variable gets set to the value in settings.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 with settings.TIME_ZONE = 'US/Pacific'.

Verified all tests are fixed with this change, with both UTC and
US/Pacific set in settings_local.py.