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

vsCode settings are not updated #432

Closed
maybeec opened this issue Jul 15, 2020 · 14 comments · Fixed by #445
Closed

vsCode settings are not updated #432

maybeec opened this issue Jul 15, 2020 · 14 comments · Fixed by #445
Labels
bug Something isn't working configurator related to our configurator tool that manages IDE settings for Eclipse, Intellij, vscode, etc. help wanted Extra attention is needed settings ide-settings repo and replated processes and features vscode Microsoft visual studio code

Comments

@maybeec
Copy link
Member

maybeec commented Jul 15, 2020

Expected behavior

As a developer, I want to share vsCode settings so that everyone in my team works for example with the same linting settings.

Actual behavior

I updated the settings in settings/vscode/workspace/update/.vscode/settings.json and ran devon ide update all, but the settings are not updated. Even on a fresh installation, the settings are not propagated to the user settings.

Steps to reproduce (bug) / Use Case of feature request (enhancement)

  1. Create a settings file in settings/vscode/workspace/update/.vscode/settings.json of your current IDE installation with the content { "tslint.autoFixOnSave": true }.
  2. Run devon ide update all
  3. The user settings file in conf/vscode/User/settings.json will not contain the new or update value.

Related/Dependent Issues

Comments/Hints:

Affected version:

  • OS: Windows
@maybeec maybeec added bug Something isn't working settings ide-settings repo and replated processes and features vscode Microsoft visual studio code labels Jul 15, 2020
@hohwille hohwille added the configurator related to our configurator tool that manages IDE settings for Eclipse, Intellij, vscode, etc. label Jul 28, 2020
@hohwille
Copy link
Member

@maybeec thanks for reporting the issue.
Can you check some things:

  • Do you have vscode configured in DEVON_IDE_TOOLS?
  • Is the configurator (the Java programm that updates/merges the settings) actually called by devon ide update all?

@maybeec
Copy link
Member Author

maybeec commented Jul 28, 2020

Hi @hohwille, we configured DEVON_IDE_TOOLS=(java mvn eclipse vscode node npm ng)

I am not sure whether this progam is running. At least I cannot see anything on the logs:

*** Software Update of devonfw-ide-scripts ***
Updating /c/project from https://repo.maven.apache.org/maven2/com/devonfw/tools/ide/devonfw-ide-scripts
Trying to determine the latest available version from https://repo.maven.apache.org/maven2/com/devonfw/tools/ide/devonfw-ide-scripts/maven-metadata.xml
The devonfw-ide-scripts package is already at the correct version 2020.04.004
Already up to date.

*** Setting up java ***
Version 1.8.0_181 of java is already installed.
java version "1.8.0_181"
Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)

*** Setting up mvn ***
Version 3.6.2 of maven is already installed.
Apache Maven 3.6.2 (40f52333136460af0dc0d7232c0dc0bcf0d9e117; 2019-08-27T17:06:16+02:00)
Maven home: C:\project\software\maven
Java version: 1.8.0_181, vendor: Oracle Corporation, runtime: C:\project\software\java\jre
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"

*** Setting up eclipse ***
Version 2020-03-custom-2 of eclipse is already installed.
name=Eclipse Platform
id=org.eclipse.platform
version=4.15.0
Created script /c/project/eclipse-main.bat

*** Setting up vscode ***
Version 1.44.1 of vscode is already installed.

******** ATTENTION ********
Installing plugin (natewallace.angular2-inline) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (danwahlin.angular2-snippets) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (johnpapa.angular2) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (MarinhoBrandao.angular2tests) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (steoates.autoimport) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (marlon407.code-groovy) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (streetsidesoftware.code-spell-checker) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (msjsdiag.debugger-for-chrome) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (dcortes92.freemarker) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (waderyan.gitblame) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (donjayamanne.githistory) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (zignd.html-css-class-completion) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
Installing extensions...
Installing extensions...
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:30:20
    at FSReqCallback.oncomplete (fs.js:153:23)
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension MarinhoBrandao.angular2testsFailed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension steoates.autoimportFailed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension danwahlin.angular2-snippetsFailed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension marlon407.code-groovy
******** ATTENTION ********resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
ERROR: Failed to run command '/c/project/software/vscode/bin/code'******** ATTENTION ********
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.ailed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/Exit code was 1o run command '/c/project/software/vscode/bin/code'ngular2i.log for writing: Permission denied
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.\index.js:34:9)
ERROR: Failed to run command '/c/project/software/vscode/bin/code'spdlog\index.js:27:7
Exit code was 1ION ********vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
Exit code was 1

******** ATTENTION ********
Installing plugin (cmstead.jsrefactor) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (christian-kohler.path-intellisense) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension streetsidesoftware.code-spell-checker

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
Installing extensions...
Extension 'natewallace.angular2-inline' is already installed.

******** ATTENTION ********
Installing plugin (eg2.tslint) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155543\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension dcortes92.freemarker

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1il VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
Installing extensions...
Extension 'msjsdiag.debugger-for-chrome' is already installed.

******** ATTENTION ********
Installing plugin (peterjausovec.vscode-docker) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155544\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension donjayamanne.githistory

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1

******** ATTENTION ********
Installing plugin (DSKWRK.vscode-generate-getter-setter) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155544\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Extension 'waderyan.gitblame' is already installed.
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension zignd.html-css-class-completion

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
******** ATTENTION ********
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.Installing plugin (vscode-icons-team.vscode-icons) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension cmstead.jsrefactor
               ^
******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'5544\cli.log for writing: Permission denied
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.\index.js:34:9)
Exit code was 1IA\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
******** ATTENTION ********lete (fs.js:166:5)
Installing plugin (mrmlnc.vscode-less) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.

******** ATTENTION ********
Installing plugin (eg2.vscode-npm-script) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
Installing extensions...
Installing extensions...
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155545\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension eg2.tslint

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1

******** ATTENTION ********
Installing plugin (dbalage.vscode-stylesheet-formatter) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
Installing extensions...
Extension 'christian-kohler.path-intellisense' is already installed.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155546\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)

******** ATTENTION ********
Installing plugin (minhthai.vscode-todo-parser) into VS code...
Please wait until VSCode has successfully installed all plugins.
You may then use or close VSCode as you like.
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension peterjausovec.vscode-docker

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
Created script /c/project/vscode-main.bat

*** Setting up node ***
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155546\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Extension 'jakethashi.vscode-angular2-emmet' is already installed.
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension DSKWRK.vscode-generate-getter-setter

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
Installing extensions...
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155547\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension mrmlnc.vscode-less

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155547\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension eg2.vscode-npm-script

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
Version v12.16.2 of nodejs is already installed.
Installing extensions...
Extension 'vscode-icons-team.vscode-icons' is already installed.
C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34
        return new spdlog.Logger('rotating', name, filepath, maxFileSize, maxFiles);
               ^

Error: Failed opening file C:\project\conf\vscode\logs\20200728T155548\cli.log for writing: Permission denied
    at createRotatingLogger (C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:34:9)
    at C:\project\software\vscode\resources\app\node_modules.asar\spdlog\index.js:27:7
    at C:\project\software\vscode\resources\app\node_modules.asar\mkdirp\index.js:48:26
    at FSReqCallback.oncomplete (fs.js:166:5)
Failed to run command: '/c/project/software/vscode/bin/code' --new-window --user-data-dir '/c/project/conf/vscode' --extensions-dir '/c/project/software/vscode-extensions' --force --install-extension minhthai.vscode-todo-parser

******** ATTENTION ********
ERROR: Failed to run command '/c/project/software/vscode/bin/code'
We are sorry for the inconvenience. Please check the above errors, resolve them and try again.
Exit code was 1
v12.16.2

*** Setting up npm ***
Extension 'dbalage.vscode-stylesheet-formatter' is already installed.
npm is already installed at /c/project/software/node/npm

*** Setting up ng ***
angular-cli (ng) is already installed at /c/project/software/node/ng

...

@hohwille
Copy link
Member

hohwille commented Jul 30, 2020

@maybeec thanks for sharing all these additional details. 👍
To me it seems there are multiple errors:

  • Installing/updating of VS Code extensions is not working:
Error: Failed opening file C:\project\conf\vscode\logs\20200728T155542\cli.log for writing: Permission denied

Can you check your disc if that file exists and is writable?

  • configurator is not run to update the "workspace" (user-data-dir). Maybe because of the previous error, maybe not. We have to check this. What happens if you run devon vscode now? Wont it update your workspace before launching VS Code?

FYI: I am not a user of VS Code as my main IDE is Eclipse. We would need more invonvement here from users of other IDEs to get IntelliJ and VS Code properly supported...

@hohwille
Copy link
Member

From the shell-script code I checked/verified that whenever VS Code is launched via devon command in advance the config sync will take place:

So maybe the expectation that devon ide update is doing this is just wrong (or a new demand/requirement). However, as the idea is that devonfw-ide acts as a wrapper for the tools and does several advanced things, users shall not bypass the devon command and expect everything to work. So if VS Code itself is buggy and can not write log files and therefore aborts invocation there is quite little we can do about it now. Maybe we can find out more details why Permission denied ocurrs on your machine. I have no clue and a test on my machine did not cause this problem.

@hohwille hohwille added the help wanted Extra attention is needed label Jul 30, 2020
@maybeec
Copy link
Member Author

maybeec commented Jul 30, 2020

The log issue might be related to microsoft/vscode#64897

@maybeec
Copy link
Member Author

maybeec commented Jul 30, 2020

Reading the logs once more, it seems that the installation is done asynchronously which causes multiple installation processes being spawned in parallel it seems. Maybe we'll find a way to do it synchronously.

@markusschuh
Copy link
Member

markusschuh commented Jul 31, 2020

Even when

is called, the

doConfigureWorkspace "${SETTINGS_PATH}/vscode/workspace" "${WORKSPACE_PATH}" "${mode}"

therein is only called, when

if [ ! -d "${WORKSPACE_PATH}/.vscode" ]

is true. Means, it sync from settings directory when directory "${WORKSPACE_PATH}/.vscode" does not exist.

If the directory already exists, it needs an explicit `call of

devon vscode ws-up

to update the settings.

At least that is, what I see in the script code. And this need for an explicit ws-update call (for an already existing setting) is a good design, IMHO. Any change other than the initial should not be an implicit side effect of just opening the IDE.

I personally also would have expected, the initial sync from settings is done during a call of idevon de update settings, since just updating the settings from some central repository to the local settings directory seems a somehow incomplete task for me. But I may miss something here.

@maybeec
Copy link
Member Author

maybeec commented Jul 31, 2020

No I think settings should be updated as well on Devon ide update all. This would be consistent to what eclipse settings are doing and it is even more important if you want to roll out some new settings to your team.

Regarding the plugin installation I found a fix which I will soon provide as a pr.

@maybeec
Copy link
Member Author

maybeec commented Aug 2, 2020

I think

if [ ! -d "${WORKSPACE_PATH}/.vscode" ]

is the problem. There are global settings and project specific settings. Project specific settings can be easily committed with the project into git in the .vscode folder right in the source code. It seems, that this line of code is addressing this .vscode folder, which does not make sense to me. Instead, the folder on conf/.vscode is the critical folder to be updated.

Maybe the intention of not updating conf/.vscode is related to the fact, that also conf/.m2/settings.xml cannot be updated as well. Anyhow, for vsCode this would be a more frequently changed file, which we should try to keep up to date by scripts.

@hohwille
Copy link
Member

I can try to create a PR to fix the rest of this issue. IMHO this should be analogue to eclipse so when vscode is launched, the settings are updated.

@hohwille
Copy link
Member

hohwille commented Aug 18, 2020

Current observations are not entirely correct about this:

if [ ! -d "${WORKSPACE_PATH}/.vscode" ]

If the workspace (.vscode) does not exist, an update of the settings is enforced while other modes (like reverse-merge) will fail (as there is no workspace yet).
However, in any case after this if the workspace settings are updated (unless mode is not defined):

doConfigureWorkspace "${SETTINGS_PATH}/vscode/workspace" "${WORKSPACE_PATH}" "${mode}"

So the actual error is just, that -u is not provided as argument here:

Like it is done for eclipse:

So trivial fix, but not so easy to trace down...

@hohwille
Copy link
Member

I created a PR with the according fix.
As already stated the expectation of this issue is not met by devonfw-ide (by design): on devon ide update the workspaces are not automatically updated. However, whenever an IDE like Eclipse or VS code is launched, the workspace shall be updated. This did not work for VS code when the workspace already existed before.

However, now I am facing the next error with the expected config provided in the steps to reproduce:

2020-08-18T09:55:12.952+02:00 [SEVERE ] Undefined JSON type: true
2020-08-18T09:55:12.961+02:00 [SEVERE ] Configurator failed: Value in JsonObjects name/value pair cannot be null
java.lang.NullPointerException: Value in JsonObjects name/value pair cannot be null
	at org.glassfish.json.JsonObjectBuilderImpl.validateValue(JsonObjectBuilderImpl.java:222)
	at org.glassfish.json.JsonObjectBuilderImpl.add(JsonObjectBuilderImpl.java:82)
	at com.devonfw.tools.ide.configurator.merge.JsonMerger.mergeAndResolveObject(JsonMerger.java:155)

I have to dig what is causing this error. Actually boolean literals like true and false are fundamentals of JSON so I am confused that glassfish JSON impl suffers here...

@hohwille
Copy link
Member

I extended the JUnit tests with this "tslint.autoFixOnSave": true and pushed to my PR #445.
However, within JUnit it is working fine. Only when invoked from commandline it is failing.
Some dependency missing for JSON to be functional? I am still very confused... Any help or hint would be highly appreciated.

@hohwille
Copy link
Member

OK, analysis completed: I was chasing a legacy error as for my testing I am using symlinks to the most recent devonfw-ide sources. As this is not working for the JARs in the lib folder that get deleted by maven and have chaning version numbers, I manually copy devonfw-ide-configurator-*.jar to my lib folder. I have missed this for a long while and therefore was testing very outdated code. All resolved. Will merge the PR and close this issue...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working configurator related to our configurator tool that manages IDE settings for Eclipse, Intellij, vscode, etc. help wanted Extra attention is needed settings ide-settings repo and replated processes and features vscode Microsoft visual studio code
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants