Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delta downloads don't work (after commit #22) #2

Open
mindheist opened this issue Dec 28, 2014 · 2 comments
Open

Delta downloads don't work (after commit #22) #2

mindheist opened this issue Dec 28, 2014 · 2 comments
Labels

Comments

@mindheist
Copy link
Owner

Delta downloads now dont work because "download_last_modified.txt" file gets sorted into a folder based on its creation year ,and when the application tries to download it subsequently , it looks for that file in the root folder .

A good way to work around this , might be to have a separate folder for all the application logic files (ie)
creation_date.txt , last_modified.txt and download_last_modified.txt.

==== log ===

download_last_modified.txt 2014
1872944-dexterslaboratorywallpaper800.jpg 2014
Dexter-and-DeeDee-dexters-laboratory-13130813-445-411.jpg 2014
Dexter's_Laboratory_title.jpg 2014
the s3_downloads folder already exists , will now selectively download files into this folder
Traceback (most recent call last):
File "cloudcrate.py", line 289, in
download_last_modified_dict = json.load(open("download_last_modified.txt"))
IOError: [Errno 2] No such file or directory: 'download_last_modified.txt'
MBP:cloudrate_test Hari$

@mindheist mindheist changed the title Delta downloads don't work Delta downloads don't work (after commit #22) Dec 28, 2014
@mindheist
Copy link
Owner Author

Making the download_last_modified.txt available in the root directory might alone suffice. Tried this manually , and all delta files are being downloaded ( on a side note : make sure that the code to sort and download files is available in all of the loops)

@mindheist
Copy link
Owner Author

-> The simplest solution for this would be to make the download_last_modified.txt available in the root folder of cloud crate; tested this solution and it seems to work. Tested the following 3 scenarios

  1. Download files for the first ever time ( regression test)
    All the files are downloaded into the respective folders and last_modified_time.txt also gets sorted into one of the folders. ( as expected and hence the bug)
    -> All of the application logic files are also created : creation.txt , last_modified.txt
  2. Modify just one file , Upload and Download
    -> Modify one file and try to upload
    -> the last_modified.txt gets updated
    -> the creation.txt file get updated
    -> Delta alone gets uploaded based on the information in last_modified.txt
    -> Once again, only the delta is downloaded
  3. Add a new file to the directory ; delta alone gets up/downloaded.

@mindheist mindheist added the bug label Jan 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant