ramensoftware / windhawk-mods

The official collection of Windhawk mods
312 stars 56 forks source link

[Better file sizes in Explorer details] No folder sizes on Windows 10 1607 #1245

Closed legacy1477 closed 6 days ago

legacy1477 commented 1 week ago

The mod does not show folder sizes on Windows 10 1607 14393.7259.

I have tried it on a VM with the same Windows version without an AV active, with allowing Windhawk to use system processes from advanced options. I have tried both manual and Everything methods, none show anything. I installed the normal version of everything without service mode. Then re-installed with service mode. I restarted the VM multiple times with no luck.

Also, the mod seems to inject quite frequently into almost every process. Stuff like DWM, cmd and etc. Stuff that doesn't have any UI or will never utilize this in any way. Winpython seemed to have issues injecting and the injection window remained opened till I restarted Windhawk. I suggest only injecting into explorer.exe and allowing people to manually specify which applications they'd like this mod to inject into.

m417z commented 1 week ago

I didn't test the mod on Windows 10 versions other than the latest build.

Please attach debug logs by following the instructions on the Troubleshooting page: https://github.com/ramensoftware/windhawk/wiki/Troubleshooting#some-or-all-windhawk-mods-dont-work

  • Disable the mod.
  • Go to the mod's Advanced tab.
  • Set Debug logging to Detailed debug logs.
  • Click on Show log output.
  • Enable the mod.
  • Verify that the mod doesn't work, copy the log and save it to a file.
  • Set Debug logging back to None.

Winpython seemed to have issues injecting and the injection window remained opened till I restarted Windhawk.

That sounds like something that shouldn't happen. What does the injection window show? Does it happen every time? Does it only happen on this Windows 10 build?

I suggest only injecting into explorer.exe and allowing people to manually specify which applications they'd like this mod to inject into.

There are several Windhawk mods which customize various aspects of the file explorer elements, and most/all of them target all processes. I'll consider changing it for "Better file sizes in Explorer details" since it's a popular mod if it causes a significant amount of problems. For now, I don't think there are enough reasons for that.

Generally, the mod hooks several functions, and if a process never shows the explorer UI then these functions will never be called, and so the mod should have no effect. If that's not the case, perhaps it's a bug that's worth investigating.

m417z commented 1 week ago

I downloaded and extracted WinPython. What should I do next to reproduce the issue?

legacy1477 commented 6 days ago

There are several Windhawk mods which customize various aspects of the file explorer elements, and most/all of them target all processes. I'll consider changing it for "Better file sizes in Explorer details"

I see.

Generally, the mod hooks several functions, and if a process never shows the explorer UI then these functions will never be called, and so the mod should have no effect. If that's not the case, perhaps it's a bug that's worth investigating.

When it injected into every process even hidden console apps it spiked the CPU like crazy. But, idk I can just manually include processes for myself I guess.

I downloaded and extracted WinPython. What should I do next to reproduce the issue?

It's running a basic script that collects CPU and RAM usage and turns it into an image that ChatGPT wrote. It's been running for nearly a week straight. It was mostly part of the example. I can attach the script if you want, not sure if you'll be able to get it stuck like it was for me.

Please attach debug logs by following the instructions on the Troubleshooting page: https://github.com/ramensoftware/windhawk/wiki/Troubleshooting#some-or-all-windhawk-mods-dont-work

  • Disable the mod.
  • Go to the mod's Advanced tab.
  • Set Debug logging to Detailed debug logs.
  • Click on Show log output.
  • Enable the mod.
  • Verify that the mod doesn't work, copy the log and save it to a file.
  • Set Debug logging back to None.

debug.txt

In regards to symbols I have the following files downloaded:

‪C:\ProgramData\Windhawk\Engine\Symbols\Windows.Storage.pdb\BC5011A7C49D43F982F6194C8B621CE51\Windows.Storage.pdb ‪C:\ProgramData\Windhawk\Engine\Symbols\Windows.Storage.pdb\7F3004384B89424AB670E8930E5DFA2E1\Windows.Storage.pdb ‪C:\ProgramData\Windhawk\Engine\Symbols\Windows.Storage.pdb\7F3004384B89424AB670E8930E5DFA2E1\download2A3693990DE747D08C22235EC2B09177.error ‪C:\ProgramData\Windhawk\Engine\Symbols\Windows.Storage.pdb\BC5011A7C49D43F982F6194C8B621CE51\download57D971D91EB04A898B8F94ED1C54299D.error

m417z commented 6 days ago

debug.txt

One of the symbols is different in this older Win10 version. Please try this mod version: https://github.com/m417z/my-windhawk-mods/blob/055b82436ccf22eba85c422c0f785e26ba1d8784/mods/explorer-details-better-file-sizes.wh.cpp

To try it, disable the existing mod, then click the bottom right button to create a new mod, replace the code with the test mod code, click "Compile Mod", then "Exit Editing Mode".

When it injected into every process even hidden console apps it spiked the CPU like crazy.

When enabled for the first time, it needs to do some symbol initialization, so that's expected, but it shouldn't spike the CPU after the initialization is completed at the first time. Can you see if it's an issue after the first initialization is completed?

I can attach the script if you want, not sure if you'll be able to get it stuck like it was for me.

Can you still reproduce it? Does it stuck for a long time (say, 30 seconds or a minute), or for what seems to be forever? What's the status that's shown?

legacy1477 commented 6 days ago

debug.txt

One of the symbols is different in this older Win10 version. Please try this mod version: https://github.com/m417z/my-windhawk-mods/blob/055b82436ccf22eba85c422c0f785e26ba1d8784/mods/explorer-details-better-file-sizes.wh.cpp

To try it, disable the existing mod, then click the bottom right button to create a new mod, replace the code with the test mod code, click "Compile Mod", then "Exit Editing Mode".

It works, thank you.

When it injected into every process even hidden console apps it spiked the CPU like crazy.

When enabled for the first time, it needs to do some symbol initialization, so that's expected, but it shouldn't spike the CPU after the initialization is completed at the first time. Can you see if it's an issue after the first initialization is completed?

Doesn't happen now.

I can attach the script if you want, not sure if you'll be able to get it stuck like it was for me.

Can you still reproduce it? Does it stuck for a long time (say, 30 seconds or a minute), or for what seems to be forever? What's the status that's shown?

I restarted the python process. Seems to be fine now.