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

[PowerToys Run] Enabling PT Run from settings takes a few seconds to reflect in the json file #6676

Closed
arjunbalgovind opened this issue Sep 17, 2020 · 10 comments
Assignees
Labels
Issue-Bug Something isn't working Product-PowerToys Run Improved app launch PT Run (Win+R) Window Product-Settings The standalone PowerToys Settings application Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Milestone

Comments

@arjunbalgovind
Copy link
Contributor

arjunbalgovind commented Sep 17, 2020

β„Ή Computer information

  • PowerToys version: master (85c0eaa)
  • PowerToy Utility: Settings/PT Run
  • Running PowerToys as Admin: No
  • Windows build number: [run "winver"] 2004

πŸ“ Provide detailed reproduction steps (if any)

  1. Enable PT Run and disable it.
  2. Check the general settings.json file

βœ”οΈ Expected result

What is the expected result of the above steps?
File gets updated immediately with "PowerToys Run":false.

❌ Actual result

What is the actual result of the above steps?
File takes a few seconds to get updated.

This bug seems to only occur for PT Run, and enabling works fine, its only disabling which has this delay. It seems like this happens because at the same time PowerLauncher.exe is loading, and it might be waiting for the load to complete for some reason. We should ideally ensure this update happens independently and isn't blocked by the update on PowerLauncher.
The end-user effect is that if a user disable PT Run and closes PT within 5 seconds the setting will not persist and PT Run will still be enabled on re-launching PT.

@arjunbalgovind arjunbalgovind added Issue-Bug Something isn't working Product-PowerToys Run Improved app launch PT Run (Win+R) Window Product-Settings The standalone PowerToys Settings application labels Sep 17, 2020
@ghost ghost added the Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams label Sep 17, 2020
@arjunbalgovind
Copy link
Contributor Author

@crutkas
Copy link
Member

crutkas commented Sep 17, 2020

Is the enable disable bug fixed in master yet?

@arjunbalgovind
Copy link
Contributor Author

Not yet, but it's independent of that PR.

@crutkas
Copy link
Member

crutkas commented Sep 17, 2020

Look at #6620 and see what the impact of that fix will have on this.

@arjunbalgovind
Copy link
Contributor Author

#620 doesn't fix this, I first reproduced this while testing that PR, but found that it is present on master as well.

@crutkas
Copy link
Member

crutkas commented Sep 17, 2020

Good to know, same area which is why I asked :)

@crutkas crutkas added this to the InVEST-2009 milestone Sep 18, 2020
@crutkas
Copy link
Member

crutkas commented Sep 18, 2020

I'm going to put this into the current release as it is unclear why this is having the issue but others are not which makes me wonder if there is some type of bug

@arjunbalgovind arjunbalgovind self-assigned this Sep 18, 2020
@dsrivastavv
Copy link
Contributor

@arjunbalgovind This issue is happening because WaitForSingleObject is used here , which blocks the calling thread until WPF app is terminated. Replacing it with RegisterWaitForSingleObject should fix this issue.

@crutkas
Copy link
Member

crutkas commented Sep 18, 2020

if that is the case, this should be a super easy fix if it is a single line #famousLastWords

@arjunbalgovind arjunbalgovind added the Status-In progress This issue or work-item is under development label Sep 18, 2020
@crutkas crutkas removed the Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams label Sep 21, 2020
@arjunbalgovind
Copy link
Contributor Author

Closing this as duplicate against #5860, since fixing that will also fix this issue.

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-PowerToys Run Improved app launch PT Run (Win+R) Window Product-Settings The standalone PowerToys Settings application Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

3 participants