spedas / pyspedas

Python-based Space Physics Environment Data Analysis Software
https://pyspedas.readthedocs.io/
MIT License
143 stars 58 forks source link

Added force_download option to download #905

Closed thepug432 closed 3 days ago

thepug432 commented 1 week ago

This should close #899 . Please tell me if any changes are needed. I considered an option where the force_download option takes either a boolean or a list of files to force download. This would allow the user to force_download only certain files with a single function call. I don't know how good it is stylistically to have a function take either a bool or an array of strings, but I could implement that if it would be better.

jameswilburlewis commented 3 days ago

I don't think we need the extra functionality of specifying a list of filenames to force-download. For the cases where force-download is useful (e.g. user has inadvertently edited a downloaded file and wants to restore from the data provider), it's probably easier to use the higher-level mission specific load routine with the desired date range and other options, with force_download=True, than it is to specify full file paths directly.