-
Notifications
You must be signed in to change notification settings - Fork 107
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
Adding a GitHub action for Beckn core specification to validate meta.yaml, registry.yaml and transaction.yaml files against OpenAPI3.0 #407
base: draft
Are you sure you want to change the base?
Conversation
Please review this PR. |
Hi @rajaneeshk90, In Pt 2, of the "Changes Made" section, you have mentioned
Can you please specify who is "the Beckn team". As per my knowledge, Beckn does not have a "team". Beckn only has a "community" of volunteers. In Pt 2 of "Steps to Test" you have mentioned
Can you please be more specifi by what "this" and "that" mean? Secondly, in the section named "Additional Information", you have mentioned,
In Pt 1, can you please specify who is "we" and "Beckn team" (see my comment above). Can you please provide clarity on the above and make the necessary fixes. Thanks! |
@rajaneeshk90 unable to replicate your steps. No action ran on my forked repo Cloned the forked repo
Added remote url
Fetched PR
Checked out branch test-github-action
Introduced an error
Pushed to draft
Nothing happened... |
Issue
Summary:
While merging the PRs from other branches (draft, feature branch etc) of the Beckn protocol specification GitHub repository to the master branch of the Beckn protocol specification GitHub repository, openAPI syntactical errors already present in the source branch get added to the master branch.
More details about the issue can be found on the Beckn protocol specification issues page: #366
Changes Made
Added a folder named workflows inside the .github directory at the root of the Beckn core protocol specification GitHub repository.
Created a file under workflows named Beckn-Core-Spec-Validator.yml. Beckn-Core-Spec-Validator.yml. contains the GitHub Action code.
The added GitHub Action validates
api/transaction/build/transaction.yaml
,api/meta/build/meta.yaml
, andapi/registry/build/registry.yaml
against the OpenAPI 3.0 specification. The GitHub Action runs automatically at the occurrence of 2 events listed below:The GitHub action utilizes the
beckn-spec-validator
npm package for OpenAPI validation, created by the Beckn Community. We can find the details about thebeckn-spec-validator
npm package on the beckn-spec-validator GitHub page: https://github.com/beckn/beckn-utilities/tree/main/beckn-spec-validatorTests performed to ensure that the created GitHub action is working as expected.
Tested the created GitHub action on a fork of the Beckn protocol specification for 2 cases:
Reviewer's Guidelines:
[Bring this change to your fork]
Add this code into your fork repo's draft branch (this code must be checked in inside the .github/workflows directory.
one way of bringing this change to your fork is described in the attached file.
PullPR407.txt
[Test out the github action]
Please note that as per the current configuration, the GitHub action will run only when we push to the draft branch.
Any feedback or suggestions on this pull request would be greatly appreciated. Community input is valuable in making the development process more robust and efficient.
Thanks,
Rajaneesh