I'm getting a weird content disposition error with my output, not entirely sure where I've gone wrong. I'm using a similar code to that which has been posted before:
from landsatxplore.earthexplorer import EarthExplorer
ee = EarthExplorer("UUUUNNNN", "PPPPPPPP")
i = 1
with open("tiles.txt", 'r') as input_data:
for scene in input_data:
ee.download(
scene_id=str(scene),
output_dir='./output'
)
ee.logout()
The error is as follows:
Traceback (most recent call last):
File "LSX_DL.py", line 10, in <module>
output_dir=r'./output'
File "/home/user/.local/lib/python3.7/site-packages/landsatxplore/earthexplorer.py", line 96, in download
filename = self._download(url, output_dir)
File "/home/user/.local/lib/python3.7/site-packages/landsatxplore/earthexplorer.py", line 77, in _download
local_filename = r.headers['Content-Disposition'].split('=')[-1]
File "/home/user/.local/lib/python3.7/site-packages/requests/structures.py", line 54, in __getitem__
return self._store[key.lower()][1]
KeyError: 'content-disposition'
I'm getting a weird content disposition error with my output, not entirely sure where I've gone wrong. I'm using a similar code to that which has been posted before:
The error is as follows: