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

build(action): commit updated sample json #10549

Closed
wants to merge 18 commits into from
Closed

Conversation

connorjclark
Copy link
Collaborator

@connorjclark connorjclark commented Apr 6, 2020

I like your idea, but I'll also feel more sympathy about team members having to bump a single number when anyone works to make the proto roundtrip test not a new contributor nightmare :P

@brendankenny #10472 (comment)

Let the nightmares end!

Example action: https://github.com/GoogleChrome/lighthouse/runs/565279958?check_suite_focus=true

In draft b/c I edited a UI string to demo the workflow.

@googlebot
Copy link

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and then comment @googlebot I fixed it.. If the bot doesn't comment, it means it doesn't think anything has changed.

ℹ️ Googlers: Go here for more info.

@connorjclark
Copy link
Collaborator Author

@googlebot it's a bot leave them alone :(

@brendankenny
Copy link
Member

ah, nice! :D

galaxy brain: what if we

  • git rm proto/sample_v2_round_trip.json
  • gitignore it
  • remove yarn compile-proto && yarn build-proto-roundtrip from update:sample-json
  • don't auto commit anything (at most devs will still need to update:sample-json, but that's a pure node step after the above change)
  • run yarn compile-proto && yarn build-proto-roundtrip as a yarn test-proto or whatever

It would still be runnable locally if e.g. need to debug a change, but could mostly run in CI, which would still ensure protobuf/PSI compatibility.

I can't remember the last time I got something useful out of the sample_v2_round_trip.json diff. Probably shortly after it was first added. We talked about something like this originally, but IIRC it was a disaster trying to install and run on Travis.

@connorjclark
Copy link
Collaborator Author

connorjclark commented Apr 6, 2020

what's up with our basics action not working on PRs from forks? e.g. #10542 @paulirish

we need to run the workflow on pull requests, not push
https://help.github.com/en/actions/reference/events-that-trigger-workflows#pull-request-events-for-forked-repositories

what's up with the action not failing on git add blah.txt? The log does have the fatal error in it

What log? I'd expect if any command in that script failed, the action should fail.

blah.txt was a file for testing (date > blah.txt) but I removed it and forgot to delete it from git add.

googlebot is going to be an issue

yeah :/

galaxy brain: what if we ...

i like it

don't auto commit anything (at most devs will still need to update:sample-json, but that's a pure node step after the above change)

With how often we say "can you run update sample json" it would be nice to autocommit if we can. IDK how to resolve the googlebot issue though so maybe not possible.

@brendankenny
Copy link
Member

brendankenny commented Apr 6, 2020

what's up with our basics action not working on PRs from forks? e.g. #10542 @paulirish

we need to run the workflow on pull requests, not push
https://help.github.com/en/actions/reference/events-that-trigger-workflows#pull-request-events-for-forked-repositories

well we should do that if we want to help anyone not us :)

what's up with the action not failing on git add blah.txt? The log does have the fatal error in it

What log? I'd expect if any command in that script failed, the action should fail.

In the "Automatically update sample json" action log:
Screen Shot 2020-04-06 at 16 33 05

@connorjclark
Copy link
Collaborator Author

oops 2ae8c8f

@connorjclark
Copy link
Collaborator Author

AIs from eng meeting:

we all agreed that moving proto stuff to CI is something we should do.

some people didn't like the auto commit idea. Maybe make it opt in - only done if a certain label is applied?

The CLA bot is a problem with no known (possible no) solution. We could reach out to the appropriate team internally to ask how to proceed.

@brendankenny
Copy link
Member

assuming this can be closed now that #10557 is landed

@brendankenny brendankenny deleted the gh-action-sample branch April 22, 2020 16:07
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.

4 participants