-
Notifications
You must be signed in to change notification settings - Fork 6
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
chore(CI): add pipeline to check sidecar version against OpenAPI spec and client code versions #1062
Conversation
Sidecar Version Check Failed (ca54eea)OpenAPI spec version mismatch:
Make sure to copy https://github.com/confluentinc/ide-sidecar/blob/v0.161.0/src/generated/resources/openapi.yaml to sidecar.openapi.yaml |
Sidecar Version Check Failed (8fd6f48)Client code version mismatch:
Make sure to run |
This reverts commit 8fd6f48.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
- name: Validate Sidecar Version | ||
pipeline_file: validate-sidecar-version.yml | ||
auto_promote: | ||
when: "result = 'passed' and change_in(['.versions/ide-sidecar.txt', 'src/clients/sidecar-openapi-specs/sidecar.openapi.yaml'])" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The auto_promote condition references 'src/clients/sidecar-openapi-specs/sidecar.openapi.yaml' for the OpenAPI spec version check, but the PR description mentions validating the client code version in 'src/clients/sidecar/runtime.ts'. Please verify that the correct file is monitored for changes.
when: "result = 'passed' and change_in(['.versions/ide-sidecar.txt', 'src/clients/sidecar-openapi-specs/sidecar.openapi.yaml'])" | |
when: "result = 'passed' and change_in(['.versions/ide-sidecar.txt', 'src/clients/sidecar/runtime.ts'])" |
Copilot is powered by AI, so mistakes are possible. Review output carefully before use.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We care more about changes to sidecar.openapi.yaml
, which should be followed up by gulp apigen
(which then changes clients/**/runtime.ts
files). No need to explicitly check for any changes to runtime.ts
here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good bot, try again next time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great!! LGTM.
Some cleanup to go along with confluentinc/ide-sidecar#332 to make sure our
.versions/ide-sidecar.txt
and OpenAPI spec version match, along with the code in the openapi-generator client code comments:vscode/src/clients/sidecar/runtime.ts
Line 7 in f1e0bf4
Failure cases:
.versions/ide-sidecar.txt
doesn't match with the OpenAPI specgulp apigen
)