Skip to content

vscode warning: matches multiple schemas when only one must validate #3909

@carpet92

Description

@carpet92

I use VSCode to edit profiles.json settings file.

My config looks this:

// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
// https://github.com/microsoft/terminal/blob/master/doc/cascadia/SettingsSchema.md

{
    "$schema": "https://aka.ms/terminal-profiles-schema",

    "defaultProfile": "{c6eaf9f4-32a7-5fdc-b5cf-066e8a4b1e40}",

    "initialCols": 120,
    "initialRows": 30,

    "requestedTheme": "system",

    "profiles":
    [
        {
            // Make changes here to the powershell.exe profile
            "useAcrylic": true,
            "acrylicOpacity": 0.5,
            "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
            "name": "Windows PowerShell 6",
            "commandline": "C:\\Program Files\\PowerShell\\6\\pwsh.exe",
            "colorScheme": "Solarized Dark cmd-colors",
            "padding": "20, 10, 20, 20",
            "fontFace": "Cascadia Code",
            "fontSize": 12,
            "cursorShape": "filledBox",
            "hidden": false
        },
        {
            // Make changes here to the cmd.exe profile
            "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
            "name": "cmd",
            "commandline": "cmd.exe",
            "hidden": false
        },
        {
            "useAcrylic": true,
            "acrylicOpacity": 0.5,
            "guid": "{c6eaf9f4-32a7-5fdc-b5cf-066e8a4b1e40}",
            "hidden": false,
            "name": "🤘 Ubuntu-18.04",
            "commandline": "wsl -d Ubuntu-18.04",
            "snapOnInput" : false, // scroll back to the command input line when typing
            "cursorColor": "#FFFFFF",
            "colorScheme": "UbuntuLegit",
            "source": "Windows.Terminal.Wsl",
            "padding": "20, 10, 20, 20",
            "fontFace": "Cascadia Code",
            "fontSize": 12,
            "cursorShape": "filledBox"
        },
        {
            "guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}",
            "hidden": true,
            "name": "Azure Cloud Shell",
            "source": "Windows.Terminal.Azure"
        },
        {
            "guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
            "hidden": true,
            "name": "PowerShell Core",
            "source": "Windows.Terminal.PowershellCore"
        }
    ],

    // Add custom color schemes to this array
    "schemes": [{
        "background" : "#002B36",
        "black" : "#073642",
        "blue" : "#268BD2",
        "brightBlack" : "#002B36",
        "brightBlue" : "#839496",
        "brightCyan" : "#93A1A1",
        "brightGreen" : "#586E75",
        "brightPurple" : "#6C71C4",
        "brightRed" : "#CB4B16",
        "brightWhite" : "#FDF6E3",
        "brightYellow" : "#657B83",
        "cyan" : "#2AA198",
        "foreground" : "#839496",
        "green" : "#859900",
        "name" : "Solarized Dark",
        "purple" : "#D33682",
        "red" : "#DC322F",
        "white" : "#EEE8D5",
        "yellow" : "#B58900"
    },
    {
        "background": "#002B36",
        "brightBlack": "#073642",
        "brightBlue": "#268BD2",
        "black": "#002B36",
        "blue": "#839496",
        "cyan": "#93A1A1",
        "green": "#586E75",
        "purple": "#6C71C4",
        "red": "#CB4B16",
        "white": "#FDF6E3",
        "yellow": "#657B83",
        "brightCyan": "#2AA198",
        "foreground": "#839496",
        "brightGreen": "#859900",
        "name": "Solarized Dark cmd-colors",
        "brightPurple": "#D33682",
        "brightRed": "#DC322F",
        "brightWhite": "#EEE8D5",
        "brightYellow": "#B58900"
    },
    {
        "background" : "#FDF6E3",
        "black" : "#073642",
        "blue" : "#268BD2",
        "brightBlack" : "#002B36",
        "brightBlue" : "#839496",
        "brightCyan" : "#93A1A1",
        "brightGreen" : "#586E75",
        "brightPurple" : "#6C71C4",
        "brightRed" : "#CB4B16",
        "brightWhite" : "#FDF6E3",
        "brightYellow" : "#657B83",
        "cyan" : "#2AA198",
        "foreground" : "#073642",
        "green" : "#859900",
        "name" : "Solarized Light",
        "purple" : "#D33682",
        "red" : "#D30102",
        "white" : "#EEE8D5",
        "yellow" : "#B58900"
    },
    {
        "background" : "#2C001E",
        "black" : "#4E9A06",
        "blue" : "#3465A4",
        "brightBlack" : "#555753",
        "brightBlue" : "#729FCF",
        "brightCyan" : "#34E2E2",
        "brightGreen" : "#8AE234",
        "brightPurple" : "#AD7FA8",
        "brightRed" : "#EF2929",
        "brightWhite" : "#EEEEEE",
        "brightYellow" : "#FCE94F",
        "cyan" : "#06989A",
        "foreground" : "#EEEEEE",
        "green" : "#300A24",
        "name" : "UbuntuLegit",
        "purple" : "#75507B",
        "red" : "#CC0000",
        "white" : "#D3D7CF",
        "yellow" : "#C4A000"
    }],

    // Add any keybinding overrides to this array.
    // To unbind a default keybinding, set the command to "unbound"
    "keybindings": []
}

I noticed that VSCode shows warning:

{
	"resource": "/c:/Users/User/AppData/Local/Packages/Microsoft.WindowsTerminal_8wekyb3d8bbwe/LocalState/profiles.json",
	"owner": "_generated_diagnostic_collection_name_#0",
	"severity": 4,
	"message": "Matches multiple schemas when only one must validate.",
	"startLineNumber": 17,
	"startColumn": 5,
	"endLineNumber": 17,
	"endColumn": 6
}

Screenshot:

Screenshot (363)

Is there something wrong with my profiles.json?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area-SchemaThings that have to do with the json schema.Area-SettingsIssues related to settings and customizability, for console or terminalIssue-BugIt either shouldn't be doing this or needs an investigation.Needs-Tag-FixDoesn't match tag requirementsPriority-2A description (P2)Product-TerminalThe new Windows Terminal.Resolution-Fix-CommittedFix is checked in, but it might be 3-4 weeks until a release.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions