[BUG] Disk optimization failed
Describe the bug
Optimize and Maintain
⚙ System 11.3/31.9GB RAM | 317/465GB Disk | Uptime 0d | (You should put the version of Mole here to help debug)
➤ Disk Optimization Running Windows default optimization on drive C:... ☻ Disk optimization failed: Aucun objet MSFT_Volume avec la propriété « DriveLetter » égale à « C » n’a été trouvé. Vérifiez la valeur de la propriété et réessayez.
A clear and concise description of what the bug is. We suggest using English for better global understanding.
If you believe the issue may allow unsafe deletion, path validation bypass, privilege boundary bypass, or release/install integrity issues, do not file a public bug report. Report it privately using the contact details in SECURITY.md.
Steps to reproduce
- Run command:
mo ... - ...
- See error
Expected behavior
A clear and concise description of what you expected to happen.
Debug logs
Please run the command with --debug flag and paste the output here:
mo <command> --debug
# Example: mo clean --debug
Debug output
Paste the debug output here
Environment
Please run mo update to ensure you are on the latest version, then paste the output of mo --version below:
Paste mo --version output here
Additional context
Add any other context about the problem here, such as screenshots or related issues.
@Shepard33 fixed this on the windows branch in commit 95616d4.
Root cause was pretty simple: Mole called Optimize-Volume directly on the system drive letter without checking whether Windows could actually resolve that drive to a real optimizable volume first. Now it checks that first and skips cleanly if Windows cannot map the drive, instead of failing with the MSFT_Volume error.
To update:
mo update
If this is an older copied install and mo update does not work, reinstall once with quick-install first.