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

feature: Improving Analyzer Failure State #2697

Conversation

xoscar
Copy link
Contributor

@xoscar xoscar commented Jun 9, 2023

This PR improves the way we handle error states for the analyzer. Instead of stopping the test execution, now clients will be reading the linter results to validate if there was a failure or not, and show the proper results.

Changes

  • Removes stopping of test runs based on analyzer errors
  • Updates analyzer errors UI to better showcase the minimum score error
  • Updates transaction execution card and test run card to show the proper status

Fixes

Checklist

  • tested locally
  • added new dependencies
  • updated the docs
  • added a test

https://www.loom.com/share/6624b56c915b4c41a07f52179bbbdbf7

@xoscar xoscar requested a review from jorgeepc June 9, 2023 17:38
@xoscar xoscar self-assigned this Jun 9, 2023
@xoscar xoscar marked this pull request as ready for review June 9, 2023 17:43
Copy link
Collaborator

@kdhamric kdhamric left a comment

Choose a reason for hiding this comment

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

Perfect!

@@ -45,36 +43,3 @@ func (l Linter) HasID() bool {
func (l Linter) GetID() id.ID {
return l.ID
}

func (l Linter) ValidateResult(result model.LinterResult) error {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not needed, clients will check score vs minimum score to validate it

@@ -10,6 +10,8 @@
package openapi

type LinterResult struct {
MinimumScore int32 `json:"minimumScore,omitempty"`
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We are now going to persis the minimum score that was used during the execution, not using the global

Copy link
Contributor

@jorgeepc jorgeepc left a comment

Choose a reason for hiding this comment

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

LGTM!

@@ -25,6 +25,7 @@ export const theme: DefaultTheme = {
md: '14px',
lg: '16px',
xl: '18px',
xxxl: '24px',
Copy link
Contributor

Choose a reason for hiding this comment

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

xxxl? 👀

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't know man, 20 should be xxl si I just went for it 😂

@xoscar xoscar merged commit 0aab475 into main Jun 9, 2023
@xoscar xoscar deleted the 2682-analyzer-results-do-all-steps-of-a-test-rather-than-failing-on-an-analyzer-score-not-being-reached branch June 9, 2023 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Analyzer Results] Do all steps of a test rather than failing on an Analyzer Score not being reached
3 participants