Skip to content
This repository has been archived by the owner on Apr 7, 2022. It is now read-only.

Commit

Permalink
Merge pull request #9926 from valaparthvi/fix_report
Browse files Browse the repository at this point in the history
[1LP][RFR] Fix KeyError for reports
  • Loading branch information
digitronik authored Feb 18, 2020
2 parents 680314c + ef53ea0 commit f2c368a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cfme/intelligence/reports/reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -584,9 +584,13 @@ def report_timezone(self):

@cached_property
def queued_datetime_in_title(self):
# when the timezone is changed,
# "display" key will not be available without clearing the cache
delattr(self.appliance, "rest_api")
area = self.appliance.rest_api.settings["display"]["timezone"]
try:
area = self.appliance.rest_api.settings["display"]["timezone"]
except KeyError:
area = "UTC"
return parsetime.from_american(
self.queued_datetime, self.report_timezone
).to_saved_report_title_format(area)
Expand Down

0 comments on commit f2c368a

Please sign in to comment.