Open FireRedDev opened 6 years ago
A bit late, but I had the same error.
Removing line 248 of c:\users\x\appdata\local\programs\python\python36\lib\site-packages\dateutil\tz\tz.py
fixed it for me, but I'm unsure what it breaks by doing that (I wasn't sorting anything by time, only removing all my posts and comments)
It occurs when nuke_hours
is set to too large of a number (in my case at least). 99999
seems to be the largest it will work with. Might end up just editing the script to remove the nuke portion itself.
Traceback (most recent call last): File "C:\Users\chris\AppData\Local\Programs\Python\Python36\Scripts\shreddit-script.py", line 11, in <module> load_entry_point('shreddit==6.0.7', 'console_scripts', 'shreddit')() File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\shreddit\app.py", line 44, in main shredder = Shredder(default_config, args.user) File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\shreddit\shredder.py", line 54, in __init__ self._logger.info("Deleting ALL items before {}".format(self._nuke_cutoff)) File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\arrow\arrow.py", line 373, in __format__ return str(self) File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\arrow\arrow.py", line 366, in __str__ return self._datetime.isoformat() File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\dateutil\tz\tz.py", line 210, in utcoffset if self._isdst(dt): File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\dateutil\tz\tz.py", line 279, in _isdst dstval = self._naive_is_dst(dt) File "c:\users\chris\appdata\local\programs\python\python36\lib\site-packages\dateutil\tz\tz.py", line 248, in _naive_is_dst return time.localtime(timestamp + time.timezone).tm_isdst OSError: [Errno 22] Invalid argument