$ rm -r be && mv symfony be #187
Annotations
102 errors and 104 warnings
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L186
SearchQuery.php: The method applyTextMatchParamOnQuery uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. (ElseExpression, Clean Code Rules)
|
runs-on (ubuntu-latest) / phpmd:
tests/PostsQuery/BaseQueryTest.php#L48
BaseQueryTest.php: The method testReOrderNestedPosts uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. (ElseExpression, Clean Code Rules)
|
runs-on (ubuntu-latest) / phpmd
Process completed with exit code 2.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/AssetController.php#L30
AssetController.php: binaryOp.invalid: Binary operation "." between array|bool|float|int|string|null and non-falsy-string results in an error.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/ForumsController.php#L13
ForumsController.php: missingType.iterableValue: Method App\Controller\ForumsController::query() return type has no value type specified in iterable type array.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L49
PostsController.php: missingType.iterableValue: Method App\Controller\PostsController::query() return type has no value type specified in iterable type array.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L60
PostsController.php: method.nonObject: Cannot call method setParams() on mixed.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L60
PostsController.php: argument.type: Parameter #1 $json of function Safe\json_decode expects string, string|null given.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L77
PostsController.php: method.nonObject: Cannot call method addDefaultParamsThenValidate() on mixed.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L90
PostsController.php: argument.templateType: Unable to resolve the template type TConcatValue in call to method Illuminate\Support\Collection<*NEVER*,*NEVER*>::concat()
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L91
PostsController.php: argument.type: Parameter #1 $source of method Illuminate\Support\Collection<*NEVER*,*NEVER*>::concat() expects iterable<(int|string), mixed>, mixed given.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L96
PostsController.php: argument.type: Parameter #1 $source of method Illuminate\Support\Collection<*NEVER*,mixed>::concat() expects iterable<(int|string), mixed>, mixed given.
|
runs-on (ubuntu-latest) / phpstan:
src/Controller/PostsController.php#L102
PostsController.php: argument.type: Parameter #1 $callback of method Illuminate\Support\Collection<string,array<string, int>|Illuminate\Support\Collection<int, App\Entity\Post\Reply>|Illuminate\Support\Collection<int, App\Entity\Post\SubReply>|Illuminate\Support\Collection<int, App\Entity\Post\Thread>|int>::flatMap() expects callable(array{thread: int, reply: int, subReply?: int}|Illuminate\Support\Collection<int, App\Entity\Post\Reply>|Illuminate\Support\Collection<int, App\Entity\Post\SubReply>|Illuminate\Support\Collection<int, App\Entity\Post\Thread>|int, string): (array<int, int>|Illuminate\Support\Collection<int, int>), Closure(Illuminate\Support\Collection): Illuminate\Support\Collection<int, int> given.
|
runs-on (ubuntu-latest) / psalm:
src/Controller/AssetController.php#L11
AssetController.php: UnusedClass: Class App\Controller\AssetController is never used
|
runs-on (ubuntu-latest) / psalm:
src/Controller/AssetController.php#L30
AssetController.php: PossiblyNullOperand: Cannot concatenate with a possibly null UnitEnum|array<array-key, mixed>|null|scalar
|
runs-on (ubuntu-latest) / psalm:
src/Controller/ForumsController.php#L9
ForumsController.php: UnusedClass: Class App\Controller\ForumsController is never used
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L31
PostsController.php: UnusedClass: Class App\Controller\PostsController is never used
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L60
PostsController.php: MixedArgument: Argument 1 of App\PostsQuery\ParamsValidator::setParams cannot be mixed, expecting array<array-key, array<array-key, mixed>>
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L60
PostsController.php: PossiblyNullArgument: Argument 1 of Safe\json_decode cannot be null, possibly null value provided
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L91
PostsController.php: MixedArgument: Argument 1 of Illuminate\Support\Collection::concat cannot be mixed, expecting iterable<array-key, mixed>
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L92
PostsController.php: QueryBuilderSetParameter: To improve performance set explicit type for objects
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L96
PostsController.php: MixedArgument: Argument 1 of Illuminate\Support\Collection::concat cannot be mixed, expecting iterable<array-key, mixed>
|
runs-on (ubuntu-latest) / psalm:
src/Controller/PostsController.php#L97
PostsController.php: QueryBuilderSetParameter: To improve performance set explicit type for objects
|
runs-on (ubuntu-latest) / phpcs:
public/index.php#L5
index.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
public/index.php#L5
index.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
tests/bootstrap.php#L5
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
tests/bootstrap.php#L5
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
tests/bootstrap.php#L8
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
tests/bootstrap.php#L8
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
tests/Repository/Post/PostRepositoryFactoryTest.php#L24
PostRepositoryFactoryTest.php: Squiz.WhiteSpace.SuperfluousWhitespace.EndLine: Whitespace found at end of line
|
runs-on (ubuntu-latest) / phpcs:
config/preload.php#L3
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
config/preload.php#L3
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (ubuntu-latest) / phpcs:
config/preload.php#L4
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (ubuntu-latest) / phpcs
Process completed with exit code 2.
|
runs-on (ubuntu-latest) / pint
Process completed with exit code 1.
|
runs-on (ubuntu-latest) / php-cs-fixer
Process completed with exit code 8.
|
runs-on (windows-latest) / phpstan
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / phpstan
Process completed with exit code 2.
|
runs-on (ubuntu-latest) / phan:
config/preload.php#L4
preload.php: PhanMissingRequireFile: Missing required file "/home/runner/work/open-tbm/open-tbm/be/var/cache/prod/App_KernelProdContainer.preload.php"
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/BaseQuery.php#L288
BaseQuery.php: PhanNonClassMethodCall: Call to method values on non-class type string
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/BaseQuery.php#L293
BaseQuery.php: PhanNonClassMethodCall: Call to method filter on non-class type string
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/BaseQuery.php#L301
BaseQuery.php: PhanNonClassMethodCall: Call to method first on non-class type string
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/BaseQuery.php#L334
BaseQuery.php: PhanNonClassMethodCall: Call to method map on non-class type string
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/BaseQuery.php#L340
BaseQuery.php: PhanNonClassMethodCall: Call to method sortBy on non-class type string
|
runs-on (ubuntu-latest) / phan:
src/PostsQuery/ParamsValidator.php#L54
ParamsValidator.php: PhanTypeMismatchArgumentReal: Argument 1 ($values) is 'fid' of type 'fid' but \Illuminate\Support\Collection::push() takes 'authorExpGrade'[]|'authorUid'[]|'latestReplierUid'[]|'pid'[]|'replySubReplyCount'[]|'spid'[]|'threadReplyCount'[]|'threadShareCount'[]|'threadViewCount'[]|'tid'[] (real type array) defined at vendor/illuminate/collections/Collection.php:1018
|
runs-on (ubuntu-latest) / phan:
tests/Entity/BlobResourceGetterTest.php#L28
BlobResourceGetterTest.php: PhanUndeclaredClassMethod: Call to method __construct from undeclared class \TbClient\Wrapper\PostContentWrapper
|
runs-on (ubuntu-latest) / phan:
tests/Entity/BlobResourceGetterTest.php#L29
BlobResourceGetterTest.php: PhanUndeclaredClassMethod: Call to method mergeFromJsonString from undeclared class \TbClient\Wrapper\PostContentWrapper
|
runs-on (ubuntu-latest) / phan:
tests/Entity/BlobResourceGetterTest.php#L30
BlobResourceGetterTest.php: PhanUndeclaredClassMethod: Call to method serializeToString from undeclared class \TbClient\Wrapper\PostContentWrapper
|
runs-on (windows-latest) / phpmd
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / phpmd
Process completed with exit code 2.
|
runs-on (windows-latest) / phan
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / phan
Process completed with exit code 2.
|
runs-on (windows-latest) / php-cs-fixer
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / php-cs-fixer
Process completed with exit code 2.
|
runs-on (windows-latest) / phpcs
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / phpcs
Process completed with exit code 2.
|
runs-on (windows-latest) / phpunit-infection
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / phpunit-infection
Process completed with exit code 2.
|
runs-on (windows-latest) / phpunit-infection
Process completed with exit code 1.
|
runs-on (windows-latest) / pint
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / pint
Process completed with exit code 2.
|
runs-on (ubuntu-latest) / phpunit-infection
Process completed with exit code 2.
|
runs-on (windows-latest) / psalm
Your lock file does not contain a compatible set of packages. Please run composer update.
Problem 1
- Root composer.json requires PHP extension ext-intl * but it is missing from your system. Install or enable PHP's intl extension.
To enable extensions, verify that they are enabled in your .ini files:
- C:\tools\php\php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-intl` to temporarily ignore these required extensions.
|
runs-on (windows-latest) / psalm
Process completed with exit code 2.
|
runs-on (macos-latest) / phpcs
Process completed with exit code 2.
|
runs-on (macos-latest) / phpcs:
config/preload.php#L3
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (macos-latest) / phpcs:
config/preload.php#L3
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (macos-latest) / phpcs:
config/preload.php#L4
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (macos-latest) / phpcs:
config/preload.php#L4
preload.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (macos-latest) / phpcs:
tests/Repository/Post/PostRepositoryFactoryTest.php#L24
PostRepositoryFactoryTest.php: Squiz.WhiteSpace.SuperfluousWhitespace.EndLine: Whitespace found at end of line
|
runs-on (macos-latest) / phpcs:
tests/bootstrap.php#L5
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (macos-latest) / phpcs:
tests/bootstrap.php#L5
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (macos-latest) / phpcs:
tests/bootstrap.php#L8
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (macos-latest) / phpcs:
tests/bootstrap.php#L8
bootstrap.php: PSR12.Operators.OperatorSpacing.NoSpaceAfter: Expected at least 1 space after "."; 0 found
|
runs-on (macos-latest) / phpcs:
public/index.php#L5
index.php: PSR12.Operators.OperatorSpacing.NoSpaceBefore: Expected at least 1 space before "."; 0 found
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L186
SearchQuery.php: The method applyTextMatchParamOnQuery uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. (ElseExpression, Clean Code Rules)
|
runs-on (macos-latest) / phpmd:
tests/PostsQuery/BaseQueryTest.php#L48
BaseQueryTest.php: The method testReOrderNestedPosts uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. (ElseExpression, Clean Code Rules)
|
runs-on (macos-latest) / phpmd
Process completed with exit code 2.
|
runs-on (macos-latest) / php-cs-fixer
Process completed with exit code 8.
|
runs-on (macos-latest) / phpstan:
src/Controller/AssetController.php#L30
AssetController.php: binaryOp.invalid: Binary operation "." between array|bool|float|int|string|null and non-falsy-string results in an error.
|
runs-on (macos-latest) / phpstan:
src/Controller/ForumsController.php#L13
ForumsController.php: missingType.iterableValue: Method App\Controller\ForumsController::query() return type has no value type specified in iterable type array.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L49
PostsController.php: missingType.iterableValue: Method App\Controller\PostsController::query() return type has no value type specified in iterable type array.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L60
PostsController.php: method.nonObject: Cannot call method setParams() on mixed.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L60
PostsController.php: argument.type: Parameter #1 $json of function Safe\json_decode expects string, string|null given.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L77
PostsController.php: method.nonObject: Cannot call method addDefaultParamsThenValidate() on mixed.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L90
PostsController.php: argument.templateType: Unable to resolve the template type TConcatValue in call to method Illuminate\Support\Collection<*NEVER*,*NEVER*>::concat()
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L91
PostsController.php: argument.type: Parameter #1 $source of method Illuminate\Support\Collection<*NEVER*,*NEVER*>::concat() expects iterable<(int|string), mixed>, mixed given.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L96
PostsController.php: argument.type: Parameter #1 $source of method Illuminate\Support\Collection<*NEVER*,mixed>::concat() expects iterable<(int|string), mixed>, mixed given.
|
runs-on (macos-latest) / phpstan:
src/Controller/PostsController.php#L102
PostsController.php: argument.type: Parameter #1 $callback of method Illuminate\Support\Collection<string,array<string, int>|Illuminate\Support\Collection<int, App\Entity\Post\Reply>|Illuminate\Support\Collection<int, App\Entity\Post\SubReply>|Illuminate\Support\Collection<int, App\Entity\Post\Thread>|int>::flatMap() expects callable(array{thread: int, reply: int, subReply?: int}|Illuminate\Support\Collection<int, App\Entity\Post\Reply>|Illuminate\Support\Collection<int, App\Entity\Post\SubReply>|Illuminate\Support\Collection<int, App\Entity\Post\Thread>|int, string): (array<int, int>|Illuminate\Support\Collection<int, int>), Closure(Illuminate\Support\Collection): Illuminate\Support\Collection<int, int> given.
|
runs-on (macos-latest) / phan
Process completed with exit code 1.
|
runs-on (macos-latest) / pint
Process completed with exit code 1.
|
runs-on (macos-latest) / phpunit-infection
Process completed with exit code 2.
|
runs-on (macos-latest) / psalm:
src/Controller/AssetController.php#L11
AssetController.php: UnusedClass: Class App\Controller\AssetController is never used
|
runs-on (macos-latest) / psalm:
src/Controller/AssetController.php#L30
AssetController.php: PossiblyNullOperand: Cannot concatenate with a possibly null UnitEnum|array<array-key, mixed>|null|scalar
|
runs-on (macos-latest) / psalm:
src/Controller/ForumsController.php#L9
ForumsController.php: UnusedClass: Class App\Controller\ForumsController is never used
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L31
PostsController.php: UnusedClass: Class App\Controller\PostsController is never used
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L60
PostsController.php: MixedArgument: Argument 1 of App\PostsQuery\ParamsValidator::setParams cannot be mixed, expecting array<array-key, array<array-key, mixed>>
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L60
PostsController.php: PossiblyNullArgument: Argument 1 of Safe\json_decode cannot be null, possibly null value provided
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L91
PostsController.php: MixedArgument: Argument 1 of Illuminate\Support\Collection::concat cannot be mixed, expecting iterable<array-key, mixed>
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L92
PostsController.php: QueryBuilderSetParameter: To improve performance set explicit type for objects
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L96
PostsController.php: MixedArgument: Argument 1 of Illuminate\Support\Collection::concat cannot be mixed, expecting iterable<array-key, mixed>
|
runs-on (macos-latest) / psalm:
src/Controller/PostsController.php#L97
PostsController.php: QueryBuilderSetParameter: To improve performance set explicit type for objects
|
runs-on (ubuntu-latest) / phpmd:
src/Controller/PostsController.php#L31
PostsController.php: The class PostsController has a coupling between objects value of 25. Consider to reduce the number of dependencies under 13. (CouplingBetweenObjects, Design Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/BaseQuery.php#L20
BaseQuery.php: The class BaseQuery has a coupling between objects value of 14. Consider to reduce the number of dependencies under 13. (CouplingBetweenObjects, Design Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/IndexQuery.php#L27
IndexQuery.php: The method query() has a Cyclomatic Complexity of 12. The configured cyclomatic complexity threshold is 10. (CyclomaticComplexity, Code Size Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/IndexQuery.php#L27
IndexQuery.php: The method query() has an NPath complexity of 200. The configured NPath complexity threshold is 200. (NPathComplexity, Code Size Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has a Cyclomatic Complexity of 12. The configured cyclomatic complexity threshold is 10. (CyclomaticComplexity, Code Size Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has an NPath complexity of 384. The configured NPath complexity threshold is 200. (NPathComplexity, Code Size Rules)
|
runs-on (ubuntu-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has 104 lines of code. Current threshold is set to 100. Avoid really long methods. (ExcessiveMethodLength, Code Size Rules)
|
runs-on (ubuntu-latest) / phpmd:
tests/PostsQuery/BaseQueryTest.php#L53
BaseQueryTest.php: The method provideReOrderNestedPostsData() has 168 lines of code. Current threshold is set to 100. Avoid really long methods. (ExcessiveMethodLength, Code Size Rules)
|
runs-on (ubuntu-latest) / phpstan
Cache save failed.
|
runs-on (ubuntu-latest) / psalm
Cache save failed.
|
runs-on (ubuntu-latest) / phpcs
Cache save failed.
|
runs-on (ubuntu-latest) / phpcs:
src/Controller/PostsController.php#L53
PostsController.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 146 characters
|
runs-on (ubuntu-latest) / phpcs:
src/PostsQuery/SearchQuery.php#L126
SearchQuery.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 133 characters
|
runs-on (ubuntu-latest) / phpcs:
src/PostsQuery/BaseQuery.php#L218
BaseQuery.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 121 characters
|
runs-on (ubuntu-latest) / phpcs:
src/EventListener/SerializeToJson.php#L10
SerializeToJson.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 170 characters
|
runs-on (ubuntu-latest) / pint
Cache save failed.
|
runs-on (ubuntu-latest) / pint:
public/index.php#L1
index.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / pint:
tests/bootstrap.php#L1
bootstrap.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / pint:
tests/EventListener/ShowReactJsonViewTest.php#L1
ShowReactJsonViewTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / pint:
tests/EventListener/PrettyJsonResponseTest.php#L1
PrettyJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / pint:
tests/EventListener/ExceptionToJsonResponseTest.php#L1
ExceptionToJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / pint:
tests/Repository/Post/PostRepositoryFactoryTest.php#L1
PostRepositoryFactoryTest.php: PHP-CS-Fixer.no_whitespace_in_blank_line: Found violation(s) of type: no_whitespace_in_blank_line
|
runs-on (ubuntu-latest) / pint:
config/preload.php#L1
preload.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / pint:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.function_declaration: Found violation(s) of type: function_declaration
|
runs-on (ubuntu-latest) / pint:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / pint:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.braces_position: Found violation(s) of type: braces_position
|
runs-on (ubuntu-latest) / php-cs-fixer:
public/index.php#L1
index.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / php-cs-fixer:
tests/bootstrap.php#L1
bootstrap.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / php-cs-fixer:
tests/EventListener/ShowReactJsonViewTest.php#L1
ShowReactJsonViewTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / php-cs-fixer:
tests/EventListener/PrettyJsonResponseTest.php#L1
PrettyJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / php-cs-fixer:
tests/EventListener/ExceptionToJsonResponseTest.php#L1
ExceptionToJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / php-cs-fixer:
tests/Repository/Post/PostRepositoryFactoryTest.php#L1
PostRepositoryFactoryTest.php: PHP-CS-Fixer.no_whitespace_in_blank_line: Found violation(s) of type: no_whitespace_in_blank_line
|
runs-on (ubuntu-latest) / php-cs-fixer:
config/preload.php#L1
preload.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (ubuntu-latest) / php-cs-fixer:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.function_declaration: Found violation(s) of type: function_declaration
|
runs-on (ubuntu-latest) / php-cs-fixer:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (ubuntu-latest) / php-cs-fixer:
src/Controller/PostsController.php#L1
PostsController.php: PHP-CS-Fixer.braces_position: Found violation(s) of type: braces_position
|
runs-on (ubuntu-latest) / phan
Cache save failed.
|
runs-on (ubuntu-latest) / phan:
public/index.php#L7
index.php: PhanUnreferencedClosure: Possibly zero references to Closure(array $context)
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L11
AssetController.php: PhanUnreferencedClass: Possibly zero references to class \App\Controller\AssetController
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L21
AssetController.php: PhanUnreferencedPublicMethod: Possibly zero references to public method \App\Controller\AssetController::getAsset()
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L24
AssetController.php: PhanPartialTypeMismatchArgument: Argument 1 ($content) is preg_replace_callback_array(['#/npm/(?<filename>\\w+)@(\\d+\\.?){3}/\\+esm#'=>(fn),'@^//# sourceMappingURL=.+$@m'=>(fn)], $this->filesystem->readFile(($this->getParameter('kernel.project_dir') . "/public/react-json-view/{$filename}"))) of type string|string[] but \Symfony\Component\HttpFoundation\Response::__construct() takes ?string (string[] is incompatible) defined at vendor/symfony/http-foundation/Response.php:200
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L26
AssetController.php: PhanTypeMismatchArgumentInternal: Argument 1 ($pattern) is ['#/npm/(?<filename>\\w+)@(\\d+\\.?){3}/\\+esm#'=>(fn),'@^//# sourceMappingURL=.+$@m'=>(fn)] of type array{\x23/npm/\x28\x3f\x3cfilename\x3e\\w+\x29\x40\x28\\d+\\.\x3f\x29\x7b3\x7d/\\+esm\x23:Closure(array):string,\x40^//\x23\x20sourceMappingURL\x3d.+$\x40m:Closure():''} but \preg_replace_callback_array() takes array<string,callable(array):string>
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L26
AssetController.php: PhanUnreferencedClosure: Possibly zero references to Closure(array $m)
|
runs-on (ubuntu-latest) / phan:
src/Controller/AssetController.php#L28
AssetController.php: PhanUnreferencedClosure: Possibly zero references to Closure()
|
runs-on (ubuntu-latest) / phan:
src/Controller/ForumsController.php#L9
ForumsController.php: PhanUnreferencedClass: Possibly zero references to class \App\Controller\ForumsController
|
runs-on (ubuntu-latest) / phan:
src/Controller/ForumsController.php#L14
ForumsController.php: PhanUnreferencedPublicMethod: Possibly zero references to public method \App\Controller\ForumsController::query()
|
runs-on (ubuntu-latest) / phan:
src/Controller/PostsController.php#L31
PostsController.php: PhanUnreferencedClass: Possibly zero references to class \App\Controller\PostsController
|
runs-on (windows-latest) / phpunit-infection
No files were found with the provided path: be/coverage/clover.xml. No artifacts will be uploaded.
|
runs-on (ubuntu-latest) / phpunit-infection
Cache save failed.
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/Entity/BlobResourceGetter.php#L44
Escaped Mutant for Mutator "FunctionCallRemoval":
--- Original
+++ New
@@ @@
if ($value === null) {
return null;
}
- rewind($value);
+
return stream_get_contents($value);
}
}
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L21
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
public function __invoke(ExceptionEvent $event) : void
{
$exception = $event->getThrowable();
- if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
+ if (true && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
} elseif ($exception instanceof ValidationFailedException) {
$event->setResponse(JsonResponse::fromJsonString(
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L21
Escaped Mutant for Mutator "LogicalAnd":
--- Original
+++ New
@@ @@
public function __invoke(ExceptionEvent $event) : void
{
$exception = $event->getThrowable();
- if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
+ if ($exception instanceof HttpException || collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
} elseif ($exception instanceof ValidationFailedException) {
$event->setResponse(JsonResponse::fromJsonString(
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L26
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
$exception = $event->getThrowable();
if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
- } elseif ($exception instanceof ValidationFailedException) {
+ } elseif (true) {
$event->setResponse(JsonResponse::fromJsonString(
// https://github.com/symfony/serializer/blob/7.1/Normalizer/ConstraintViolationListNormalizer.php
$this->serializer->serialize(['errorCode' => 40000, 'errorInfo' => $exception->getViolations()], 'json')
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/PrettyJsonResponse.php#L16
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
{
// https://github.com/laravel/framework/issues/3929#issuecomment-935123918
$response = $event->getResponse();
- if ($response instanceof JsonResponse) {
+ if (true) {
$response->setEncodingOptions(JSON_PRETTY_PRINT);
}
}
}
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L20
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
{
$request = $event->getRequest();
$response = $event->getResponse();
- if (!$response instanceof JsonResponse || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
+ if (!true || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
return;
}
$json = $response->getContent();
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L20
Escaped Mutant for Mutator "LogicalOr":
--- Original
+++ New
@@ @@
{
$request = $event->getRequest();
$response = $event->getResponse();
- if (!$response instanceof JsonResponse || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
+ if (!$response instanceof JsonResponse && !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
return;
}
$json = $response->getContent();
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L25
Escaped Mutant for Mutator "MBString":
--- Original
+++ New
@@ @@
return;
}
$json = $response->getContent();
- $jsonLength = mb_strlen($json);
+ $jsonLength = strlen($json);
$assetsUrl = collect(['react-json-view', 'react', 'react-dom'])->mapWithKeys(fn($asset) => [$asset => $this->assets->getUrl("/assets/{$asset}.js")]);
$event->setResponse(new Response(<<<HTML
<html>
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/Helper.php#L85
Escaped Mutant for Mutator "DecrementInteger":
--- Original
+++ New
@@ @@
];
public static function abortAPI(int $errorCode) : never
{
- $statusCode = 0;
+ $statusCode = -1;
$errorInfo = null;
foreach (self::ERROR_STATUS_CODE_INFO as $infoStatusCode => $infoErrorInfo) {
if (\array_key_exists($errorCode, $infoErrorInfo)) {
|
runs-on (ubuntu-latest) / phpunit-infection:
be/src/PostsQuery/CursorCodec.php#L34
Escaped Mutant for Mutator "LessThan":
--- Original
+++ New
@@ @@
return '0';
}
$prefix = match (true) {
- \is_int($cursor) && $cursor < 0 => '-',
+ \is_int($cursor) && $cursor <= 0 => '-',
\is_string($cursor) => 'S',
default => '',
};
|
runs-on (macos-latest) / phpcs
Cache save failed.
|
runs-on (macos-latest) / phpcs:
src/Controller/PostsController.php#L53
PostsController.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 146 characters
|
runs-on (macos-latest) / phpcs:
src/PostsQuery/BaseQuery.php#L218
BaseQuery.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 121 characters
|
runs-on (macos-latest) / phpcs:
src/PostsQuery/SearchQuery.php#L126
SearchQuery.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 133 characters
|
runs-on (macos-latest) / phpcs:
src/EventListener/SerializeToJson.php#L10
SerializeToJson.php: Generic.Files.LineLength.TooLong: Line exceeds 120 characters; contains 170 characters
|
runs-on (macos-latest) / phpmd:
src/Controller/PostsController.php#L31
PostsController.php: The class PostsController has a coupling between objects value of 25. Consider to reduce the number of dependencies under 13. (CouplingBetweenObjects, Design Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/BaseQuery.php#L20
BaseQuery.php: The class BaseQuery has a coupling between objects value of 14. Consider to reduce the number of dependencies under 13. (CouplingBetweenObjects, Design Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/IndexQuery.php#L27
IndexQuery.php: The method query() has a Cyclomatic Complexity of 12. The configured cyclomatic complexity threshold is 10. (CyclomaticComplexity, Code Size Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/IndexQuery.php#L27
IndexQuery.php: The method query() has an NPath complexity of 200. The configured NPath complexity threshold is 200. (NPathComplexity, Code Size Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has a Cyclomatic Complexity of 12. The configured cyclomatic complexity threshold is 10. (CyclomaticComplexity, Code Size Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has an NPath complexity of 384. The configured NPath complexity threshold is 200. (NPathComplexity, Code Size Rules)
|
runs-on (macos-latest) / phpmd:
src/PostsQuery/SearchQuery.php#L64
SearchQuery.php: The method applyQueryParamsOnQuery() has 104 lines of code. Current threshold is set to 100. Avoid really long methods. (ExcessiveMethodLength, Code Size Rules)
|
runs-on (macos-latest) / phpmd:
tests/PostsQuery/BaseQueryTest.php#L53
BaseQueryTest.php: The method provideReOrderNestedPostsData() has 168 lines of code. Current threshold is set to 100. Avoid really long methods. (ExcessiveMethodLength, Code Size Rules)
|
runs-on (macos-latest) / php-cs-fixer
Cache save failed.
|
runs-on (macos-latest) / php-cs-fixer:
config/preload.php#L1
preload.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / php-cs-fixer:
tests/Repository/Post/PostRepositoryFactoryTest.php#L1
PostRepositoryFactoryTest.php: PHP-CS-Fixer.no_whitespace_in_blank_line: Found violation(s) of type: no_whitespace_in_blank_line
|
runs-on (macos-latest) / php-cs-fixer:
tests/bootstrap.php#L1
bootstrap.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / php-cs-fixer:
tests/EventListener/PrettyJsonResponseTest.php#L1
PrettyJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / php-cs-fixer:
tests/EventListener/ShowReactJsonViewTest.php#L1
ShowReactJsonViewTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / php-cs-fixer:
tests/EventListener/ExceptionToJsonResponseTest.php#L1
ExceptionToJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / php-cs-fixer:
public/index.php#L1
index.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / php-cs-fixer:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.method_argument_space: Found violation(s) of type: method_argument_space
|
runs-on (macos-latest) / php-cs-fixer:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.blank_line_after_opening_tag: Found violation(s) of type: blank_line_after_opening_tag
|
runs-on (macos-latest) / php-cs-fixer:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / phpstan
Cache save failed.
|
runs-on (macos-latest) / pint:
config/preload.php#L1
preload.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / pint:
tests/Repository/Post/PostRepositoryFactoryTest.php#L1
PostRepositoryFactoryTest.php: PHP-CS-Fixer.no_whitespace_in_blank_line: Found violation(s) of type: no_whitespace_in_blank_line
|
runs-on (macos-latest) / pint:
tests/bootstrap.php#L1
bootstrap.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / pint:
tests/EventListener/PrettyJsonResponseTest.php#L1
PrettyJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / pint:
tests/EventListener/ShowReactJsonViewTest.php#L1
ShowReactJsonViewTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / pint:
tests/EventListener/ExceptionToJsonResponseTest.php#L1
ExceptionToJsonResponseTest.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / pint:
public/index.php#L1
index.php: PHP-CS-Fixer.concat_space: Found violation(s) of type: concat_space
|
runs-on (macos-latest) / pint:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.method_argument_space: Found violation(s) of type: method_argument_space
|
runs-on (macos-latest) / pint:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.blank_line_after_opening_tag: Found violation(s) of type: blank_line_after_opening_tag
|
runs-on (macos-latest) / pint:
src/DTO/User/AuthorExpGrade.php#L1
AuthorExpGrade.php: PHP-CS-Fixer.trailing_comma_in_multiline: Found violation(s) of type: trailing_comma_in_multiline
|
runs-on (macos-latest) / phpunit-infection:
be/src/Entity/BlobResourceGetter.php#L44
Escaped Mutant for Mutator "FunctionCallRemoval":
--- Original
+++ New
@@ @@
if ($value === null) {
return null;
}
- rewind($value);
+
return stream_get_contents($value);
}
}
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L21
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
public function __invoke(ExceptionEvent $event) : void
{
$exception = $event->getThrowable();
- if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
+ if (true && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
} elseif ($exception instanceof ValidationFailedException) {
$event->setResponse(JsonResponse::fromJsonString(
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L21
Escaped Mutant for Mutator "LogicalAnd":
--- Original
+++ New
@@ @@
public function __invoke(ExceptionEvent $event) : void
{
$exception = $event->getThrowable();
- if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
+ if ($exception instanceof HttpException || collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
} elseif ($exception instanceof ValidationFailedException) {
$event->setResponse(JsonResponse::fromJsonString(
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ExceptionToJsonResponse.php#L26
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
$exception = $event->getThrowable();
if ($exception instanceof HttpException && collect(Helper::ERROR_STATUS_CODE_INFO)->flatMap(static fn(array $codes) => array_keys($codes))->contains($exception->getCode())) {
$event->setResponse(JsonResponse::fromJsonString($exception->getMessage()));
- } elseif ($exception instanceof ValidationFailedException) {
+ } elseif (true) {
$event->setResponse(JsonResponse::fromJsonString(
// https://github.com/symfony/serializer/blob/7.1/Normalizer/ConstraintViolationListNormalizer.php
$this->serializer->serialize(['errorCode' => 40000, 'errorInfo' => $exception->getViolations()], 'json')
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/PrettyJsonResponse.php#L16
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
{
// https://github.com/laravel/framework/issues/3929#issuecomment-935123918
$response = $event->getResponse();
- if ($response instanceof JsonResponse) {
+ if (true) {
$response->setEncodingOptions(JSON_PRETTY_PRINT);
}
}
}
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L20
Escaped Mutant for Mutator "InstanceOf_":
--- Original
+++ New
@@ @@
{
$request = $event->getRequest();
$response = $event->getResponse();
- if (!$response instanceof JsonResponse || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
+ if (!true || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
return;
}
$json = $response->getContent();
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L20
Escaped Mutant for Mutator "LogicalOr":
--- Original
+++ New
@@ @@
{
$request = $event->getRequest();
$response = $event->getResponse();
- if (!$response instanceof JsonResponse || !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
+ if (!$response instanceof JsonResponse && !in_array('text/html', $request->getAcceptableContentTypes(), true)) {
return;
}
$json = $response->getContent();
|
runs-on (macos-latest) / phpunit-infection:
be/src/EventListener/ShowReactJsonView.php#L25
Escaped Mutant for Mutator "MBString":
--- Original
+++ New
@@ @@
return;
}
$json = $response->getContent();
- $jsonLength = mb_strlen($json);
+ $jsonLength = strlen($json);
$assetsUrl = collect(['react-json-view', 'react', 'react-dom'])->mapWithKeys(fn($asset) => [$asset => $this->assets->getUrl("/assets/{$asset}.js")]);
$event->setResponse(new Response(<<<HTML
<html>
|
runs-on (macos-latest) / phpunit-infection:
be/src/Helper.php#L85
Escaped Mutant for Mutator "DecrementInteger":
--- Original
+++ New
@@ @@
];
public static function abortAPI(int $errorCode) : never
{
- $statusCode = 0;
+ $statusCode = -1;
$errorInfo = null;
foreach (self::ERROR_STATUS_CODE_INFO as $infoStatusCode => $infoErrorInfo) {
if (\array_key_exists($errorCode, $infoErrorInfo)) {
|
runs-on (macos-latest) / phpunit-infection:
be/src/PostsQuery/CursorCodec.php#L34
Escaped Mutant for Mutator "LessThan":
--- Original
+++ New
@@ @@
return '0';
}
$prefix = match (true) {
- \is_int($cursor) && $cursor < 0 => '-',
+ \is_int($cursor) && $cursor <= 0 => '-',
\is_string($cursor) => 'S',
default => '',
};
|
Artifacts
Produced during runtime
Name | Size | |
---|---|---|
coverage-macos-latest
Expired
|
6.31 KB |
|
coverage-ubuntu-latest
Expired
|
6.31 KB |
|