vscode-yaml
vscode-yaml copied to clipboard
Valid bamboo.yaml gets [Incorrect type. Expected "job"] error.
Summary
I receive vscode-yaml exception when I am using official Bamboo key for specifying "branch-overrides". The error itself is Incorrect type. Expected "job" error.
Relevant information
My vsCode:
Version: 1.60.2 (user setup)
Commit: 7f6ab5485bbc008386c4386d08766667e155244e
Date: 2021-09-22T12:00:31.514Z (1 wk ago)
Electron: 13.1.8
Chrome: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.19043
My bamboo.yaml file:
---
version: 2
plan:
project-key: ROCKET
name: Launch Rocket
key: LAUNCH
stages:
- Default stage:
- Default job
Default job:
tasks:
- script: echo 'Default job'
- clean
branch-overrides:
-
integration-branch:
stages:
- Different stage:
- Different job
Different job:
tasks:
- script: echo 'Override job'
The whole part "branch-overrides" is underlined with all its sub elements, even though it is valid YAML and valid bamboo plan. Following variant also gives issue:
branch-overrides:
- integration-branch:
stages:
- Different stage:
- Different job
Different job:
tasks:
- script: echo 'Override job'
Issue disappears only when I remove first dash
branch-overrides:
integration-branch:
stages:
- Different stage:
- Different job
Different job:
tasks:
- script: echo 'Override job'
This extension provides generic YAML support and It is very hard for us to assess issues on many different schemas and usages. Can you provide instructions on how the bamboo.yaml is associated with a schema?
Hello, the bamboo.yaml is associated with schema https://json.schemastore.org/bamboo-spec.json at least according vscode code actions menu. I am not sure however on how exactly the association works - if I understood your question correctly of course (sorry, not a native english speaker)