OceanNetworksCanada / api-python-client

Provides easy access to ONC data in Python
https://oceannetworkscanada.github.io/api-python-client/
Apache License 2.0
10 stars 9 forks source link

overwrite parameter = False in download methods should prevent downloading if file exists #41

Open kan-fu opened 3 weeks ago

kan-fu commented 3 weeks ago

There are 4 ways to download data in onc client library:

Only downloadDirectArchivefile checks whether the file exists before the download. Others will download the data first, then check whether the file should be downloaded. This is a waste of bandwidth if the file size is big.

aschlesin commented 3 weeks ago

This is a good catch @kan-fu. I agree a check for existing files should be implemented in all download functions. Can we make sure that this is also captured in the Matlab code?