From 2230fdf694612052db93f26349f141adef219d71 Mon Sep 17 00:00:00 2001 From: Tony Xiao Date: Fri, 9 Feb 2024 15:57:40 -0500 Subject: [PATCH] chore(stats-detectors): Remove unreleased regression issue This was the experimental issue type. We can remove it now. --- internal/occurrence/occurrence.go | 8 ++------ internal/occurrence/occurrence_test.go | 17 ----------------- internal/occurrence/regressed_frame.go | 1 - 3 files changed, 2 insertions(+), 24 deletions(-) diff --git a/internal/occurrence/occurrence.go b/internal/occurrence/occurrence.go index 5e63afe..f86f31f 100644 --- a/internal/occurrence/occurrence.go +++ b/internal/occurrence/occurrence.go @@ -219,12 +219,8 @@ func FromRegressedFunction( beforeP95 := time.Duration(regressed.AggregateRange1).Round(10 * time.Microsecond) afterP95 := time.Duration(regressed.AggregateRange2).Round(10 * time.Microsecond) - occurrenceType := FrameRegressionExpType - var issueTitle IssueTitle = "Function Duration Regression (Experimental)" - if regressed.Released { - occurrenceType = FrameRegressionType - issueTitle = "Function Regression" - } + occurrenceType := FrameRegressionType + var issueTitle IssueTitle = "Function Regression" return &Occurrence{ Culprit: fullyQualifiedName, diff --git a/internal/occurrence/occurrence_test.go b/internal/occurrence/occurrence_test.go index dbd7b43..ab1b519 100644 --- a/internal/occurrence/occurrence_test.go +++ b/internal/occurrence/occurrence_test.go @@ -64,28 +64,11 @@ func TestFromRegressedFunction(t *testing.T) { Fingerprint: 0, AggregateRange1: 100_000_000, AggregateRange2: 200_000_000, - Released: true, }, expectedType: 2011, expectedTitle: "Function Regression", expectedSubtitle: "Duration increased from 100ms to 200ms (P95).", }, - { - name: "unreleased", - frame: f, - function: RegressedFunction{ - OrganizationID: 1, - ProjectID: 1, - ProfileID: "", - Fingerprint: 0, - AggregateRange1: 100_000_000, - AggregateRange2: 200_000_000, - Released: false, - }, - expectedType: 2010, - expectedTitle: "Function Duration Regression (Experimental)", - expectedSubtitle: "Duration increased from 100ms to 200ms (P95).", - }, } for _, tt := range tests { diff --git a/internal/occurrence/regressed_frame.go b/internal/occurrence/regressed_frame.go index 9776f53..d68857f 100644 --- a/internal/occurrence/regressed_frame.go +++ b/internal/occurrence/regressed_frame.go @@ -25,7 +25,6 @@ type RegressedFunction struct { TrendPercentage float64 `json:"trend_percentage"` UnweightedPValue float64 `json:"unweighted_p_value"` UnweightedTValue float64 `json:"unweighted_t_value"` - Released bool `json:"released,omitempty"` } func ProcessRegressedFunction(