Skip to content

Commit

Permalink
generate baseline
Browse files Browse the repository at this point in the history
  • Loading branch information
staabm committed Nov 14, 2024
1 parent 3437398 commit 3379930
Showing 1 changed file with 85 additions and 23 deletions.
108 changes: 85 additions & 23 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
@@ -1,80 +1,142 @@
parameters:
ignoreErrors:
-
message: "#^Unresolvable Query\\: Cannot resolve query with variable type\\: non\\-empty\\-string\\.$#"
message: '#^Unresolvable Query\: Cannot resolve query with variable type\: non\-empty\-string\.$#'
identifier: dba.unresolvableQuery
count: 2
path: src/Analyzer/QueryPlanAnalyzerMysql.php

-
message: """
#^Call to deprecated method resolveQueryString\\(\\) of class staabm\\\\PHPStanDba\\\\QueryReflection\\\\QueryReflection\\:
use resolveQueryStrings\\(\\) instead$#
"""
message: '''
#^Call to deprecated method resolveQueryString\(\) of class staabm\\PHPStanDba\\QueryReflection\\QueryReflection\:
use resolveQueryStrings\(\) instead$#
'''
identifier: method.deprecated
count: 1
path: src/Extensions/DeployerRunMysqlQueryDynamicReturnTypeExtension.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\Constant\\\\ConstantArrayType is error\\-prone and deprecated\\. Use Type\\:\\:getConstantArrays\\(\\) instead\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\Constant\\ConstantArrayType is error\-prone and deprecated\. Use Type\:\:getConstantArrays\(\) instead\.$#'
identifier: phpstanApi.instanceofType
count: 2
path: src/Extensions/DibiConnectionFetchDynamicReturnTypeExtension.php

-
message: "#^Strict comparison using \\=\\=\\= between 'dibi' and 'dibi' will always evaluate to true\\.$#"
message: '#^Strict comparison using \=\=\= between ''dibi'' and ''dibi'' will always evaluate to true\.$#'
identifier: identical.alwaysTrue
count: 1
path: src/QueryReflection/DbaApi.php

-
message: """
#^Call to deprecated method resolvePreparedQueryString\\(\\) of class staabm\\\\PHPStanDba\\\\QueryReflection\\\\QueryReflection\\:
use resolvePreparedQueryStrings\\(\\) instead$#
"""
message: '#^Return type \(array\<array\{name\: string, table\?\: string, native_type\: string, len\: int, flags\: array\<int, string\>\}\>\|PDOException\|null\) of method staabm\\PHPStanDba\\QueryReflection\\PdoPgSqlQueryReflector\:\:simulateQuery\(\) should be covariant with return type \(array\<array\{name\: string, table\: string, native_type\: string, len\: int, flags\: array\<int, string\>, precision\: int\<0, max\>, pdo_type\: 0\|1\|2\|3\|4\|5\|6\|536870912\|1073741824\|2147483648\}\>\|PDOException\|null\) of method staabm\\PHPStanDba\\QueryReflection\\BasePdoQueryReflector\:\:simulateQuery\(\)$#'
identifier: method.childReturnType
count: 1
path: src/QueryReflection/PdoPgSqlQueryReflector.php

-
message: '''
#^Call to deprecated method resolvePreparedQueryString\(\) of class staabm\\PHPStanDba\\QueryReflection\\QueryReflection\:
use resolvePreparedQueryStrings\(\) instead$#
'''
identifier: method.deprecated
count: 1
path: src/QueryReflection/QueryReflection.php

-
message: "#^Casting to \\*NEVER\\* something that's already \\*NEVER\\*\\.$#"
message: '#^Casting to \*NEVER\* something that''s already \*NEVER\*\.$#'
identifier: cast.useless
count: 1
path: src/QueryReflection/QueryReflection.php

-
message: "#^Strict comparison using \\=\\=\\= between null and null will always evaluate to true\\.$#"
message: '#^Strict comparison using \=\=\= between null and null will always evaluate to true\.$#'
identifier: identical.alwaysTrue
count: 1
path: src/QueryReflection/QueryReflection.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\ConstantScalarType is error\\-prone and deprecated\\. Use Type\\:\\:isConstantScalarValue\\(\\) or Type\\:\\:getConstantScalarTypes\\(\\) or Type\\:\\:getConstantScalarValues\\(\\) instead\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\ConstantScalarType is error\-prone and deprecated\. Use Type\:\:isConstantScalarValue\(\) or Type\:\:getConstantScalarTypes\(\) or Type\:\:getConstantScalarValues\(\) instead\.$#'
identifier: phpstanApi.instanceofType
count: 1
path: src/QueryReflection/QuerySimulation.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\IntersectionType is error\\-prone and deprecated\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\IntersectionType is error\-prone and deprecated\.$#'
identifier: phpstanApi.instanceofType
count: 1
path: src/QueryReflection/QuerySimulation.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\ObjectType is error\\-prone and deprecated\\. Use Type\\:\\:isObject\\(\\) or Type\\:\\:getObjectClassNames\\(\\) instead\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\ObjectType is error\-prone and deprecated\. Use Type\:\:isObject\(\) or Type\:\:getObjectClassNames\(\) instead\.$#'
identifier: phpstanApi.instanceofType
count: 2
path: src/QueryReflection/QuerySimulation.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\Constant\\\\ConstantStringType is error\\-prone and deprecated\\. Use Type\\:\\:getConstantStrings\\(\\) instead\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\Constant\\ConstantStringType is error\-prone and deprecated\. Use Type\:\:getConstantStrings\(\) instead\.$#'
identifier: phpstanApi.instanceofType
count: 1
path: src/Rules/PdoStatementExecuteMethodRule.php

-
message: """
#^Call to deprecated method resolveQueryString\\(\\) of class staabm\\\\PHPStanDba\\\\QueryReflection\\\\QueryReflection\\:
use resolveQueryStrings\\(\\) instead$#
"""
message: '''
#^Call to deprecated method resolveQueryString\(\) of class staabm\\PHPStanDba\\QueryReflection\\QueryReflection\:
use resolveQueryStrings\(\) instead$#
'''
identifier: method.deprecated
count: 1
path: src/Rules/SyntaxErrorInDibiPreparedStatementMethodRule.php

-
message: "#^Doing instanceof PHPStan\\\\Type\\\\Constant\\\\ConstantArrayType is error\\-prone and deprecated\\. Use Type\\:\\:getConstantArrays\\(\\) instead\\.$#"
message: '#^Doing instanceof PHPStan\\Type\\Constant\\ConstantArrayType is error\-prone and deprecated\. Use Type\:\:getConstantArrays\(\) instead\.$#'
identifier: phpstanApi.instanceofType
count: 1
path: src/Rules/SyntaxErrorInDibiPreparedStatementMethodRule.php

-
message: "#^Only booleans are allowed in an if condition, int given\\.$#"
message: '#^Cannot call method getCondition\(\) on mixed\.$#'
identifier: method.nonObject
count: 2
path: src/SqlAst/ParserInference.php

-
message: '#^Cannot call method getLeft\(\) on mixed\.$#'
identifier: method.nonObject
count: 4
path: src/SqlAst/ParserInference.php

-
message: '#^Cannot call method getName\(\) on mixed\.$#'
identifier: method.nonObject
count: 1
path: src/SqlAst/ParserInference.php

-
message: '#^Cannot call method getRight\(\) on mixed\.$#'
identifier: method.nonObject
count: 2
path: src/SqlAst/ParserInference.php

-
message: '#^Cannot call method getTable\(\) on mixed\.$#'
identifier: method.nonObject
count: 1
path: src/SqlAst/ParserInference.php

-
message: '#^Parameter \#1 \$tableName of method staabm\\PHPStanDba\\SchemaReflection\\SchemaReflection\:\:getTable\(\) expects string, mixed given\.$#'
identifier: argument.type
count: 1
path: src/SqlAst/ParserInference.php

-
message: '#^Parameter \#3 \$joinCondition of class staabm\\PHPStanDba\\SchemaReflection\\Join constructor expects SqlFtw\\Sql\\Expression\\RootNode, mixed given\.$#'
identifier: argument.type
count: 1
path: src/SqlAst/ParserInference.php

-
message: '#^Only booleans are allowed in an if condition, int given\.$#'
identifier: if.condNotBoolean
count: 1
path: src/TypeMapping/MysqliTypeMapper.php

0 comments on commit 3379930

Please sign in to comment.