Roundup Tracker - Issues

Issue 2551030

classification
Roundup fails to start if pytz to access Olson timezone database not installed
Type: crash Severity: major
Components: Infrastructure Versions: devel, 1.6
process
Status: fixed fixed
:
: rouilj : rouilj
Priority: high : Effort-Low

Created on 2019-03-13 00:01 by rouilj, last changed 2019-06-01 22:01 by rouilj.

Messages
msg6386 Author: [hidden] (rouilj) Date: 2019-03-13 00:01
When running roundup, the Olson timezone database (pytz) is supposed to 
be optional. However the configuration.py file uses:

        (TimezoneOption, "timezone", "UTC", "Default timezone offset,"
            " applied when user's timezone is not set.",
            ["DEFAULT_TIMEZONE"]),

in ths

  SETTINGS = (
      ("main", (

tuple definition. This raises an exception when trying to parse UTC
if pytz is not installed. I think the fix it to set a variable
for the setting:

  try:
    import pytz
    timezone=  (TimezoneOption, "timezone", "UTC",
                "Default timezone offset,"
            " applied when user's timezone is not set.",
            ["DEFAULT_TIMEZONE"])
  except ImportError:
    timezone = (TimezoneOption, "timezone", "0",
            "Default timezone offset,"
            " applied when user's timezone is not set.",
            ["DEFAULT_TIMEZONE"])

then replace the entry in the tuple with timezone. I think this would 
work, but I am not sure.
msg6495 Author: [hidden] (rouilj) Date: 2019-06-01 22:01
fixed in rev5753:178ca608ddb9.

Implemented as a new defaulttz property on TimezoneOption
that is used to set the default in the timezone option setting.
History
Date User Action Args
2019-06-01 22:01:21rouiljsetstatus: new -> fixed
assignee: rouilj
resolution: fixed
messages: + msg6495
2019-03-13 00:01:40rouiljcreate