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

User level "settings.json" is ignore if a local ".vscode/settings.json" sqltools.connections block exists #872

Open
1 of 5 tasks
mc-zact opened this issue Oct 5, 2021 · 0 comments
Labels

Comments

@mc-zact
Copy link

mc-zact commented Oct 5, 2021

Describe the bug
A clear and concise description of what the bug is.

I noticed that trying to add global connections in the user settings.json was not working, but adding via wizard which adds them in the workspace level did.

After removing the SQL tools block from settings and reloading I now see the global connections.

To Reproduce
Steps to reproduce the behavior:

  1. Edit you User settings.json and add a sample connection, i.e.:
"sqltools.connections": [
        {
            "mysqlOptions": {
                "authProtocol": "default"
            },
            "previewLimit": 50,
            "server": "localhost",
            "port": 3306,
            "askForPassword": false,
            "driver": "MySQL",
            "name": "TEST-1",
            "group": "TEST",
            "username": "username",
            "socketPath": "/tmp/cloud_sql_proxy/sokcet",
        },
        {
            "mysqlOptions": {
                "authProtocol": "default"
            },
            "previewLimit": 50,
            "server": "localhost",
            "port": 3306,
            "askForPassword": true,
            "driver": "MySQL",
            "name": "TEST-2",
            "group": "TEST",
            "username": "username",
            "socketPath": "/tmp/cloud_sql_proxy/sokcet"
        }
    ]

Now add a connection via the Wizard, this will save it in the workspace folder (.vscode/settings.json), the connections added in the global config will go away

Expected behavior
Both should show, perhaps grouped by "Global"/"Local", or if this is an intentional feature, perhaps make it optional. On that subject when adding via wizard it would be ideal to state this is being added in the workspace not user (oh btw, if you client "edit settings.json it actually defaults to the user one, which is a bit confusing)

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • SQLTools Version 0.23.0
  • VSCode Version: 1.60.2
  • OS: macOS
  • Driver:
    • PostgreSQL/Redshift
    • MySQL/MariaDB
    • MSSQL/Azure
    • SQLite
    • Other? Which...
  • Database version: [e.g. MySQL v5.6, PostgreSQL vX...]

Additional context
Add any other context about the problem here.

@mc-zact mc-zact added the triage label Oct 5, 2021
@gjsjohnmurray gjsjohnmurray changed the title User level "settings.json" is ignore if a local ".vsocde/settings.json" sqltools.connections block exists User level "settings.json" is ignore if a local ".vscode/settings.json" sqltools.connections block exists Sep 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant