-
Couldn't load subscription status.
- Fork 119
Support CodeOwnership 2.0.0 #1474
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
base: main
Are you sure you want to change the base?
Conversation
Starting from version `2.0.0` of `CodeOwnership` teams that don't have a `github` property in their `team.yml` config file are ignored. Add github property with fake github organizations to all team config fixtures.
23bbb18 to
40d5f7e
Compare
40d5f7e to
ad0dff6
Compare
Starting from version `2.0.0` `CodeOwnership` is much stricter in how it handles config. Files that aren't included in `owned_globs` of `config/code_ownership.yml` are ignored even if valid ownership is specified. This broke the existing setup for integration tests. Move all "app" fixtures to `/app` directory. Copy all config and app files from `support_dir` to `tmp_dir`, so that everything is loaded from same directory.
The public api method that the integration uses hasn't changed. Remove requirement for `CodeOwnership` gem version below `v2.0`.
1e35984 to
1b6af50
Compare
The CodeOwnership gem fails to build its native extension on ruby `3.5.0-preview1`. Remove ruby `3.5.0-preview1` from the CodeOwnership gem's CI build matrix.
1b6af50 to
63dff70
Compare
CodeOwnership uses `oxidize-rb/actions/fetch-ci-data@v1` github action to fetch a list of ruby versions to build native extension for. During the realase of 2.0.0 it only returned ["3.2", "3.4"]. The gem fails to load because there's no compiled native extension available for Ruby 3.3. Missing builds for Ruby 3.3 seems to be a known issue in the `oxidize-rb/actions` repo. See oxidize-rb/actions#62 Remove Ruby 3.3.4 from the build matrix.
| def create_team_files | ||
| FileUtils.mkdir(File.join(tmp_dir, "config", "teams")) | ||
|
|
||
| %w[file directory].each do |team| | ||
| FileUtils.copy_file( | ||
| File.join(support_dir, "code_ownership", "config", "teams", "#{team}.yml"), | ||
| File.join(tmp_dir, "config", "teams", "#{team}.yml") | ||
| ) | ||
| end | ||
|
|
||
| glob_team = | ||
| <<~CONFIG | ||
| name: GlobTeam | ||
| owned_globs: | ||
| - #{File.join(support_dir, "code_ownership", "glob", "*.rb")} | ||
| CONFIG | ||
|
|
||
| write_file(File.join(tmp_dir, "config", "teams", "glob.yml"), glob_team) |
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.
Now that everything is loaded from the same directory, there's no need for a dynamic owned_globs property, so I moved the glob_team config into the config/teams/glob.yml fixture.
This is a message from the daily scheduled checks. |
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.
Looks good to me -- do you know why CI is failing? Looks unrelated, but just to be sure.
Yes, it's unrelated. Two things appeared simultaneously on the same day and broke everything:
Once this PR and #1473 are merged, we should be back to green builds. |
No changes were necessary in the integration. The only issues were stricter config requirements that caused CodeOwnership to ignore teams in our tests.
Fixes #1472.
Add github property to team.yml config files
Starting from version
2.0.0ofCodeOwnershipteams that don'thave a
githubproperty in theirteam.ymlconfig file are ignored.Add github property with fake github organizations to all team config
fixtures.
Move CodeOwnership fixtures to app dir
Starting from version
2.0.0CodeOwnershipis much stricter in how ithandles config. Files that aren't included in
owned_globsofconfig/code_ownership.ymlare ignored even if valid ownership isspecified. This broke the existing setup for integration tests.
Move all "app" fixtures to
/appdirectory. Copy all config and appfiles from
support_dirtotmp_dir, so that everything is loaded fromsame directory.
Remove gem version requirement
The public api method that the integration uses hasn't changed. Remove
requirement for
CodeOwnershipgem version belowv2.0.Update build matrix
The CodeOwnership gem fails to build its native extension on ruby
3.5.0-preview1.Remove ruby
3.5.0-preview1from the CodeOwnership gem's CI buildmatrix.
Disable Ruby 3.3.4 from build matrix
CodeOwnership uses
oxidize-rb/actions/fetch-ci-data@v1github actionto fetch a list of ruby versions to build the native extension for. During
the realase of 2.0.0 it only returned ["3.2", "3.4"]. The gem fails to
load because there's no compiled extension available for Ruby
3.3.
Missing builds for Ruby 3.3 seems to be a known issue in the
oxidize-rb/actionsrepo. Seeoxidize-rb/actions#62
Remove Ruby 3.3.4 from the build matrix.
[skip changeset]