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 automation to report on recent build flakes #3012

Merged
merged 7 commits into from
Mar 3, 2023

Conversation

zmerlynn
Copy link
Collaborator

@zmerlynn zmerlynn commented Mar 2, 2023

Adds build/report/report.go, which generates a dated report and an index.html that redirects to it.

You can see it live at https://agones-build-reports.storage.googleapis.com/index.html, which redirects (today) to https://agones-build-reports.storage.googleapis.com/2023-03-02.html. The formatting is terrible, apologies for the web1.0 vibe.

Also adds a cloudbuild.yaml to run it. I opted to strip the build down to just the gcloud build runner because I was having difficulty with authentication with the normal build container - plus it's way heavier to build.

Also updates vendoring to pull in the cloudbuild package (plus upgrades).

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 416fc094-2e25-4508-950b-721b6b6b8cd2

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 1f8631c4-a848-4ab7-b209-8a87ed092555

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 7b7396c1-ce30-400a-a42b-83f57d82150e

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: bf41603a-e517-4b91-8b32-f8fe4d51d3f6

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 94e4f7db-afc4-4000-806e-18fdda657dc8

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: b6c8d5d7-95f3-40b8-ae94-2ff17904a7af

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 16cf63a3-965d-4cd9-a774-a79134e39fdd

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@google-oss-prow google-oss-prow bot added size/XXL and removed size/L labels Mar 2, 2023
@zmerlynn zmerlynn changed the title WIP: Add flake report script / build Add automation to report on recent build flakes Mar 2, 2023
@zmerlynn zmerlynn marked this pull request as ready for review March 2, 2023 17:19
@gongmax
Copy link
Collaborator

gongmax commented Mar 3, 2023

Wow, much nicer now!

@google-oss-prow google-oss-prow bot added the lgtm label Mar 3, 2023
@google-oss-prow
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: gongmax, zmerlynn
Once this PR has been reviewed and has the lgtm label, please ask for approval from markmandel. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@markmandel
Copy link
Member

That is really cool!

@markmandel
Copy link
Member

Suggestion on enhancement: Show which step fails. That way we can at least see some patterns in which step is the failure (although not the failure itself)

@zmerlynn
Copy link
Collaborator Author

zmerlynn commented Mar 3, 2023

Suggestion on enhancement: Show which step fails. That way we can at least see some patterns in which step is the failure (although not the failure itself)

Yup. A lot of this was just to get some sort of framework in place to extend it. It's a starting place.

I've been thinking we should allow people to annotate somehow, but it requires a level of interactivity I'm certainly not competent at. It would be nice to be able to audit the builds and note where it failed to detect trends, like I did manually a few weeks ago. I may hack something up in a csv file that plugs in here, as a starting point.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: e58158ca-f4ed-4008-93ba-182bd91ea9cf

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: c3d8e057-8414-4294-82fc-7f5b9c509830

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/googleforgames/agones.git pull/3012/head:pr_3012 && git checkout pr_3012
  • helm install agones ./install/helm/agones --namespace agones-system --agones.image.release=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.31.0-acf95c9-amd64

build/Makefile Outdated Show resolved Hide resolved
Comment on lines 185 to 199
for sha := range success {
buildCount++
if ids, ok := failure[sha]; ok {
flakeCount++
for _, id := range ids {
flakes = append(flakes, flake{
ID: id,
CreateTime: idTime[id].Format(time.RFC3339),
})
}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
for sha := range success {
buildCount++
if ids, ok := failure[sha]; ok {
flakeCount++
for _, id := range ids {
flakes = append(flakes, flake{
ID: id,
CreateTime: idTime[id].Format(time.RFC3339),
})
}
}
}
buildCount := len(success)
for sha := range success {
ids, ok := failure[sha]; ok
if !ok {
continue
}
flakeCount++
for _, id := range ids {
flakes = append(flakes, flake{
ID: id,
CreateTime: idTime[id].Format(time.RFC3339),
})
}
}

A suggestion, I don't know if it would be better, at least not so deep

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Thanks for the suggestion. I decided to change methodology and just count all the flakes and report the flake ratio, which makes this less complicated anyways.

Adds build/report/report.go, which generates a dated report and an
index.html that redirects to it.

You can see it live at https://agones-build-reports.storage.googleapis.com/index.html

The formatting is terrible, apologies for the web1.0 vibe.

Adds a cloudbuild.yaml to run it. I opted to strip the build down to
just the gcloud build runner because I was having difficulty with
authentication with the normal build container - plus it's _way_
heavier to build.
@google-oss-prow
Copy link

New changes are detected. LGTM label has been removed.

@zmerlynn
Copy link
Collaborator Author

zmerlynn commented Mar 3, 2023

https://agones-build-reports.storage.googleapis.com/test/2023-03-03-new8.html has the new output, and a description of the methodology at the bottom.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 9a0577f9-1c26-4f86-8640-27b9271f57e2

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 7489ca6e-3bf8-43cf-b19e-a9c2c959f618

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: dc286ac4-58ec-4346-92c0-bf5ce2046d1e

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 1e53572f-0263-4bda-8dfd-4fb47508e8e6

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/googleforgames/agones.git pull/3012/head:pr_3012 && git checkout pr_3012
  • helm install agones ./install/helm/agones --namespace agones-system --agones.image.release=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.31.0-ad692ca-amd64

@zmerlynn zmerlynn merged commit 7671529 into googleforgames:main Mar 3, 2023
@Kalaiselvi84 Kalaiselvi84 added the kind/feature New features for Agones label Apr 10, 2023
@Kalaiselvi84 Kalaiselvi84 added this to the 1.31.0 milestone Apr 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature New features for Agones size/XXL
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants