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 test risk analysis html for spyglass #27508

Merged
merged 1 commit into from Nov 10, 2022

Conversation

xueqzhan
Copy link
Contributor

@xueqzhan xueqzhan commented Nov 1, 2022

@dgoodwin
Copy link
Contributor

dgoodwin commented Nov 2, 2022

Wrong PR :0 ignore last comment. :)

@xueqzhan
Copy link
Contributor Author

xueqzhan commented Nov 2, 2022

/retest-required

@xueqzhan
Copy link
Contributor Author

xueqzhan commented Nov 3, 2022

/retest-required

Comment on lines 9 to 11
<p>
"Risk analysis is performed by Sippy[<a href="TEST_RISK_ANALYSIS_SIPPY_URL_GOES_HERE">link</a>] to attempt to
determine if the failures in this job are abnormal when compared to results for similar jobs over the past week,
and amidst on-going incidents in the CI infrastructure. Risk analysis API will not catch everything and is a
relatively simple implementation today, please reach out to the Technical Release Team if you spot abnormalities
or have suggestions."
</p>
Copy link
Member

Choose a reason for hiding this comment

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

Spyglass supports "info" tooltips, if you'd prefer to put most of this info except maybe the link in there. Example:

https://github.com/openshift/release/blob/9548766e2f234917b40732d279fa1fe6cf7f6dad/ci-operator/step-registry/gather/extra/gather-extra-commands.sh#L577-L579

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Does the tooltip support links? If one puts the cursor on and get the tooltip, can he click on the link to get to sippy? I just experimented and it doesn't seem to support that.

Copy link
Member

@stbenjam stbenjam Nov 7, 2022

Choose a reason for hiding this comment

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

Right, I suggested not putting the link. You can leave everything here if you want, but it'd be more consistent if we described what the page is doing in the tooltip.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Devan suggested the link. @dgoodwin do you prefer this text in tooltip without the link to Sippy, or a paragraph on the top of the page?

Copy link
Contributor

Choose a reason for hiding this comment

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

My thought was here was just to link to top level Sippy page, so a user could see what it was. Not directly to risk analysis. I can live without either though if anyone feels strongly.

And if we keep it, I'd just do the word Sippy as the link, not a [] after it, that was just markdown slipping into my suggestions for the card.

Copy link
Member

@stbenjam stbenjam Nov 7, 2022

Choose a reason for hiding this comment

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

Sorry if I wasn't clear, I just meant putting the link outside of the tooltip somewhere on the page would be fine, but not including the wall of text someone probably only needs to read once.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Is there a corresponding PR to openshift/release to add this as an HTML page spyglass should show? There's no reason it can't be there now so we could see the results in the presubmits

@deepsm007 Deep has a PR here: openshift/release#33731

You meant that PR can be merged now so that we can see the spyglass in our job runs. Good point.

@@ -91,5 +93,16 @@ func (opt *Options) Run() error {
}
fmt.Fprintf(opt.Out, "Successfully wrote: %s\n", outputFile)

// Write html file for spyglass
riskAnalysisHTMLTemplate := testdata.MustAsset("e2echart/test-risk-analysis.html")
title := fmt.Sprintf("Risk Analysis For Job: %s, ID: %d", finalProwJobRun.ProwJob, finalProwJobRun.ID)
Copy link
Member

Choose a reason for hiding this comment

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

Nit: the spyglass page already has the job name and ID prominently displayed at the top, I'd omit this and just leave it as "Risk Analysis"

@xueqzhan xueqzhan force-pushed the risk-analysis-html branch 2 times, most recently from 3432685 to d67f411 Compare November 7, 2022 16:44
@xueqzhan
Copy link
Contributor Author

xueqzhan commented Nov 7, 2022

/retest-required

<h1>
</h1>
<p>
"<a href="TEST_RISK_ANALYSIS_SIPPY_URL_GOES_HERE">Link to Sippy</a>"
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is nothing planned for this. The risk analysis API requires a body. The top page of Sippy is put here just for convenience purposes. I am open for suggestions though.

@stbenjam
Copy link
Member

stbenjam commented Nov 7, 2022

Is there a corresponding PR to openshift/release to add this as an HTML page spyglass should show? There's no reason it can't be there now so we could see the results in the presubmits

// Build rows for all tests
for (var i = 0; i < testResult.Tests.length; i++) {
var row$ = $('<tr/>');
row$.append($('<td/>').html(testResult.Tests[i].Name));
Copy link
Member

Choose a reason for hiding this comment

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

Is it possible to put a link to the test analysis page in Sippy for each test? That seems more useful to me than a link to the main page of sippy

Copy link
Contributor Author

Choose a reason for hiding this comment

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

As of now, this might not be easy. I need to change the risk analysis API to return release number first to generate the test case URL. Trying to figure out the release from prow job name is not the best way.

@xueqzhan xueqzhan force-pushed the risk-analysis-html branch 2 times, most recently from eea44ec to 522f640 Compare November 8, 2022 17:38
for (var i = 0; i < testResult.Tests.length; i++) {
var row$ = $('<tr/>');
testUrl = encodeURI(testLinkPrefix + testResult.Release + testLinkSuffix + testResult.Tests[i].Name)
row$.append($('<td/>').html("<a href=" + testUrl + ">" + testResult.Tests[i].Name + "</a>"));
Copy link
Member

@stbenjam stbenjam Nov 8, 2022

Choose a reason for hiding this comment

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

Can we get this to open in a new tab?

Suggested change
row$.append($('<td/>').html("<a href=" + testUrl + ">" + testResult.Tests[i].Name + "</a>"));
row$.append($('<td/>').html("<a target=\"_blank\" href=" + testUrl + ">" + testResult.Tests[i].Name + "</a>"));

@stbenjam
Copy link
Member

stbenjam commented Nov 8, 2022

It looks like the table is getting cut off, do we control the size of the iframe? The intervals chart seems to be able to be taller.

image

</head>
<body onLoad="buildTestCaseTable('#test_case_results')">
<p>
<a href="TEST_RISK_ANALYSIS_SIPPY_URL_GOES_HERE">Link to Sippy</a>
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
<a href="TEST_RISK_ANALYSIS_SIPPY_URL_GOES_HERE">Link to Sippy</a>
<a target="_blank" href="TEST_RISK_ANALYSIS_SIPPY_URL_GOES_HERE">Link to Sippy</a>

cell$ = $('<ul/>')
for (var i = 0; i < openBugs.length; i++) {
li$ = $('<li>')
bug = "<a href=" + openBugs[i].url + ">" + openBugs[i].id + "</a>: " + openBugs[i].summary
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
bug = "<a href=" + openBugs[i].url + ">" + openBugs[i].id + "</a>: " + openBugs[i].summary
bug = "<a target=\"_blank\" href=" + openBugs[i].url + ">" + openBugs[i].id + "</a>: " + openBugs[i].summary

Comment on lines 5 to 7
<meta name="description"
content="Risk analysis is performed by Sippy to attempt to determine if the failures in this job are
abnormal when compared to results for similar jobs over the past week, and amidst on-going incidents
in the CI infrastructure. Risk analysis API will not catch everything and is a relatively simple
implementation today, please reach out to the Technical Release Team if you spot abnormalities or
have suggestions.">
</head>
Copy link
Member

Choose a reason for hiding this comment

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

Can we get the text all on one line? Seems to not like the white space.

image

@stbenjam
Copy link
Member

stbenjam commented Nov 9, 2022

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Nov 9, 2022
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 9, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: stbenjam, xueqzhan

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

The pull request process is described 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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 9, 2022
@xueqzhan
Copy link
Contributor Author

xueqzhan commented Nov 9, 2022

/retest-required

1 similar comment
@xueqzhan
Copy link
Contributor Author

xueqzhan commented Nov 9, 2022

/retest-required

@stbenjam
Copy link
Member

stbenjam commented Nov 9, 2022

/override ci/prow/e2e-gcp-ovn-image-ecosystem

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 9, 2022

@stbenjam: /override requires failed status contexts, check run or a prowjob name to operate on.
The following unknown contexts/checkruns were given:

  • ci/prow/e2e-gcp-ovn-image-ecosystem

Only the following failed contexts/checkruns were expected:

  • ci/prow/e2e-agnostic-ovn-cmd
  • ci/prow/e2e-aws-csi
  • ci/prow/e2e-aws-ovn-cgroupsv2
  • ci/prow/e2e-aws-ovn-fips
  • ci/prow/e2e-aws-ovn-serial
  • ci/prow/e2e-aws-ovn-single-node
  • ci/prow/e2e-aws-ovn-single-node-serial
  • ci/prow/e2e-aws-ovn-single-node-upgrade
  • ci/prow/e2e-aws-ovn-upgrade
  • ci/prow/e2e-gcp-csi
  • ci/prow/e2e-gcp-ovn
  • ci/prow/e2e-gcp-ovn-rt-upgrade
  • ci/prow/e2e-gcp-ovn-upgrade
  • ci/prow/e2e-metal-ipi-ovn-ipv6
  • ci/prow/e2e-metal-ipi-sdn
  • ci/prow/e2e-openstack-ovn
  • ci/prow/images
  • ci/prow/lint
  • ci/prow/unit
  • ci/prow/verify
  • ci/prow/verify-deps
  • pull-ci-openshift-origin-master-e2e-agnostic-ovn-cmd
  • pull-ci-openshift-origin-master-e2e-aws-csi
  • pull-ci-openshift-origin-master-e2e-aws-ovn-cgroupsv2
  • pull-ci-openshift-origin-master-e2e-aws-ovn-fips
  • pull-ci-openshift-origin-master-e2e-aws-ovn-serial
  • pull-ci-openshift-origin-master-e2e-aws-ovn-single-node
  • pull-ci-openshift-origin-master-e2e-aws-ovn-single-node-serial
  • pull-ci-openshift-origin-master-e2e-aws-ovn-single-node-upgrade
  • pull-ci-openshift-origin-master-e2e-aws-ovn-upgrade
  • pull-ci-openshift-origin-master-e2e-gcp-csi
  • pull-ci-openshift-origin-master-e2e-gcp-ovn
  • pull-ci-openshift-origin-master-e2e-gcp-ovn-rt-upgrade
  • pull-ci-openshift-origin-master-e2e-gcp-ovn-upgrade
  • pull-ci-openshift-origin-master-e2e-metal-ipi-ovn-ipv6
  • pull-ci-openshift-origin-master-e2e-metal-ipi-sdn
  • pull-ci-openshift-origin-master-e2e-openstack-ovn
  • pull-ci-openshift-origin-master-images
  • pull-ci-openshift-origin-master-lint
  • pull-ci-openshift-origin-master-unit
  • pull-ci-openshift-origin-master-verify
  • pull-ci-openshift-origin-master-verify-deps
  • tide

If you are trying to override a checkrun that has a space in it, you must put a double quote on the context.

In response to this:

/override ci/prow/e2e-gcp-ovn-image-ecosystem

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@stbenjam
Copy link
Member

stbenjam commented Nov 9, 2022

/override ci/prow/e2e-gcp-ovn
/skip

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 9, 2022

@stbenjam: Overrode contexts on behalf of stbenjam: ci/prow/e2e-gcp-ovn

In response to this:

/override ci/prow/e2e-gcp-ovn
/skip

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@stbenjam
Copy link
Member

/override ci/prow/e2e-aws-ovn-serial

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 10, 2022

@stbenjam: Overrode contexts on behalf of stbenjam: ci/prow/e2e-aws-ovn-serial

In response to this:

/override ci/prow/e2e-aws-ovn-serial

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Nov 10, 2022

@xueqzhan: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-gcp-ovn-image-ecosystem 2d5b958 link true /test e2e-gcp-ovn-image-ecosystem
ci/prow/e2e-openstack-ovn c1a0ac5 link false /test e2e-openstack-ovn
ci/prow/e2e-gcp-ovn-rt-upgrade c1a0ac5 link false /test e2e-gcp-ovn-rt-upgrade
ci/prow/e2e-aws-ovn-upgrade c1a0ac5 link false /test e2e-aws-ovn-upgrade
ci/prow/e2e-aws-ovn-single-node-serial c1a0ac5 link false /test e2e-aws-ovn-single-node-serial
ci/prow/e2e-aws-ovn-single-node-upgrade c1a0ac5 link false /test e2e-aws-ovn-single-node-upgrade

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@openshift-merge-robot openshift-merge-robot merged commit 63e7542 into openshift:master Nov 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants