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

[File Locksmith] just displays busy circle #21621

Closed
ChrisJohnTaylor opened this issue Nov 2, 2022 · 36 comments
Closed

[File Locksmith] just displays busy circle #21621

ChrisJohnTaylor opened this issue Nov 2, 2022 · 36 comments
Labels
Issue-Bug Something isn't working Product-File Locksmith Refers to the File Locksmith utility Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release.

Comments

@ChrisJohnTaylor
Copy link

Microsoft PowerToys version

0.64.0

Installation method

PowerToys auto-update

Running as admin

Yes

Area(s) with issue?

File Locksmith

Steps to reproduce

  • I opened a PowerPoint file
  • open File Explorer and right-click the PPTX file and choose "What's using this file"
  • File Locksmith opens and the screen just shows the busy, rotating circle. I waited 5 minutes with no change.
  • I also tried on a file that was not opened by any process with the same result
  • I tried rebooting. Same results.

✔️ Expected Behavior

tell me that the file was in use by PowerPoint

❌ Actual Behavior

Just the busy circle

Other Software

No response

@ChrisJohnTaylor ChrisJohnTaylor added Issue-Bug Something isn't working Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams labels Nov 2, 2022
@Aaron-Junker Aaron-Junker added the Product-File Locksmith Refers to the File Locksmith utility label Nov 2, 2022
@ChrisJohnTaylor
Copy link
Author

Follow up on this. When I choose the option "What's using this file", if I look at task Maanger, I see PowerToys.FileLocksmith using between 0.6% and 1.2% CPU on my 8th gen Core-i7. It is using 46.9MB RAM.

@htcfreek
Copy link
Collaborator

htcfreek commented Nov 3, 2022

@ChrisJohnTaylor
Copy link
Author

I should have been clearer ;-)

Although I gave the PowerPoint file as an example, I get the same results for any file type, folders, and groups of files and folders.

I have a second computer where File Locksmith works fine. So it is something local to my desktop computer, but I don't have a clue as to how to track down what is causing the problem. If anyone on the dev team wants me to try various things or provide log files or whatever, I am happy to help in any way I can.

I have tried uninstalling and reinstalling PowerToys.

I have Lock Hunter (https://lockhunter.com/) which does pretty much the same function (tells you what is locking a file and allows you to unlock it) and it is functioning fine. I tried uninstalling Lock Hunter in case (I can't imagine why) it was causing the problem for File Locksmith, but that didn't help

@jaimecbernardo
Copy link
Collaborator

/bugreport to see if we can figure something out.

@jaimecbernardo
Copy link
Collaborator

/bugreport

@ghost ghost removed the Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams label Nov 3, 2022
@ghost
Copy link

ghost commented Nov 3, 2022

Hi there!

We need a bit more information to really debug this issue. Can you add a "Report Bug" zip file here? You right click on our system tray icon and just go to report bug. Then drag the zipfile from your desktop onto the GitHub comment box in this issue. Thanks!
Report Bug

@ghost ghost added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Nov 3, 2022
@ChrisJohnTaylor
Copy link
Author

Thanks, I had no idea how to do a bugreport :-)
PowerToysReport_2022-11-03-13-45-06.zip

@ghost ghost added Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams Needs-Team-Response An issue author responded so the team needs to follow up and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels Nov 3, 2022
@kevinf100
Copy link

I'm getting the exact same problem. Doesn't seem to work with any file in any location.
PowerToysReport_2022-11-04-21-54-37.zip

@fixator10
Copy link

Same here. Process Hacker's "Find Handles and DLLs" finds the process just fine, while File Locksmith seems to search infinitely.
PowerToysReport_2022-11-05-12-51-23.zip

@Church-17
Copy link

Same problem here, Just doesn't work with any types of files.
PowerToysReport_2022-11-05-10-10-06.zip

@ctp9
Copy link

ctp9 commented Nov 7, 2022

Not working here either - except, instead of a busy circle, mine shows "No results" on each file:

File_Locksmith_not_working

Bug report:
PowerToysReport_2022-11-07-05-06-41.zip

@ThioJoe
Copy link

ThioJoe commented Nov 8, 2022

Infinite spinning circle happens to me too, except only in administrator mode, and only with the latest 0.64.1 release. After uninstalling 64.1 and reinstalling 64.0, it works in both user and admin mode again. I'm on an insider build (22621.755) not sure if that is affecting it. For me it happens with any file, whether in use or not.

Here's the bug report using 0.64.1
PowerToysReport_2022-11-08-12-05-43.zip

Funnily enough, I was trying to compile the latest build before the 64.1 was released, and with that it was doing the same thing. I assumed I messed something up when compiling.

I also tried installing PowerToys 0.64.1 in a Windows 11 virtual machine, it works fine in there.

Edit: I've just ran Windows update, now on 22621.819, but no change.

Edit2: I rebooted into safe mode, where I guess everything is run as admin by default. In safe mode, it does not have the infinite spinning problem.

Some additional things I tried:

  • Enabling the default Administrator account and logging into that desktop. There it opens directly to the elevated mode which also keeps spinning forever.
  • Creating a new user account. Same behavior, keeps spinning after escalating.

@PaulGronwald
Copy link

Can confirm it only displaying busy circle (for folders and files) even in elevated state.

But, switching to safe mode, displayed all processes attached.

@Rialtho-the-Magnificent
Copy link

just installed 64.1 as 64.0 also gave the eternal spinning circle, but that did not help. Now I have a zip file which I try to add to this message
PowerToysReport_2022-11-09-11-14-09.zip
hope this helps.

@ChrisJohnTaylor
Copy link
Author

64.1 installed. I am still getting the spinning circle on any file with File Locksmith

LockHunter (https://lockhunter.com/) has no problem
image

PowerToys bug report log attached
PowerToysReport_2022-11-09-07-45-52.zip

@dougwebb
Copy link

PowerToysReport_2022-11-14-12-26-35.zip

Happening to me too. Local admin account, Win10, any file.

@jaimecbernardo
Copy link
Collaborator

Hi @ChrisJohnTaylor , @kevinf100 , @fixator10 , @Church-17 , @ctp9 , @ThioJoe , @Rialtho-the-Magnificent , @dougwebb ,

Could you please try a 0.0.1 x64 dev build so we can try to see if my fix solves this for you? (It's a signed build)
https://github.com/jaimecbernardo/PowerToys/releases/tag/0.0.1-test-fix-locksmith-hanging

Please uninstall your current PowerToys installation, then install this debug build.
Replicate the bug.
Let us know if File Locksmith is working now.
Uninstall this build and install an official release of PowerToys again.

Thank you, in advance.

@ChrisJohnTaylor
Copy link
Author

Hi @jaimecbernardo

Actually, I had updated to 65.0. (it was 64 that I was running when I bugged this originally). I had not checked to see if the problem had been resolved. I just checked and File Locksmith was working for me under 65.0. I installed the 0.0.1 dev build you pointed to and it is still working :-)

I will go back to the release build of 65.0

Thanks!

@kevinf100
Copy link

@jaimecbernardo
v65.0 did not work for me with Locksmith. Uninstalling v65.0 and trying 0.0.1 x64 dev build had Locksmith working.
Uninstalling the dev build and installing v65.0 broke Locksmith again.
v65.0 and older is broken for me.
Dev 0.0.1 works for me.

@Rialtho-the-Magnificent

I'm now on v0.65.0 and still a no go. Only spinning circle both in normal as well as admin mode.

@jaimecbernardo
Copy link
Collaborator

@Rialtho-the-Magnificent , did you try the build I shared in this comment? #21621 (comment)

@Rialtho-the-Magnificent
Copy link

Rialtho-the-Magnificent commented Dec 15, 2022 via email

@ChrisJohnTaylor
Copy link
Author

@Rialtho-the-Magnificent - Pretty harsh! You reported a bug and the developers think they have a fix. They want people who reported the bug to try the fix and see if it works for them. Very professional in my opinion.

@Rialtho-the-Magnificent
Copy link

Rialtho-the-Magnificent commented Dec 15, 2022 via email

@dougwebb
Copy link

Well I'm a developer. Test build works for me, as far as not getting stuck on the spinner. Weirdly on some files it works, such as the firefox.exe file. But with Visual Studio 2022 open in a solution, I tried both the .sln file and a C# file I had open in the editor, and File Locksmith couldn't detect that either one was in use. Maybe that's a new bug, or maybe VS is privileged in some way that's related to whatever you needed to do for the spinner hang.

@Rialtho-the-Magnificent
Copy link

Rialtho-the-Magnificent commented Dec 15, 2022 via email

@ThioJoe
Copy link

ThioJoe commented Dec 15, 2022

No I did not and I'm not willing to do this. I'm just an 'ordinary' user and not a developer or similar. I find it very unprofessional to even come up with this type of solution.

@Rialtho-the-Magnificent 🤡🤡🤡

Untitled-1

@jaimecbernardo Anyway the 0.65 release version actually works fine for me, but I tried your test build and that worked fine also. Though for me the problem only was when running as admin, so not sure if it was a slightly different issue than the others who had it spinning no matter what.

@jaimecbernardo jaimecbernardo added Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release. and removed Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams Needs-Team-Response An issue author responded so the team needs to follow up labels Dec 16, 2022
@jaimecbernardo
Copy link
Collaborator

Hi,
It's OK for users to distrust a build that's not release through official channels :)
We've got enough tests anyway. Thanks a lot for helping out here. ;)
The fix has been merged and should be out in the next release.
Please remember to uninstall the dev build I sent and install an official release again.

@Rialtho-the-Magnificent
Copy link

Rialtho-the-Magnificent commented Dec 16, 2022 via email

@Rialtho-the-Magnificent
Copy link

Rialtho-the-Magnificent commented Dec 16, 2022 via email

@kevinf100
Copy link

kevinf100 commented Dec 16, 2022

@Rialtho-the-Magnificent
#22806

It's not clear in what conditions this happens, so the work was offloaded to a different thread, which is destroyed and resumed if getting the information for a specific handle takes too long.

Also in the code
// The system calls we use in this block were reported to hang on some machines.
// We need to offload the cycle to another thread and keep track of progress to terminate and resume when needed.

Mutithreading was the problem basically. It is assumed the thread working on getting the file lock was blocked or terminated/destroyed before it finished.

@Jay-o-Way
Copy link
Collaborator

So this can be closed, right?

@Rialtho-the-Magnificent
Copy link

Yes, seems to work with latest version. Even on a file in my Google drive (although it resides off course on my pc)

image

@Jay-o-Way
Copy link
Collaborator

Thanks for confirming.
En succes met het verhuizen :⁠-⁠)

@kevinf100
Copy link

Can also confirm this works now with the latest update.

@ChrisJohnTaylor
Copy link
Author

It is working for me too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug Something isn't working Product-File Locksmith Refers to the File Locksmith utility Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release.
Projects
None yet
Development

No branches or pull requests