this is particularly at this line:
filesys = os.listdir(settings.CAPTCHA_ROOT)
it happens when trying to read or write to a directory.
any ideas why it would do this only under Windows?
edit ---------------------------------------
def __clean_captchas(self, offset=3600):
"""docstring for __clean_captchas"""
filesys = os.listdir(settings.CAPTCHA_ROOT)
offset = datetime.datetime.now() - datetime.timedelta(seconds=offset)
for file in filesys:
d = datetime.datetime.fromtimestamp(os.stat(settings.CAPTCHA_ROOT+file).st_ctime) ...
if d < offset:
os.remove(settings.CAPTCHA_ROOT+file)