Skip to content

Implement query history "cancel" option#1715

Merged
elenatanasoiu merged 4 commits intomainfrom
elena/cancel-variant-analysis
Nov 4, 2022
Merged

Implement query history "cancel" option#1715
elenatanasoiu merged 4 commits intomainfrom
elena/cancel-variant-analysis

Conversation

@elenatanasoiu
Copy link
Copy Markdown
Contributor

@elenatanasoiu elenatanasoiu commented Nov 4, 2022

This makes it possible to cancel a variant analysis from the query history by right-clicking on it. This will trigger a request to the GitHub API to cancel the workflow run. Once that happens, the variant analysis will be updated via the monitor with a canceled state.

NB: We only attempt to cancel if the item is in progress.

While we're here we're also adding tests for cancelling local queries and remote queries.

Checklist

  • CHANGELOG.md has been updated to incorporate all user visible changes made by this pull request.
  • Issues have been created for any UI or other user-facing changes made by this pull request.
  • [Maintainers only] If this pull request makes user-facing changes that require documentation changes, open a corresponding docs pull request in the github/codeql repo and add the ready-for-doc-review label there.

This will allow us to make an API call to cancel a variant analysis.
We're going to add tests to check that we cancel a remote query.

We'll need a `.cancel` method to be present on our mock local queries for this.
This also adds tests for cancelling a local query and a remote query.

NB: We only cancel queries that are in progress, so the tests check
the behaviour both for in progress and not in progress items.
@elenatanasoiu elenatanasoiu force-pushed the elena/cancel-variant-analysis branch from 443f773 to 145f0bf Compare November 4, 2022 14:13
@elenatanasoiu elenatanasoiu marked this pull request as ready for review November 4, 2022 14:35
@elenatanasoiu elenatanasoiu requested review from a team as code owners November 4, 2022 14:35
@elenatanasoiu elenatanasoiu merged commit 1fdb1e2 into main Nov 4, 2022
@elenatanasoiu elenatanasoiu deleted the elena/cancel-variant-analysis branch November 4, 2022 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants