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

chore(ci): regen docs & add generate workflow to test make generate #3409

Merged
merged 3 commits into from
Jul 4, 2022

Conversation

tadayosi
Copy link
Member

Release Note

NONE

@tadayosi
Copy link
Member Author

tadayosi commented Jul 4, 2022

@squakez @phantomjinx @oscerd Could anybody review this?

Copy link
Contributor

@squakez squakez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice idea!

uses: actions/setup-go@v1
with:
# make generate requires Go >=1.17
go-version: 1.17.x
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're still on 1.16. We may need to wait #2845 before merging this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but it just runs test with make generate and doesn't commit any changes to the repo, so it should be safe to go ahead to merge it. And after all make generate hasn't been working with Go 1.16.x so there's no reason to worry about backward compatibility on it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doesn't commit any changes to the repo

I thought it was adding the generate doc back to the repo. Can you please clarify what the action does?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, the workflow just tests make generate; it makes sure the target runs fine, as I found this target is fragile and easy to be in a state of not working, e.g. it doesn't run with Go 1.16 or sometimes go mod tidy has tidied up too much of go.mod . We discover that only when we try to run the target. This workflow should find such breaking changes earlier.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okey, so, the idea of the action is to run it just to report any problem, not to generate on behalf of the user. I'd call it verify-generate to avoid creating confusion on the goal of the action.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, the suggested name is better. In the future, it might be worth adding the 'real' generate workflow that automatically generates docs for us. But let's do it another time.

@tadayosi tadayosi merged commit d73d5cd into apache:main Jul 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants