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

UX issue with updates #155043

Closed
makemefeelgr8 opened this issue Jul 13, 2022 · 9 comments
Closed

UX issue with updates #155043

makemefeelgr8 opened this issue Jul 13, 2022 · 9 comments
Assignees

Comments

@makemefeelgr8
Copy link

Does this issue occur when all extensions are disabled?: Yes

Version: 1.69.0 (user setup)
Commit: 92d25e3
Date: 2022-07-07T05:28:36.503Z
Electron: 18.3.5
Chromium: 100.0.4896.160
Node.js: 16.13.2
V8: 10.0.139.17-electron.0
OS: Windows_NT x64 10.0.19044

Default template for github issues doesn't even contain a "description" field, just "Steps to reproduce". So, I'll add the description here.

Basically, VS Code never updates properly (tried it on 3 machines already). I bet there have been countless reports like this one, and you've aready came up with a generic response, like "we care but we don't", "use a different installer" or whatnot. There's also an option you'll just close this report instantly and link it to the different issue (which has been hanging there for years). Please, take your time to read the cases. This isssue has been a source of confusion for countless users.

Steps to Reproduce:

Case 1.

  1. Navigate to https://code.visualstudio.com/
  2. Click Download for Windows
  3. It will grab "user installer" by default
  4. Install it in any directory (like, program files, C:/programs, whatever)
  5. Install a lot of extensions, work for about a month
  6. As soon as there's a new update, a "Setup" - "Access is denied" error keeps popping up every few minutes. Extremely misleading!
  7. At this point you're fucked. There's no way to make it work. Every time there's an update you'll have to run VS Code as an admin.

Case 2.

  1. Navigate to https://code.visualstudio.com/
  2. Click Download for Windows
  3. It will grab "user installer" by default
  4. Install it in any directory (like, program files, C:/programs, whatever)
  5. Install a lot of extensions, work for about a month
  6. Get an "Error" - "An error occurred while trying to create a file in the destination directory. Access is denied"
  7. At this point- you've guessed it. Fucked. There's no way to make it work. And if you want to run VS Code as an admin... you close the app, and it disappears from the Start menu, and from context menu!! The only way to run it is the command line!

In case you're like "oh, this guy downloaded the wrong thing, it's obvious"- no, it isn't! Just imagine for a second this happened to a product MS really cares about, like Edge. You open the browser, an error appears, you close it... and it's gone!

And what is the most sad fact about these cases? Those are default ones! You navigate to the website for the 1st time. You see a big download button. You click the default download button. So, you would expect the app to work, wouldn't you? Nope.

Right now, the only way to resolve the issue with updates is to remove VS Code, loose all your extensions, settings, etc. Then, one has to search the website for the specific System installer (the difference is never explained properly). Is this an intended workflow? I bet it's not.

Finally, let me tell you what happens in real life. They either make VS Code always run in admin mode (insecure) or just never update anymore (also insecure).

What I suggest is to add a dialog, like "The setup doesn't have enough permissions to write to the installation directory. Do you want to convert this installation to the system one?" And then one can just click "yes, sure, whatever".

Thanks for reading.

@gjsjohnmurray
Copy link
Contributor

Please clarify whether you perform step 4 (running the installer) using "Run as administrator" or as a regular "Run"?

@gjsjohnmurray
Copy link
Contributor

related: #147408

@gjsjohnmurray
Copy link
Contributor

Based on #148428 another possible scenario is that you initially install normally, then one day launch VS Code as administrator and during that session it finds an update and installs it on exit. Then next time you're running normally when it finds another update it can't install this.

@makemefeelgr8 do you ever run VS Code as administrator?

@makemefeelgr8
Copy link
Author

Please clarify whether you perform step 4 (running the installer) using "Run as administrator" or as a regular "Run"?

For the sake of the experiment, let's do it the way 99.5% of users would do it. Click "download" and then just open the downloaded file. So, no "run as administrator".

do you ever run VS Code as administrator

Yes, as it failed to update in non-admin mode. And before that? Dunno. Running the app as admin shouldn't break anything. Imagine MS Edge updates failed if it was started as admin.

As per #148428 - if you guys actually disable updates for "user mode" installations when launched in admin mode, there would be like no way to update these "failed" installations at all. Sounds like the worst way to handle this issue.

@gjsjohnmurray
Copy link
Contributor

If you perform the steps in #147408 (comment) are you subsequently able to update VS Code when running unelevated?

If so, the hypothesis is that as long as a future auto-update doesn't happen while you are running as administrator, you will continue to be able to update when running unelevated.

@makemefeelgr8
Copy link
Author

If you perform the steps in #147408 (comment) are you subsequently able to update VS Code when running unelevated?

No, as my VS Code is installed in a different folder, not in %LOCALAPPDATA%\Programs\Microsoft VS Code. And right now there's no "broken" vs code installations around, so I can't check if it'll work. And even if it did, it would make no difference whatsoever.

I strongly suggest the issue should be fixed. I'm sure there are hundreds of thousands of users with "broken" permissions. You can't just ask all of them to "go run these commands". How about you make the app execute these commands automatically?

@rzhao271
Copy link
Contributor

Potential duplicate: #147408

@makemefeelgr8
Copy link
Author

Potential duplicate: #147408

No, it's not. This one is about creating an automated way of fixing existing "broken" installations.

@joaomoreno
Copy link
Member

No, as my VS Code is installed in a different folder, not in %LOCALAPPDATA%\Programs\Microsoft VS Code.

The User Setup is meant to be installed in a location your user usually has access to, like %LOCALAPPDATA%. If you intend to install Code in C:\Program Files or similar, please use the System Setup.

This is documented here: https://code.visualstudio.com/docs/setup/windows#_user-setup-versus-system-setup

@joaomoreno joaomoreno closed this as not planned Won't fix, can't repro, duplicate, stale Aug 25, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Oct 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants