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

dashboard/templates: Remove graphs from jobs-job{-branch} templates #144

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

patersonc
Copy link
Contributor

In the job// and job// views we often get a "Error
loading test data" error for the test pass rate graph at the bottom of the
page.

When viewing an entire tree at this level the build/test pass rate graphs
don't provide any useful information anyway, so let's just remove them.

If anyone manages to work out what is causing the issues in future we can
always restore one or both of the graphs again.

Signed-off-by: Chris Paterson [email protected]

In the job/<tree>/ and job/<tree>/<branch> views we often get a "Error
loading test data" error for the test pass rate graph at the bottom of the
page.

When viewing an entire tree at this level the build/test pass rate graphs
don't provide any useful information anyway, so let's just remove them.

If anyone manages to work out what is causing the issues in future we can
always restore one or both of the graphs again.

Signed-off-by: Chris Paterson <[email protected]>
@gctucker gctucker requested a review from a team November 26, 2021 09:15
Copy link
Contributor

@gctucker gctucker left a comment

Choose a reason for hiding this comment

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

Please also remove the Javascript code that sends requests to the backend to populate these graphs, otherwise they'll keep doing it and just discarding the data.

$ git grep build-pass-rate
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:            document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:        chart.buildpassrate('build-pass-rate', response);
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:                document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job.2020.10.js:            document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job.2020.10.js:        chart.buildpassrate('build-pass-rate', response);
app/dashboard/static/js/app/view-jobs-job.2020.10.js:                document.getElementById('build-pass-rate'),

Same for test-pass-rate.

Keep charts/passrate.js for now in case it's useful for someone.

Signed-off-by: Chris Paterson <[email protected]>
@patersonc
Copy link
Contributor Author

Hi @gctucker

Please also remove the Javascript code that sends requests to the backend to populate these graphs, otherwise they'll keep doing it and just discarding the data.

$ git grep build-pass-rate
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:            document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:        chart.buildpassrate('build-pass-rate', response);
app/dashboard/static/js/app/view-jobs-job-branch.2020.10.js:                document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job.2020.10.js:            document.getElementById('build-pass-rate'),
app/dashboard/static/js/app/view-jobs-job.2020.10.js:        chart.buildpassrate('build-pass-rate', response);
app/dashboard/static/js/app/view-jobs-job.2020.10.js:                document.getElementById('build-pass-rate'),

Same for test-pass-rate.

Thank you for pointing this out.

I've gone through and (hopefully) removed the relevant code.

Let me know if you also think charts/passrate.js should be removed. I kept it in case someone wants to use it elsewhere in future.

@gctucker gctucker added the staging-skip Don't test automatically on staging.kernelci.org label Dec 6, 2021
@gctucker
Copy link
Contributor

gctucker commented Dec 6, 2021

Adding staging-skip label as this seems to be causing some issues on staging.

@patersonc
Copy link
Contributor Author

Adding staging-skip label as this seems to be causing some issues on staging.

Sorry! Do you have any logs I can look through to work out what went wrong?

@gctucker
Copy link
Contributor

gctucker commented Dec 7, 2021

No I just noticed that the frontend was failing to load some data and spinning for ever. I think that should be reproducible locally, but make sure you enable developer mode in your browser and disable all caches and force-reload the pages to get the actual Javascript changes. The developer mode should also show you all the queries that the frontend is doing and which ones are failing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
staging-skip Don't test automatically on staging.kernelci.org
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants