Skip to content

DRAFT refactor: Improve page + authentication querying #1784

DRAFT refactor: Improve page + authentication querying

DRAFT refactor: Improve page + authentication querying #1784

Triggered via pull request January 18, 2024 13:04
Status Failure
Total duration 7m 11s
Artifacts
This run and associated checks have been archived and are scheduled for deletion. Learn more about checks retention

code-pr-check.yml

on: pull_request
Get Directories for Linting
4s
Get Directories for Linting
Build database upgrader
13s
Build database upgrader
Run javascript tests
15s
Run javascript tests
Matrix: Lint & Commit
Build and run unit tests
1m 18s
Build and run unit tests
Fit to window
Zoom out
Zoom in

Annotations

19 errors and 21 warnings
Lint & Commit (Dfe.PlanTech.Application/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.AzureFunctions/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.DatabaseUpgrader/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Domain/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Infrastructure.Contentful/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Infrastructure.Data/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Infrastructure.SignIn/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Web.Node/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Lint & Commit (Dfe.PlanTech.Web/)
Received status code 403. Resource not accessible by integration https://docs.github.com/rest/checks/runs#create-a-check-run
Build and run unit tests: tests/Dfe.PlanTech.Application.UnitTests/Content/Queries/GetPageQueryTests.cs#L288
Argument 1: cannot convert from 'Dfe.PlanTech.Application.Content.Queries.GetPageFromDbQuery' to 'Dfe.PlanTech.Application.Content.Queries.GetPageFromContentfulQuery'
Build and run unit tests: tests/Dfe.PlanTech.Application.UnitTests/Content/Queries/GetPageQueryTests.cs#L288
Argument 2: cannot convert from 'Microsoft.Extensions.Logging.ILogger<Dfe.PlanTech.Application.Content.Queries.GetPageQuery>' to 'Dfe.PlanTech.Application.Content.Queries.GetPageFromDbQuery'
Build and run unit tests: tests/Dfe.PlanTech.Application.UnitTests/Content/Queries/GetPageQueryTests.cs#L288
Argument 3: cannot convert from 'Dfe.PlanTech.Application.Caching.Interfaces.IQuestionnaireCacher' to 'Microsoft.Extensions.Logging.ILogger<Dfe.PlanTech.Application.Content.Queries.GetPageQuery>'
Build and run unit tests: tests/Dfe.PlanTech.Application.UnitTests/Content/Queries/GetPageQueryTests.cs#L288
Argument 4: cannot convert from 'Dfe.PlanTech.Application.Persistence.Interfaces.IContentRepository' to 'Dfe.PlanTech.Application.Caching.Interfaces.IQuestionnaireCacher'
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L74
There is no argument given that corresponds to the required parameter 'user' of 'PagesController.GetByRoute(string, IGetPageQuery, IUser, CancellationToken)'
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L78
Cannot convert type 'System.Threading.Tasks.Task<Microsoft.AspNetCore.Mvc.IActionResult>' to 'Microsoft.AspNetCore.Mvc.ViewResult' via a reference conversion, boxing conversion, unboxing conversion, wrapping conversion, or null type conversion
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L117
There is no argument given that corresponds to the required parameter 'user' of 'PagesController.GetByRoute(string, IGetPageQuery, IUser, CancellationToken)'
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L121
Cannot convert type 'System.Threading.Tasks.Task<Microsoft.AspNetCore.Mvc.IActionResult>' to 'Microsoft.AspNetCore.Mvc.ViewResult' via a reference conversion, boxing conversion, unboxing conversion, wrapping conversion, or null type conversion
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L160
There is no argument given that corresponds to the required parameter 'user' of 'PagesController.GetByRoute(string, IGetPageQuery, IUser, CancellationToken)'
Build and run unit tests: tests/Dfe.PlanTech.Web.UnitTests/Controllers/PagesControllerTests.cs#L164
Cannot convert type 'System.Threading.Tasks.Task<Microsoft.AspNetCore.Mvc.IActionResult>' to 'Microsoft.AspNetCore.Mvc.ViewResult' via a reference conversion, boxing conversion, unboxing conversion, wrapping conversion, or null type conversion
Build database upgrader
The "--output" option isn't supported when building a solution. Specifying a solution-level output path results in all projects copying outputs to the same directory, which can lead to inconsistent builds.
Build database upgrader
The "--output" option isn't supported when building a solution. Specifying a solution-level output path results in all projects copying outputs to the same directory, which can lead to inconsistent builds.
Lint & Commit (Dfe.PlanTech.Application/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.AzureFunctions/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.DatabaseUpgrader/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Domain/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Infrastructure.Contentful/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Infrastructure.Data/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Infrastructure.SignIn/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Web.Node/)
Some check runs could not be created.
Lint & Commit (Dfe.PlanTech.Web/)
Some check runs could not be created.
Build and run unit tests
The "--output" option isn't supported when building a solution. Specifying a solution-level output path results in all projects copying outputs to the same directory, which can lead to inconsistent builds.
Build and run unit tests: src/Dfe.PlanTech.Domain/Content/Interfaces/IRichTextContent.cs#L38
Reduce the number of generic parameters in the 'IRichTextContent' interface to no more than the 2 authorized. (https://rules.sonarsource.com/csharp/RSPEC-2436)
Build and run unit tests: src/Dfe.PlanTech.Domain/Questionnaire/Interfaces/ISection.cs#L19
Reduce the number of generic parameters in the 'ISection' interface to no more than the 2 authorized. (https://rules.sonarsource.com/csharp/RSPEC-2436)
Build and run unit tests: src/Dfe.PlanTech.Domain/Content/Interfaces/IRichTextContent.cs#L23
"Find" method should be used instead of the "FirstOrDefault" extension method. (https://rules.sonarsource.com/csharp/RSPEC-6602)
Build and run unit tests: src/Dfe.PlanTech.Application/Content/Queries/GetPageQuery.cs#L10
Remove this unread private field '_logger' or refactor the code to use its value. (https://rules.sonarsource.com/csharp/RSPEC-4487)
Build and run unit tests: src/Dfe.PlanTech.Application/Submissions/Queries/SubmissionStatusProcessor.cs#L65
"Find" method should be used instead of the "FirstOrDefault" extension method. (https://rules.sonarsource.com/csharp/RSPEC-6602)
Build and run unit tests: src/Dfe.PlanTech.Application/Submissions/Queries/GetSubmissionStatusesQuery.cs#L65
Extract this nested ternary operation into an independent statement. (https://rules.sonarsource.com/csharp/RSPEC-3358)
Build and run unit tests: src/Dfe.PlanTech.Infrastructure.Contentful/Content/Renderers/Models/RichTextRenderer.cs#L51
"Find" method should be used instead of the "FirstOrDefault" extension method. (https://rules.sonarsource.com/csharp/RSPEC-6602)
Build and run unit tests: src/Dfe.PlanTech.Infrastructure.Contentful/Persistence/QueryBuilders.cs#L99
Make sure that this accessibility bypass is safe here. (https://rules.sonarsource.com/csharp/RSPEC-3011)
Build and run unit tests: src/Dfe.PlanTech.Infrastructure.Contentful/Persistence/QueryBuilders.cs#L101
'System.Exception' should not be thrown by user code. (https://rules.sonarsource.com/csharp/RSPEC-112)