deltazefiro / Amarok-Hider

Hide your private files and apps with a single click.

Home Page:https://deltazefiro.github.io/Amarok-doc/en-US/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Recover unexpectedly corrupted files - v0.8.1b3

xMostafax opened this issue · comments

Describe the bug / 问题描述
A clear and concise description of what the bug is.
请清晰地描述您遇到的异常。

I'm selected Pictures folder by mistake in hide files and hide it after un hide all pictures destroyed any fix for this 😔 ?

To Reproduce / 复现步骤
Steps to reproduce the behavior / 复现异常的步骤:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior / 预期行为
A clear and concise description of what you expected to happen.
描述您认为正常情况下应该发生什么。

Screenshots / 截图
If applicable, add screenshots to help explain your problem.
(可选)问题复现时候的截图或录屏。

Screenshot_20230117-182554_MiXplorer

Basic Information (please complete the following information) / 请填写以下信息:

  • OS (ROM) / 系统: [e.g. Derpfest
  • Android Version / 安卓版本: [e.g. 12.l]
  • Amarok Version / Amarok版本: [e.g. v0.8.1b3-foss]

Can I assume that you are using Amarok v0.8.1b3 and enabled the Obfuscate File Header [Experimental] function?
Possibly the same bug: #16
I failed to reproduce this bug. It seems to happen occasionally 🤔
If you can find a way to reproduce this bug consistently, it would greatly aid in resolving the issue.

Recover the Corrupted files

  1. Download and install this Special version of Amarok (v0.8.1b3-sp-e57eb09).
  2. In More Settings -> Switch FileHider Workmode of that special Amarok, make sure the Obfuscate File Header [Experimental] switch is toggled to OFF.
  3. Put the corrupted files into a directory, and add the directory to the hide list in Set Hide Files.
  4. Press the Hide button in the main activity.
  5. In More Settings -> Switch FileHider Workmode, toggle Obfuscate File Header [Experimental] to ON.
    (In the normal version this switch is unavailable and a note says Options are unavailable until Unhide.)
  6. Press the Unhide button in the main activity.

Hopefully, your corrupted files (images) will be recovered.

Can I assume that you are using Amarok v0.8.1b3 and enabled the Obfuscate File Header [Experimental] function? Possibly the same bug: #16 I failed to reproduce this bug. It seems to happen occasionally 🤔 If you can find a way to reproduce this bug consistently, it would greatly aid in resolving the issue.

Recover the Corrupted files

  1. Download and install this Special version of Amarok (v0.8.1b3-sp-e57eb09).
  2. In More Settings -> Switch FileHider Workmode of that special Amarok, make sure the Obfuscate File Header [Experimental] switch is toggled to OFF.
  3. Put the corrupted files into a directory, and add the directory to the hide list in Set Hide Files.
  4. Press the Hide button in the main activity.
  5. In More Settings -> Switch FileHider Workmode, toggle Obfuscate File Header [Experimental] to ON.
    (In the normal version this switch is unavailable and a note says Options are unavailable until Unhide.)
  6. Press the Unhide button in the main activity.

Hopefully, your corrupted files (images) will be recovered.

Thank you some pictures are back but not all, and it's my fault from first i killed the app from background while the app hiding files because i select pictures file by mistake thanks.

Thank you some pictures are back but not all

Sorry to hear that. Perhaps you can try the recovery process again.
If still without luck and the images are really important to you, you can try recovering the images manually:

  • Amarok only read the first 8 bytes of each file, calculates their ones' complement and writes the result back.
  • As Amarok reads and writes files sequentially, theoretically will be only one file is "real" damaged, while others are just not reverted.
  • Fixing them manually: Open the image with a hex editor, replace the first 8 bytes with their ones' complement — e.x. 1 to F, 2 to E and so on.

it's my fault from first i killed the app from background while the app hiding files because i select pictures file by mistake thanks.

To avoid it happening again, I've refactored the FileHider and added some insurance work during the process. 8261481

Fixing them manually: Open the image with a hex editor, replace the first 8 bytes with their ones' complement — e.x. 1 to F, 2 to E and so on.

Well, I wrote a simple script to do this. Python3 is required.

Thank you some pictures are back but not all

Sorry to hear that. Perhaps you can try the recovery process again. If still without luck and the images are really important to you, you can try recovering the images manually:

  • Amarok only read the first 8 bytes of each file, calculates their ones' complement and writes the result back.
  • As Amarok reads and writes files sequentially, theoretically will be only one file is "real" damaged, while others are just not reverted.
  • Fixing them manually: Open the image with a hex editor, replace the first 8 bytes with their ones' complement — e.x. 1 to F, 2 to E and so on.

it's my fault from first i killed the app from background while the app hiding files because i select pictures file by mistake thanks.

To avoid it happening again, I've refactored the FileHider and added some insurance work during the process. 8261481

I tried the first process again and it's works thank you again.

I tried the first process again and it's works thank you again.

Cool! Let me close this issue then.

commented

To avoid it happening again, I've refactored the FileHider and added some insurance work during the process. 8261481

I'm waiting for you to add it to the release

I'm waiting for you to add it to the release

already here 🤔

commented

I'm waiting for you to add it to the release

already here 🤔

sorry, I didn't see it before