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

Unable to download vscode in terminal #190220

Closed
chouzz opened this issue Aug 11, 2023 · 4 comments
Closed

Unable to download vscode in terminal #190220

chouzz opened this issue Aug 11, 2023 · 4 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug *duplicate Issue identified as a duplicate of another issue(s)

Comments

@chouzz
Copy link
Contributor

chouzz commented Aug 11, 2023

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

  • VS Code Version: 1.81.0
  • OS Version: windows 11

Steps to Reproduce:

  1. create an new vscode extension in command line in windows11
yo code
  1. Open vscode and disable all installed extension
  2. open pwsh terminal and run npm run test
  3. the logs show it can't rename vscode-win32-x64-archive-1.81.1.tmp to vscode-win32-x64-archive-1.81.1

full logs:

PS D:\src\samples\typescript\extension-test> npm run coverage

> [email protected] coverage
> c8 --check-coverage npm run test


> [email protected] pretest
> npm run compile-tests && npm run compile && npm run lint


> [email protected] compile-tests
> tsc -p . --outDir out


> [email protected] compile
> webpack

    [webpack-cli] Compiler starting... 
    [webpack-cli] Compiler is using config: 'D:\src\samples\typescript\extension-test\webpack.config.js'
    [webpack-cli] Compiler finished
asset extension.js 6.47 KiB [emitted] (name: main) 1 related asset
cacheable modules 4.77 KiB
  ./src/extension.ts 1.62 KiB [built] [code generated]
  ./src/utils.ts 3.14 KiB [built] [code generated]
external "vscode" 42 bytes [built] [code generated]
external "path" 42 bytes [built] [code generated]
external "url" 42 bytes [built] [code generated]
webpack 5.88.2 compiled successfully in 2918 ms

> [email protected] lint
> eslint src --ext ts


> [email protected] test
> node ./out/test/runTest.js

(node:43124) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.
(Use `node --trace-warnings ...` to show where the warning was created)
Downloading VS Code 1.81.1 from https://update.code.visualstudio.com/1.81.1/win32-x64-archive/stable
Downloading VS Code [==============================] 100%
Error downloading, retrying (attempt 1 of 3): EPERM: operation not permitted, rename 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1.tmp' -> 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1'
Downloading VS Code 1.81.1 from https://update.code.visualstudio.com/1.81.1/win32-x64-archive/stable
Downloading VS Code [==============================] 100%
Error downloading, retrying (attempt 3 of 3): EPERM: operation not permitted, rename 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1.tmp' -> 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1'
Downloading VS Code 1.81.1 from https://update.code.visualstudio.com/1.81.1/win32-x64-archive/stable
Downloading VS Code [==============================] 100%[Error: EPERM: operation not permitted, rename 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1.tmp' -> 'D:\src\samples\typescript\extension-test\.vscode-test\vscode-win32-x64-archive-1.81.1'] {
  errno: -4048,
  code: 'EPERM',
  syscall: 'rename',
  path: 'D:\\src\\samples\\typescript\\extension-test\\.vscode-test\\vscode-win32-x64-archive-1.81.1.tmp',
  dest: 'D:\\src\\samples\\typescript\\extension-test\\.vscode-test\\vscode-win32-x64-archive-1.81.1'
}
Failed to run tests

Screenshot:

image

@chouzz chouzz changed the title Unable to download vscode test instance during npm run test Unable to download in vscode terminal Aug 11, 2023
@chouzz chouzz changed the title Unable to download in vscode terminal Unable to download vscode in terminal Aug 11, 2023
@dsyx
Copy link

dsyx commented Aug 24, 2023

+1

@connor4312 connor4312 added the bug Issue identified by VS Code Team member as probable bug label Aug 24, 2023
@dsyx
Copy link

dsyx commented Aug 25, 2023

@chouzz

Manually renaming the vscode-win32-x64-archive-1.81.1.tmp directory to vscode-win32-x64-archive-1.81.1 can temporarily resolve this issue.

Note: If you have opened the project in VSCode, you need to close VSCode first.

@chouzz
Copy link
Contributor Author

chouzz commented Aug 26, 2023

@dsyx Sure. Apparently, another process in vscode might be using the file, thereby preventing the renaming operation, that's why I created the issue.

@connor4312
Copy link
Member

Merging into microsoft/vscode-test#233

@connor4312 connor4312 added the *duplicate Issue identified as a duplicate of another issue(s) label Oct 5, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Nov 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug *duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests

5 participants