"3 validation errors for PipelineSpec" for a pipeline that is working in the cloud
Closed this issue · 1 comments
M-Ahal commented
The error below is too obscure. The pipeline has been working the cloud, so I would guess that that is valid.
Error: Invalid pipelines file:
3 validation errors for PipelineSpec
pipelines.pull-requests.{feature/*,bugfix/*,chore/*,refactor/*,acceptance-test-issues/*}.2.StepWrapper.step
Field required [type=missing, input_value={'parallel': [{'step': {'...'flutter analyze .']}}]}, input_type=dict]
For further information visit https://errors.pydantic.dev/2.10/v/missing
pipelines.pull-requests.{feature/*,bugfix/*,chore/*,refactor/*,acceptance-test-issues/*}.2.ParallelStep.parallel
List should have at least 2 items after validation, not 1 [type=too_short, input_value=[{'step': {'name': 'Code ... 'flutter analyze .']}}], input_type=list]
For further information visit https://errors.pydantic.dev/2.10/v/too_short
pipelines.pull-requests.{feature/*,bugfix/*,chore/*,refactor/*,acceptance-test-issues/*}.2.Variables.variables
Field required [type=missing, input_value={'parallel': [{'step': {'...'flutter analyze .']}}]}, input_type=dict]
For further information visit https://errors.pydantic.dev/2.10/v/missing
My BitBucket yaml file:
bitbucket-pipelines copy.yml.txt
mathieu-lemay commented
Pydantic's validation errors can be a bit hard to read indeed. I might look into that later on.
In the meantime, the issue is due to the wrong assumption that parallel entries must contain at least two steps. This may or may not have been true in the past, but it is definitely valid now, so I'm fixing that.
Fix will be released in a few minutes, in version 0.4.8.