Overview

Request 726578 superseded

- Remove system_zoneinfo.patch, and instead add a symlink to the system timezone database
- Replace unnecessary pytest, adding a missing __init__.py in the tests to allow the test suite to work on Python 2.7 without pytest

Loading...

Tomáš Chvátal's avatar

Wouldn't it be easier to sent the fix for the missing init to upstream and just wait for the next release? Also why do you want it to be symlinked? I think the idea was to have the pytz to always just get stuff from /usr/share/zoneinfo and for that we should probably just define the PYTZ_TZDATADIR and make sure the tzfile.py respect that too


John Vandenberg's avatar

Upstream doesnt need the missing __init__.py. And it is almost never "easier" to try to work with upstream and than remember to come and fix the problem here when they do a release.

pytz declares it has package data, which is supposed to be available. The current "solution" removes that functionality. This request restores it. I'm not sure this is the best way, as it appears that despite the symlink - a new copy of the directory is included in the rpm, so it isnt required to be identical to the data from timezone. I suspect that is being done by rpm .. ? A real symlink would be better. I guess a postinstall step is needed to achieve a real symlink.

A patch to set PYTZ_TZDATADIR, if unset, would also work as a way of ensuring the timezone package data is loaded, but the crucial part is that the file paths declared by pytz need to exist .


Request History
John Vandenberg's avatar

jayvdb created request

- Remove system_zoneinfo.patch, and instead add a symlink to the system timezone database
- Replace unnecessary pytest, adding a missing __init__.py in the tests to allow the test suite to work on Python 2.7 without pytest


openSUSE Build Service is sponsored by