jugaad-py / jugaad-data

Download live and historical data for Indian stock market
https://marketsetup.in/documentation/jugaad-data/
373 stars 147 forks source link

zipfile.BadZipFile: File is not a zip file for bhavcopy_fo_save #19

Closed borsemayur2 closed 2 years ago

borsemayur2 commented 3 years ago
Traceback (most recent call last):
  File "/home/mb/my/career/market/bhav/setup.py", line 8, in <module>
    bhavcopy_fo_save(date(2021,7,20), ".")
  File "/home/mb/my/career/market/bhav/venv/lib/python3.9/site-packages/jugaad_data/nse/archives.py", line 120, in bhavcopy_fo_save
    text = self.bhavcopy_fo_raw(dt)
  File "/home/mb/my/career/market/bhav/venv/lib/python3.9/site-packages/jugaad_data/nse/archives.py", line 13, in unzipper
    with zipfile.ZipFile(file=fp) as zf:
  File "/usr/lib/python3.9/zipfile.py", line 1257, in __init__
    self._RealGetContents()
  File "/usr/lib/python3.9/zipfile.py", line 1324, in _RealGetContents
    raise BadZipFile("File is not a zip file")
zipfile.BadZipFile: File is not a zip file
sevakram commented 2 years ago

Please share the code snippet and error