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

[BUG/Feature request] 0 byte .json files - randomly occurring - please test for them #6

Open
stylemessiah opened this issue Aug 18, 2022 · 0 comments

Comments

@stylemessiah
Copy link

stylemessiah commented Aug 18, 2022

Recently i have had a few migrate backups fail

Like tonight, with errors like:

Zip Read Errors

Errors

PARSE_APP_MTD: [/sdcard/Migrate/Backup_/Part-x_of_x.zip]
.json - end of input at character of

My current workaround:

I highly recommend checking your backups after creation by launching a terminal app, changing to the Migrate backup folder (/sdcard/Migrate/Backup) and pasting and running the following command:

for file in *.zip; do echo $file && unzip -l "$file" | awk '{print $1 "\t" $4}' | grep 'json' | grep '^0' | grep -v '/' ; done

It will show you any 0 byte .json files and the zip in which theyre in

If you have access to a PC and a GUI zip client, you can then remove the 0 byte files from the zips

OR

you can manually extract the zips to the usual manual restore folder (/data/local/migrate_cache), by opening a terminal, navigating to /sdcard/Migrate/Backup, and then:

for file in *.zip; do unzip "$file" -d "/data/local/tmp/migrate_cache"; done

then to remove any 0 byte .json files:

find /data/local/tmp/migrate_cache -name '*.json' -maxdepth 1 -size 0c -print0 | xargs -0 rm

And then Restore via Migrate Helper

Dont ask me why this randomly occurs.....im just suggesting ways to check and work around it. I ended up having to only reinstall 4 apps from scratch in this latest round of weirdness....thankfully for years ive only had a handful of issues with Migrate

@stylemessiah stylemessiah changed the title [Feature request] 0 byte .json files - randomly occurring - please test for them [BUG/Feature request] 0 byte .json files - randomly occurring - please test for them Sep 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant