Skip to content
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

Add ci workflow for validating schema changes #6396

Open
wants to merge 1 commit into
base: dev-2.x
Choose a base branch
from

Conversation

optionsome
Copy link
Member

@optionsome optionsome commented Jan 17, 2025

Summary

Adds CI workflow that uses schema inspector to validate that there are no breaking schema changes and to list changes.

Issue

This was shortly discussed in a dev meeting this week

Unit tests

No

Documentation

No

Changelog

Skipped

@optionsome optionsome requested a review from a team as a code owner January 17, 2025 14:11
@optionsome
Copy link
Member Author

@leonardehrenfried perhaps we need to use a token? Seems like giving all permissions didn't fix the issue.

@leonardehrenfried
Copy link
Member

I'm sorry but I don't have a clue.

@optionsome optionsome force-pushed the ci-schema-validation branch from 6346e13 to 7788f1d Compare January 17, 2025 14:33
@optionsome
Copy link
Member Author

Maybe we need to use pull_request_target instead of pull_request for some reason but it does have some security concerns that I haven't fully looked into yet and action doesn't seem to run yet (perhaps the pr needs to be merged first).

@optionsome optionsome force-pushed the ci-schema-validation branch from 56c93b8 to 01cd2ed Compare January 17, 2025 14:47
@optionsome
Copy link
Member Author

I read a bit more about pull_request_target and about the permissions in general. With pull_request_target we can circumvent the issues with permissions, but in this context it won't work since the workflow would run against the dev-2.x code instead of the pr code. Therefore, I think I'll try to implement this ci workflow with some js libraries instead of trying to use this action.

@optionsome optionsome force-pushed the ci-schema-validation branch from bf2e7e8 to b147b21 Compare January 20, 2025 15:18
@optionsome optionsome force-pushed the ci-schema-validation branch 2 times, most recently from 0f065f8 to 6016a89 Compare January 20, 2025 15:29
@optionsome
Copy link
Member Author

I finally got it to work by manually running some npm cli library. This should be ready for review now.

Copy link

codecov bot commented Jan 20, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.72%. Comparing base (1030408) to head (6016a89).
Report is 38 commits behind head on dev-2.x.

Additional details and impacted files
@@              Coverage Diff              @@
##             dev-2.x    #6396      +/-   ##
=============================================
- Coverage      69.73%   69.72%   -0.02%     
+ Complexity     18024    18016       -8     
=============================================
  Files           2057     2057              
  Lines          76970    76967       -3     
  Branches        7846     7844       -2     
=============================================
- Hits           53678    53666      -12     
- Misses         20545    20551       +6     
- Partials        2747     2750       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@optionsome
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants