Fix-OneDrive-Zip icon indicating copy to clipboard operation
Fix-OneDrive-Zip copied to clipboard

Hey there, the script is not working

Open kpratikraj opened this issue 1 year ago • 3 comments

Thanks for your script but its not working. After I run the command, it says "Updated myfile.zip" but when I go back to my directory and try to unzip it, I get the message "Before you can extract files, you must copy files to this compressed (zipped) folder. Please help me!

kpratikraj avatar Jun 17 '24 19:06 kpratikraj

Hi @kpratikraj

what platform are you running? I'm don't know the "Before you can extract files, you must copy files to this compressed (zipped) folder." message but it sounds like a gui application.

pmqs avatar Jun 17 '24 19:06 pmqs

Hey @pmqs , I am on windows. I get the "Updated myfile.zip" and when I try to unzip using windows default unzipper, I get the message "Before you can extract files, you must copy files to this compressed (zipped) folder."

kpratikraj avatar Jun 17 '24 20:06 kpratikraj

A quick search for the message you are getting suggests that "Windows Compressed Folders" thinks that your zip file doesn't contain any files at all.

Are you sure that the OneDrive zip file contains files?

If you have access to one of the command line unzip utilities you could try using them to see what they think are in your zip file.

pmqs avatar Jun 17 '24 21:06 pmqs

Hi, thank you for developing this script. I've tried it on a zip file I've just downloaded from onedrive to a ubuntu 22.04 machine using the onedrive web interface in Firefox and run your script with the --dry-run option. It gives the following error:

Checking 'Vatt_Run_oct_nov_2023.zip' Error: Cannot find Zip signature at end of 'Vatt_Run_oct_nov_2023.zip'

The zip file is about 21GB. I'd be very grateful for any insights. Thanks!

mgeever avatar Mar 20 '25 11:03 mgeever

The error you are getting suggests that the zip file has been truncated. Can you try downloading again?

pmqs avatar Mar 20 '25 11:03 pmqs

Hi, thanks for a super fast reply. I think you're correct; onedrive seems to be truncating the downloads somewhere along the way. Just for info: I tried 7zip and it seemed to work (extracts and writes some of the data) but reports an error to say that the zip archive was truncated. I'm trying to download five different folders and the resulting downloaded zip file for each one is suspiciously the same size, 21.5GB. More digging required. Thanks for your help, very much appreciated!

mgeever avatar Mar 20 '25 12:03 mgeever