Skip to content
This repository has been archived by the owner on Sep 9, 2022. It is now read-only.

Follow folder structure as on S3 locally for ease of finding files #3

Closed
sckott opened this issue Oct 1, 2015 · 6 comments
Closed
Milestone

Comments

@sckott
Copy link
Collaborator

sckott commented Oct 1, 2015

No description provided.

@sckott
Copy link
Collaborator Author

sckott commented Oct 2, 2015

@lawinslow is it annoying if the root folder to store images is a hidden folder? starting with .landsat-pds - i like hidden because less likely for user to accidentally delete, but harder to find

@sckott sckott modified the milestone: v0.1 Oct 9, 2015
@lawinslow
Copy link
Contributor

It doesn't bother me much. Just mimics git and the like. Point to note though, dot doesn't hide files on Windows file system.

> lsat_image(x = paste0(entityId, "_B2.TIF"))
[1] "~/.landsat-pds/L8/010/117/LC80101172015002LGN00/LC80101172015002LGN00_B2.TIF"
> lsat_image(x = paste0(entityId, "_B2.TIF"))
File in cache
[1] "~/.landsat-pds/L8/010/117/LC80101172015002LGN00/LC80101172015002LGN00_B2.TIF"

I like it. Awesome.

@lawinslow
Copy link
Contributor

Also, may want to handle issues with the cache having partial downloads. If I kill the download half way through, it still gives me the cached version.

> lsat_image(x = paste0(entityId, "_B2.TIF"))

 Show Traceback

 Rerun with Debug
 Error in curl::curl_fetch_disk(url, x$path, handle = handle) : 
  Failed writing received data to disk/application > entityId
[1] "LC80260392015002LGN00"
> lsat_image(x = paste0(entityId, "_B2.TIF"))
File in cache
[1] "~/.landsat-pds/L8/026/039/LC80260392015002LGN00/LC80260392015002LGN00_B2.TIF"
> 

Perhaps download to a temporary location and on success, move to the .landsat-pds cache location? I wonder if there's a way to verify the file integrity. I don't see any MD5's and I'm unaware if Tiff has anything built-in.

@sckott
Copy link
Collaborator Author

sckott commented Oct 9, 2015

ahhhhh, good to know, didn't realize . files/folders aren't hidden on windows

@sckott
Copy link
Collaborator Author

sckott commented Oct 9, 2015

thanks, see #7 and #8

@sckott
Copy link
Collaborator Author

sckott commented Aug 10, 2016

sorted, using rappdirs now, and files found in same structure as on aws

@sckott sckott closed this as completed Aug 10, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants