diff options
author | Costin Galan <cgalan@cloudbasesolutions.com> | 2016-06-16 14:56:28 +0300 |
---|---|---|
committer | Costin Galan <cgalan@cloudbasesolutions.com> | 2016-06-17 07:51:19 +0300 |
commit | 5a8cade630e6d72e9d81784648484faa530c40da (patch) | |
tree | 20a285422b8b475668c7d8428e44aa93c1556f6e /oslo_utils/timeutils.py | |
parent | 2ac2bff19e4c35ec9d04c098b7a48b302602d8a2 (diff) | |
download | oslo-utils-5a8cade630e6d72e9d81784648484faa530c40da.tar.gz |
Fix flake8 issues
I have improved the readability of the code by fixing the
problems that flake8 reported.
The type of errors that are fixed are:
* H302 - Import only module
* H305 - Import not grouped correctly
* H307 - Like imports shoud be grouped together
* H402 - One line docstring needs punctation
* F821 - Undefined name
Change-Id: I3a7f12120b6a99342a3d2025206edcdc0f6a4a93
Signed-off-by: Costin Galan <cgalan@cloudbasesolutions.com>
Diffstat (limited to 'oslo_utils/timeutils.py')
-rw-r--r-- | oslo_utils/timeutils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/oslo_utils/timeutils.py b/oslo_utils/timeutils.py index ca809fc..4509da6 100644 --- a/oslo_utils/timeutils.py +++ b/oslo_utils/timeutils.py @@ -25,7 +25,7 @@ import time from debtcollector import removals import iso8601 from monotonic import monotonic as now # noqa -from pytz import timezone +import pytz import six from oslo_utils import reflection @@ -283,7 +283,7 @@ def unmarshall_time(tyme): microsecond=tyme['microsecond']) tzname = tyme.get('tzname') if tzname: - tzinfo = timezone(tzname) + tzinfo = pytz.timezone(tzname) dt = tzinfo.localize(dt) return dt |