-
Notifications
You must be signed in to change notification settings - Fork 511
Extension commands loaded in PowerShell profile are not being registered #396
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
Comments
I might have broken something here, will investigate for 0.8.1 |
Same issue here. I think it happened on upgrading VSCode-PowerShell from 0.7.2 to 0.8.0. Upgrading VSCode itself to 1.8.0 did not cause this problem. |
@daviwil same on my work desktop. Let me know if I can help with anything else or could help test any changes. |
I just checked it, looks like I broke profile loading in general. Looking into it now |
Profile loading is fine, was just testing with the wrong profile path :/ This looks like it's caused by an event sequence I hadn't accounted for when I totally redesigned the extension code. Fixed it, PR incoming! I'll be shipping an update in the next couple of days so this fix will go out with it. |
@daviwil yeah, was going to say that this also doesn't work when using f8 or running the register command either. Profile is running and commands output as being registered, but not showing up as having any registered. Anyway I can get the fix for my local build for the time being? I may have to revert to previous version if not. Totally kills my workflow without them lol. |
@gerane It should be working when you use F8 on an editor command registration after the profile has been loaded. Are you saying it isn't working in that case? Here's a preview drop, I didn't bump the version number so you might need to uninstall the existing 0.8.0: Rename .zip to .vsix and use the VSIX installation command in VS Code. |
@daviwil ok, that is working now actually. It wasn't working on my laptop though. |
@daviwil is there a cli for installing a vsix, or only the one in the GUI? |
I've only seen the one in the GUI, not sure if they give a CLI path. |
@daviwil I may see if just highlighting and running one works out. When I registered one, they all were visible. I couldn't get that to work on my laptop, but this is likely ok for me until you get that fix out. I can test that one if you need me to though. |
I'm pretty sure highlighting and running will work. The only problem I saw in the code was when the commands are registered in your profile, the registration events happen too early for the extension command code in the extension to catch them. |
@daviwil hmm, let me retest. Just noticed the window I was in still had 7.2 loaded and hadn't been reloaded since the update |
@daviwil yeah, running f8 still doesn't register the commands. |
@daviwil let me grab that zip and try that out. |
If it doesn't work, grab logs and send them to me? |
@daviwil Yup, that worked. However, highlight + f8 didn't work prior to the fix. I tested f8 as well just to make sure, and it works with the changes. |
@daviwil Now to test out multi select =) EDIT: multi select is awesome! |
Fix #396: Extension commands loaded in profile are not being registered
System Details
$PSVersionTable
:Issue Description
When trying to load the Editor Command menu, v8.0 throws the following error
No extension commands have been loaded into the current session.
The logs show that my Editor Commands were successfully registered. They are in my VSCode profile.
Attached Logs
Here are the logs Gist
The text was updated successfully, but these errors were encountered: