Describe the bug
I installed Bazaar and when starting from cmd this error:
Bazarr starting...
Traceback (most recent call last):
File "c:\bazarr\bazarr\main.py", line 54, in <module>
from scheduler import *
File "c:\bazarr\bazarr\scheduler.py", line 66, in <module>
if str(get_localzone()) == "local":
File "c:\bazarr\bazarr\../libs/tzlocal\win32.py", line 95, in get_localzone
utils.assert_tz_offset(_cache_tz)
File "c:\bazarr\bazarr\../libs/tzlocal\utils.py", line 38, in assert_tz_offset
raise ValueError(msg)
ValueError: Timezone offset does not match system offset: -7200 != -10800. Please, check your config files.
To Reproduce
Steps to reproduce the behavior:
Software
Please confirm your Bazarr version as this bug has been fixed a long time ago: https://github.com/morpheus65535/bazarr/issues/405
v0.8.2.4
same here
Same here
It's broken. Wont start. Please, fix it. Thanks.
I will, when I'm gonna get time to. Until then, sorry.
Brazilian Daylight Saving Time would start yesterday but has been canceled.
I changed from UTC-3 to UTC-0 on Windows and it work, but I have incorrect time on Windows System...
I did the same. The problem has relation with the Brazilian daylight time,
that was canceled.
Enviado utilizando um Galaxy S9...
Em ter, 22 de out de 2019 01:19, Tiago Souza notifications@github.com
escreveu:
Brazilian Daylight Saving Time would start yesterday but has been canceled.
I changed from UTC-3 to UTC-0 on Windows and it work, but I have incorrect
time on Windows System...—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGXEBCMIIJUJWL2LKQTQPZ5OPA5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB4PTRA#issuecomment-544799172,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABUXTGRLBVWCETYD53DD5QDQPZ5OPANCNFSM4JCUIFBQ
.
Please insure your Windows 10 is up-to-date: https://techcommunity.microsoft.com/t5/Daylight-Saving-Time-Time-Zone/Time-zone-updates-for-Brazil-are-available/ba-p/751175
Updated here. Same problem
Enviado utilizando um Galaxy S9...
Em ter, 22 de out de 2019 13:37, morpheus65535 notifications@github.com
escreveu:
Please insure your Windows 10 is up-to-date:
https://techcommunity.microsoft.com/t5/Daylight-Saving-Time-Time-Zone/Time-zone-updates-for-Brazil-are-available/ba-p/751175—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGQX34BTOI7MBY3JOELQP4T4JA5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB6MUCQ#issuecomment-545049098,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABUXTGTTE6PYRGFII7LTMN3QP4T4JANCNFSM4JCUIFBQ
.
@rodrigoscoelho Are you able to replace the pytz directory in bazarr/libs with the one in the latest release zip of pytz Python module? The pytzdirectory in the zip archive is located under src directory. You can get it from https://github.com/stub42/pytz/archive/release_2019.3.zip
Restart Bazarr and confirm if it fix your issue. Thanks!
Didn't work.
Enviado utilizando um Galaxy S9...
Em ter, 22 de out de 2019 14:27, morpheus65535 notifications@github.com
escreveu:
@rodrigoscoelho https://github.com/rodrigoscoelho Are you able to
replace the pytz directory in bazarr/libs with the one in the latest
release zip of pytz Python module? The pytzdirectory in the zip archive
is located under src directory. You can get it from
https://github.com/stub42/pytz/archive/release_2019.3.zipRestart Bazarr and confirm if it fix your issue. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGTJVRL7GME3NGJ2TQTQP4ZWXA5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB6RNIA#issuecomment-545068704,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABUXTGWDXYEPUR3AON2PAY3QP4ZWXANCNFSM4JCUIFBQ
.
We are on gmt -3 on Brazil, which is equivalent to minus 10800 seconds.
When on summertime, it is only gmt -2, equivalent to minus 7200 seconds.
So, we are not on summertime, windows is correct, but the python is
expecting the summertime,causing the time difference. It should be only a
warning and this couldn't be a critical exception, IMHO.
Where can we force the timezone on configuration of bazarr? Is it possible?
Thanks
Enviado utilizando um Galaxy S9...
Em ter, 22 de out de 2019 20:29, rodrigoscoelho notifications@github.com
escreveu:
Didn't work.
Enviado utilizando um Galaxy S9...
Em ter, 22 de out de 2019 14:27, morpheus65535 notifications@github.com
escreveu:@rodrigoscoelho https://github.com/rodrigoscoelho Are you able to
replace the pytz directory in bazarr/libs with the one in the latest
release zip of pytz Python module? The pytzdirectory in the zip archive
is located under src directory. You can get it from
https://github.com/stub42/pytz/archive/release_2019.3.zipRestart Bazarr and confirm if it fix your issue. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGTJVRL7GME3NGJ2TQTQP4ZWXA5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB6RNIA#issuecomment-545068704
,
or unsubscribe
<
https://github.com/notifications/unsubscribe-auth/ABUXTGWDXYEPUR3AON2PAY3QP4ZWXANCNFSM4JCUIFBQ.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGWXQOYQT67MSOJ5FSDQP6EHLA5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB7RFHI#issuecomment-545198749,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABUXTGW2FNSF2MWCWSGETSLQP6EHLANCNFSM4JCUIFBQ
.
Same error here, I've downloaded the pytz from https://pypi.org/project/pytz/ ( latest version )
pip install pytz
Collecting pytz
Downloading https://files.pythonhosted.org/packages/e7/f9/f0b53f88060247251bf481fa6ea62cd0d25bf1b11a87888e53ce5b7c8ad2/pytz-2019.3-py2.py3-none-any.whl (509kB)
100% |UUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU| 512kB 3.2MB/s
Installing collected packages: pytz
Successfully installed pytz-2019.3
I've copied the files from C:\Python27\Lib\site-packagespytz\zoneinfo\Brazil to C:\bazarr\libspytz\zoneinfo\Brazil , I do believe the problem lies with the cancellation of daylight savings in Brazil...
the problem persist.
I think this is a problem for every single brazilian user. Daylight saving time was cancelled by the president some months ago, but systems are still configured waiting for it to happen.
Got the same exact error.
From my understanding about the problem, pytz needs to be updated with the new information about the non usage of daylight saving time in Brazil.
As a workaround to remove the problem on my system to keep using Bazarr for the time being, I changed the definition of function get_tz_offset, located in file:
Bazarr\bazarr\utils.py
Changed function from:
def get_tz_offset(tz):
"""Get timezone's offset using built-in function datetime.utcoffset()."""
return int(datetime.datetime.now(tz).utcoffset().total_seconds())
to:
def get_tz_offset(tz):
"""Get timezone's offset using built-in function datetime.utcoffset()."""
if str(tz) == 'America/Sao_Paulo':
return int(-10800)
else:
return int(datetime.datetime.now(tz).utcoffset().total_seconds())
This way I "force" Bazarr to set the offset value to -10800 instead of receiving that value from pytz.
Don't know if it's for the better to remove the raise error there on the if statement that checks if values of offsets are equal (_and leave the print error as just a warning_), or just wait for a new pytz version to be used by bazarr (_don`t actually know if it's already using the lastest version_).
Thanks to @dkage for fixing this issue! In dev branch for now.
I don't think he fixed the issue. He forced a wrong value to fix the issue now. When the PYTZ corrects the data for Brazil, the issue probably will rise back. Not?
His last comment here was a temporary fix that didn't get pushed to Bazarr. He fixed it in PR #646 where he updated pytz and tzlocal to latest version.
great. Thanks.
Em qui, 24 de out de 2019 Ã s 10:59, morpheus65535 notifications@github.com
escreveu:
His last comment here was a temporary fix that didn't get pushed to
Bazarr. He fixed it in PR #646
https://github.com/morpheus65535/bazarr/pull/646 where he updated pytz
and tzlocal to latest version.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/morpheus65535/bazarr/issues/641?email_source=notifications&email_token=ABUXTGRZZAZMHOX7PBZ5CE3QQGS25A5CNFSM4JCUIFB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECFD7AQ#issuecomment-545931138,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABUXTGXAYKBQYI7NMB4USZTQQGS25ANCNFSM4JCUIFBQ
.
I was passing through the same problem in a different context, so I did changes suggested by @dkage and it worked perfectly. Thanks!