From 632e12d10f395412316c9a9ab76e63be1dd87b14 Mon Sep 17 00:00:00 2001 From: mary-georgiou-sonarsource Date: Tue, 23 Apr 2024 16:09:50 +0200 Subject: [PATCH 1/3] update rspec and remove from sonar-way --- analyzers/rspec/cs/S6803.html | 3 ++- analyzers/rspec/cs/S6803.json | 2 +- analyzers/rspec/cs/Sonar_way_profile.json | 1 - 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/analyzers/rspec/cs/S6803.html b/analyzers/rspec/cs/S6803.html index 399c742c8da..04312714955 100644 --- a/analyzers/rspec/cs/S6803.html +++ b/analyzers/rspec/cs/S6803.html @@ -1,4 +1,5 @@ -

Component parameters can only receive query parameter values in routable components with an @page directive.

+

<p>This rule is deprecated, and will eventually be removed.</p> Component parameters can only receive query parameter values in +routable components with an @page directive.

Why is this an issue?

SupplyParameterFromQuery diff --git a/analyzers/rspec/cs/S6803.json b/analyzers/rspec/cs/S6803.json index 72971147c0a..ed6b03b5af6 100644 --- a/analyzers/rspec/cs/S6803.json +++ b/analyzers/rspec/cs/S6803.json @@ -1,7 +1,7 @@ { "title": "Parameters with SupplyParameterFromQuery attribute should be used only in routable components", "type": "CODE_SMELL", - "status": "ready", + "status": "deprecated", "remediation": { "func": "Constant\/Issue", "constantCost": "5min" diff --git a/analyzers/rspec/cs/Sonar_way_profile.json b/analyzers/rspec/cs/Sonar_way_profile.json index 5006acc1f55..85d684d44ab 100644 --- a/analyzers/rspec/cs/Sonar_way_profile.json +++ b/analyzers/rspec/cs/Sonar_way_profile.json @@ -313,7 +313,6 @@ "S6797", "S6798", "S6800", - "S6803", "S6930", "S6931", "S6934", From 1423cfb005190904d189ba9e3c6847dec39b5a4f Mon Sep 17 00:00:00 2001 From: mary-georgiou-sonarsource Date: Tue, 23 Apr 2024 16:13:03 +0200 Subject: [PATCH 2/3] mark code as obsolete --- .../Rules/BlazorQueryParameterRoutableComponent.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/analyzers/src/SonarAnalyzer.CSharp/Rules/BlazorQueryParameterRoutableComponent.cs b/analyzers/src/SonarAnalyzer.CSharp/Rules/BlazorQueryParameterRoutableComponent.cs index 8ddb71708fa..b1dd88506a0 100644 --- a/analyzers/src/SonarAnalyzer.CSharp/Rules/BlazorQueryParameterRoutableComponent.cs +++ b/analyzers/src/SonarAnalyzer.CSharp/Rules/BlazorQueryParameterRoutableComponent.cs @@ -20,6 +20,7 @@ namespace SonarAnalyzer.Rules.CSharp; +[Obsolete("This rule has been deprecated since 9.25")] [DiagnosticAnalyzer(LanguageNames.CSharp)] public sealed class BlazorQueryParameterRoutableComponent : SonarDiagnosticAnalyzer { From 7764bf066d1c487dbda02b78044c38bc542e8873 Mon Sep 17 00:00:00 2001 From: mary-georgiou-sonarsource Date: Tue, 23 Apr 2024 16:59:44 +0200 Subject: [PATCH 3/3] Apply comments --- analyzers/rspec/cs/S6803.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/analyzers/rspec/cs/S6803.html b/analyzers/rspec/cs/S6803.html index 04312714955..6ea0df99dd0 100644 --- a/analyzers/rspec/cs/S6803.html +++ b/analyzers/rspec/cs/S6803.html @@ -1,5 +1,5 @@ -

<p>This rule is deprecated, and will eventually be removed.</p> Component parameters can only receive query parameter values in -routable components with an @page directive.

+

This rule is deprecated, and will eventually be removed.

+

Component parameters can only receive query parameter values in routable components with an @page directive.

Why is this an issue?

SupplyParameterFromQuery