From a66e384255736806c28f85165afc1dde1c32f0df Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Mon, 19 Jun 2023 16:24:33 +0200 Subject: [PATCH 01/12] workflows: Add phpstan --- .github/workflows/php.yml | 4 ++++ phpstan.neon | 20 ++++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 phpstan.neon diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index ead436c..43214a7 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -41,6 +41,10 @@ jobs: if: success() || matrix.allow_failure run: phpcs -wps --colors + - name: PHPStan + uses: php-actions/phpstan@v3 + if: success() || matrix.allow_failure + test: name: Unit tests with php ${{ matrix.php }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} diff --git a/phpstan.neon b/phpstan.neon new file mode 100644 index 0000000..ef6f183 --- /dev/null +++ b/phpstan.neon @@ -0,0 +1,20 @@ +parameters: + level: 5 # Use 'max' instead when we got the time to fix all the claims + + treatPhpDocTypesAsCertain: false # ignore phpDoc failure for now, remove it later + + paths: + - src + + scanDirectories: + - vendor + + universalObjectCratesClasses: # to ignore magic property errors + - ipl\Sql\Config + + ignoreErrors: + - '#Call to an undefined method ipl\\Sql\\Connection::exec\(\)#' + - '#Call to an undefined method ipl\\Sql\\Connection::query\(\)#' + - '#Call to an undefined method ipl\\Sql\\Connection::quote\(\)#' + + - "#Strict comparison using === between 'AND'|'OR' and 'OR NOT' will always evaluate to false´#" From d0451646a61395fe0cff3c3752b3308c500d9c35 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 13:53:19 +0200 Subject: [PATCH 02/12] Fix property type hints --- src/Connection.php | 2 +- src/OrderBy.php | 2 +- src/Select.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Connection.php b/src/Connection.php index bfc3f70..de84c72 100644 --- a/src/Connection.php +++ b/src/Connection.php @@ -21,7 +21,7 @@ class Connection implements Quoter /** @var Config */ protected $config; - /** @var PDO */ + /** @var ?PDO */ protected $pdo; /** @var QueryBuilder */ diff --git a/src/OrderBy.php b/src/OrderBy.php index 0721ad5..a19d7c5 100644 --- a/src/OrderBy.php +++ b/src/OrderBy.php @@ -7,7 +7,7 @@ */ trait OrderBy { - /** @var array ORDER BY part of the query */ + /** @var ?array ORDER BY part of the query */ protected $orderBy; public function hasOrderBy() diff --git a/src/Select.php b/src/Select.php index 77a50ee..f56a131 100644 --- a/src/Select.php +++ b/src/Select.php @@ -29,7 +29,7 @@ class Select implements CommonTableExpressionInterface, LimitOffsetInterface, Or * ... * ] * - * @var array + * @var ?array */ protected $join; @@ -47,7 +47,7 @@ class Select implements CommonTableExpressionInterface, LimitOffsetInterface, Or * ... * ] * - * @var array + * @var ?array */ protected $union; From 110e181f725a5961d2203d99d052fc66d4e69a0b Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 13:56:16 +0200 Subject: [PATCH 03/12] QueryBuilder: Remove dead code --- src/QueryBuilder.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/QueryBuilder.php b/src/QueryBuilder.php index 51a44c4..04d61c4 100644 --- a/src/QueryBuilder.php +++ b/src/QueryBuilder.php @@ -587,10 +587,6 @@ public function buildSelect(array $columns, $distinct, array &$values) $select .= ' DISTINCT'; } - if (empty($columns)) { - return "$select *"; - } - $sql = []; foreach ($columns as $alias => $column) { From 23b71a11f7bd4fd0bfb1a467012c113065b619bd Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:05:29 +0200 Subject: [PATCH 04/12] QueryBuilder: Explicitly declare `$tableName` --- src/QueryBuilder.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/QueryBuilder.php b/src/QueryBuilder.php index 04d61c4..07b5e3e 100644 --- a/src/QueryBuilder.php +++ b/src/QueryBuilder.php @@ -656,6 +656,7 @@ public function buildJoin($joins, array &$values) list($joinType, $table, $condition) = $join; if (is_array($table)) { + $tableName = null; foreach ($table as $alias => $tableName) { break; } From 9ca01520c3c484d882c2875e40a08b00d8d5eab4 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:06:34 +0200 Subject: [PATCH 05/12] Expression: Add missing return statement --- src/Expression.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Expression.php b/src/Expression.php index cd508ac..83c10bd 100644 --- a/src/Expression.php +++ b/src/Expression.php @@ -43,6 +43,8 @@ public function getColumns() public function setColumns(array $columns) { $this->columns = $columns; + + return $this; } public function getValues() From c615907aaadea5a086bbf5cf752846be5cf37355 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:12:46 +0200 Subject: [PATCH 06/12] FilterProcessor: Fix `Uneqaul` referenced with incorrect case --- src/Compat/FilterProcessor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Compat/FilterProcessor.php b/src/Compat/FilterProcessor.php index 3f4c1c7..6835e25 100644 --- a/src/Compat/FilterProcessor.php +++ b/src/Compat/FilterProcessor.php @@ -76,7 +76,7 @@ public static function assemblePredicate(Filter\Condition $filter) } } - if ($filter instanceof Filter\UnEqual || $filter instanceof NotIn) { + if ($filter instanceof Filter\Unequal || $filter instanceof NotIn) { return [sprintf($nullVerification ? '(%s NOT IN (?) OR %1$s IS NULL)' : '%s NOT IN (?)', $column) => $expression]; From f3c79544f4c133eb5b1ce5752f18ebfcc82fe18c Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:19:16 +0200 Subject: [PATCH 07/12] Mssql: Add missing return statement --- src/Adapter/Mssql.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Adapter/Mssql.php b/src/Adapter/Mssql.php index 2bad7b1..c9f11ce 100644 --- a/src/Adapter/Mssql.php +++ b/src/Adapter/Mssql.php @@ -74,5 +74,7 @@ public function registerQueryBuilderCallbacks(QueryBuilder $queryBuilder) $select->orderBy(1); } }); + + return $this; } } From 57fee01e39a4ddda405868275e4fd3e29ecfea91 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:22:15 +0200 Subject: [PATCH 08/12] OrderByInterface: Fix argument type hint --- src/OrderByInterface.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/OrderByInterface.php b/src/OrderByInterface.php index 9cce3d0..0ee0dda 100644 --- a/src/OrderByInterface.php +++ b/src/OrderByInterface.php @@ -33,10 +33,10 @@ public function getOrderBy(); * If you are using special field names, e.g. reserved keywords for your DBMS, you are required to use * {@link Connection::quoteIdentifier()} as well. * - * @param string|array $orderBy The ORDER BY part. The items can be in any format of the following: - * ['column', 'column' => 'DESC', 'column' => SORT_DESC, ['column', 'DESC']] - * @param string|int $direction The default direction. Can be any of the following: - * 'ASC', 'DESC', SORT_ASC, SORT_DESC + * @param string|int|array $orderBy The ORDER BY part. The items can be in any format of the following: + * ['column', 'column' => 'DESC', 'column' => SORT_DESC, ['column', 'DESC']] + * @param string|int $direction The default direction. Can be any of the following: + * 'ASC', 'DESC', SORT_ASC, SORT_DESC * * @return $this */ From bd4a34466f0e129edb2e98fdc6aa4d3e5ad14737 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Fri, 18 Aug 2023 14:23:25 +0200 Subject: [PATCH 09/12] BaseAdapter: Add missing return statement --- src/Adapter/BaseAdapter.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Adapter/BaseAdapter.php b/src/Adapter/BaseAdapter.php index 97bfca4..f062f63 100644 --- a/src/Adapter/BaseAdapter.php +++ b/src/Adapter/BaseAdapter.php @@ -61,6 +61,7 @@ public function getOptions(Config $config) public function setClientTimezone(Connection $db) { + return $this; } public function quoteIdentifier($identifiers) @@ -100,6 +101,8 @@ public function registerQueryBuilderCallbacks(QueryBuilder $queryBuilder) } } }); + + return $this; } protected function getTimezoneOffset() From 210769904cd835fdf7fd5c1e695f3243af9df68c Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Wed, 23 Aug 2023 10:08:17 +0200 Subject: [PATCH 10/12] Override all `Filter\Condition` methods & properties --- phpstan.neon | 2 ++ src/Filter/In.php | 12 ++++++- src/Filter/InAndNotInUtils.php | 62 ++++++++++++++++++++++++++++++++++ src/Filter/NotIn.php | 12 ++++++- 4 files changed, 86 insertions(+), 2 deletions(-) create mode 100644 src/Filter/InAndNotInUtils.php diff --git a/phpstan.neon b/phpstan.neon index ef6f183..63e1d14 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -18,3 +18,5 @@ parameters: - '#Call to an undefined method ipl\\Sql\\Connection::quote\(\)#' - "#Strict comparison using === between 'AND'|'OR' and 'OR NOT' will always evaluate to false´#" + + - '#Method .*\\(In|NotIn)::getValue\(\) should return ipl\\Sql\\Select but returns mixed.$#' diff --git a/src/Filter/In.php b/src/Filter/In.php index a5c29ca..c126af6 100644 --- a/src/Filter/In.php +++ b/src/Filter/In.php @@ -7,8 +7,18 @@ class In extends Filter\Condition { + use InAndNotInUtils; + + /** + * Create a new sql IN condition + * + * @param string[]|string $column + * @param Select $select + */ public function __construct($column, Select $select) { - parent::__construct($column, $select); + $this + ->setColumn($column) + ->setValue($select); } } diff --git a/src/Filter/InAndNotInUtils.php b/src/Filter/InAndNotInUtils.php new file mode 100644 index 0000000..6f26de1 --- /dev/null +++ b/src/Filter/InAndNotInUtils.php @@ -0,0 +1,62 @@ +column; + } + + /** + * Set the columns of this condition + * + * @param string[]|string $column + * + * @return $this + */ + public function setColumn($column): self + { + $this->column = $column; + + return $this; + } + + /** + * Get the value of this condition + * + * @return Select + */ + public function getValue(): Select + { + return $this->value; + } + + /** + * Set the value of this condition + * + * @param Select $value + * + * @return $this + */ + public function setValue($value): self + { + $this->value = $value; + + return $this; + } +} diff --git a/src/Filter/NotIn.php b/src/Filter/NotIn.php index 28b3fed..cdf6241 100644 --- a/src/Filter/NotIn.php +++ b/src/Filter/NotIn.php @@ -7,8 +7,18 @@ class NotIn extends Filter\Condition { + use InAndNotInUtils; + + /** + * Create a new sql NOT IN condition + * + * @param string[]|string $column + * @param Select $select + */ public function __construct($column, Select $select) { - parent::__construct($column, $select); + $this + ->setColumn($column) + ->setValue($select); } } From cacaaaeaf37b2088b5da5e5da0af2aa7e58d3eaf Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Tue, 22 Aug 2023 16:07:52 +0200 Subject: [PATCH 11/12] Add phpstan `baseline` config --- phpstan-baseline.neon | 1186 +++++++++++++++++++++++++++++++++++++++++ phpstan.neon | 11 +- 2 files changed, 1193 insertions(+), 4 deletions(-) create mode 100644 phpstan-baseline.neon diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon new file mode 100644 index 0000000..5107fd0 --- /dev/null +++ b/phpstan-baseline.neon @@ -0,0 +1,1186 @@ +parameters: + ignoreErrors: + - + message: "#^Argument of an invalid type array\\|null supplied for foreach, only iterables are supported\\.$#" + count: 1 + path: src/Adapter/BaseAdapter.php + + - + message: "#^Method ipl\\\\Sql\\\\Adapter\\\\BaseAdapter\\:\\:getOptions\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/BaseAdapter.php + + - + message: "#^Method ipl\\\\Sql\\\\Adapter\\\\BaseAdapter\\:\\:getTimezoneOffset\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Adapter/BaseAdapter.php + + - + message: "#^Property ipl\\\\Sql\\\\Adapter\\\\BaseAdapter\\:\\:\\$options type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/BaseAdapter.php + + - + message: "#^Property ipl\\\\Sql\\\\Adapter\\\\BaseAdapter\\:\\:\\$quoteCharacter type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/BaseAdapter.php + + - + message: "#^Property ipl\\\\Sql\\\\Adapter\\\\Mssql\\:\\:\\$quoteCharacter type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/Mssql.php + + - + message: "#^Method ipl\\\\Sql\\\\Adapter\\\\Mysql\\:\\:getOptions\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/Mysql.php + + - + message: "#^Property ipl\\\\Sql\\\\Adapter\\\\Mysql\\:\\:\\$quoteCharacter type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Adapter/Mysql.php + + - + message: "#^Method ipl\\\\Sql\\\\CommonTableExpressionInterface\\:\\:getWith\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/CommonTableExpressionInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\Compat\\\\FilterProcessor\\:\\:assembleFilter\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Compat/FilterProcessor.php + + - + message: "#^Method ipl\\\\Sql\\\\Compat\\\\FilterProcessor\\:\\:assembleFilter\\(\\) has parameter \\$level with no type specified\\.$#" + count: 1 + path: src/Compat/FilterProcessor.php + + - + message: "#^Method ipl\\\\Sql\\\\Compat\\\\FilterProcessor\\:\\:assemblePredicate\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Compat/FilterProcessor.php + + - + message: "#^Parameter \\#1 \\$haystack of function strpos expects string, mixed given\\.$#" + count: 1 + path: src/Compat/FilterProcessor.php + + - + message: "#^Parameter \\#3 \\$subject of function str_replace expects array\\|string, mixed given\\.$#" + count: 2 + path: src/Compat/FilterProcessor.php + + - + message: "#^Strict comparison using \\=\\=\\= between 'AND'\\|'OR' and 'OR NOT' will always evaluate to false\\.$#" + count: 1 + path: src/Compat/FilterProcessor.php + + - + message: "#^Method ipl\\\\Sql\\\\Config\\:\\:__construct\\(\\) has parameter \\$config with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Config.php + + - + message: "#^Method ipl\\\\Sql\\\\Config\\:\\:__get\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Config.php + + - + message: "#^Method ipl\\\\Sql\\\\Config\\:\\:__set\\(\\) has parameter \\$value with no type specified\\.$#" + count: 1 + path: src/Config.php + + - + message: "#^Property ipl\\\\Sql\\\\Config\\:\\:\\$extraSettings type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Config.php + + - + message: "#^Property ipl\\\\Sql\\\\Config\\:\\:\\$options type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Config.php + + - + message: "#^Cannot call method beginTransaction\\(\\) on PDO\\|null\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Cannot call method commit\\(\\) on PDO\\|null\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Cannot call method prepare\\(\\) on PDO\\|null\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Cannot call method rollBack\\(\\) on PDO\\|null\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:__call\\(\\) has parameter \\$arguments with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:__construct\\(\\) has parameter \\$config with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:delete\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchAll\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchAll\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchCol\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchCol\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchOne\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchOne\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchOne\\(\\) should return array but returns mixed\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchPairs\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchPairs\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchRow\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchRow\\(\\) has parameter \\$stmt with no type specified\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchRow\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchScalar\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:fetchScalar\\(\\) should return string but returns int\\|string\\|false\\|null\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:init\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:insert\\(\\) has parameter \\$data with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:prepexec\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:update\\(\\) has parameter \\$data with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:update\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:yieldCol\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Connection\\:\\:yieldPairs\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#1 \\$callback of function call_user_func_array expects callable\\(\\)\\: mixed, array\\{PDO\\|null, string\\} given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#1 \\$condition of method ipl\\\\Sql\\\\Delete\\:\\:where\\(\\) expects array\\|ipl\\\\Sql\\\\ExpressionInterface\\|ipl\\\\Sql\\\\Select\\|string, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#1 \\$condition of method ipl\\\\Sql\\\\Update\\:\\:where\\(\\) expects array\\|ipl\\\\Sql\\\\ExpressionInterface\\|ipl\\\\Sql\\\\Select\\|string, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#1 \\$mode of method PDOStatement\\:\\:setFetchMode\\(\\) expects int, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#1 \\$object_or_class of function method_exists expects object\\|string, PDO\\|null given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#2 \\$className of method PDOStatement\\:\\:setFetchMode\\(\\) expects int\\|object\\|string, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#2 \\$values of method ipl\\\\Sql\\\\Connection\\:\\:prepexec\\(\\) expects array\\|string\\|null, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Parameter \\#2 \\$values of method ipl\\\\Sql\\\\Connection\\:\\:yieldPairs\\(\\) expects array\\|null, mixed given\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Property ipl\\\\Sql\\\\Connection\\:\\:\\$adapter \\(ipl\\\\Sql\\\\Contract\\\\Adapter\\) does not accept object\\.$#" + count: 1 + path: src/Connection.php + + - + message: "#^Method ipl\\\\Sql\\\\Contract\\\\Adapter\\:\\:getOptions\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Contract/Adapter.php + + - + message: "#^Class ipl\\\\Sql\\\\Cursor implements generic interface IteratorAggregate but does not specify its types\\: TKey, TValue$#" + count: 1 + path: src/Cursor.php + + - + message: "#^Method ipl\\\\Sql\\\\Cursor\\:\\:count\\(\\) should return int but returns int\\|string\\|false\\|null\\.$#" + count: 1 + path: src/Cursor.php + + - + message: "#^Method ipl\\\\Sql\\\\Cursor\\:\\:getFetchMode\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Cursor.php + + - + message: "#^Property ipl\\\\Sql\\\\Cursor\\:\\:\\$fetchModeAndArgs type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Cursor.php + + - + message: "#^Cannot access an offset on mixed\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Cannot access offset 0 on mixed\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Cannot access offset 1 on mixed\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Cannot cast mixed to string\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:buildCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:buildCondition\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:cloneCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:cloneCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:cloneCte\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:cloneWhere\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:from\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:getFrom\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:getWhere\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:getWith\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:mergeCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:mergeCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:notWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:orNotWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:orWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:prepareConditionArguments\\(\\) has parameter \\$args with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:prepareConditionArguments\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Delete\\:\\:where\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Property ipl\\\\Sql\\\\Delete\\:\\:\\$from type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Property ipl\\\\Sql\\\\Delete\\:\\:\\$where type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Property ipl\\\\Sql\\\\Delete\\:\\:\\$with type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Delete.php + + - + message: "#^Method ipl\\\\Sql\\\\Expression\\:\\:__construct\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Method ipl\\\\Sql\\\\Expression\\:\\:getColumns\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Method ipl\\\\Sql\\\\Expression\\:\\:getValues\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Method ipl\\\\Sql\\\\Expression\\:\\:setColumns\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Property ipl\\\\Sql\\\\Expression\\:\\:\\$columns \\(array\\) does not accept array\\|null\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Property ipl\\\\Sql\\\\Expression\\:\\:\\$columns type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Property ipl\\\\Sql\\\\Expression\\:\\:\\$values type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Expression.php + + - + message: "#^Method ipl\\\\Sql\\\\ExpressionInterface\\:\\:getColumns\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/ExpressionInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\ExpressionInterface\\:\\:getValues\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/ExpressionInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\ExpressionInterface\\:\\:setColumns\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/ExpressionInterface.php + + - + message: "#^Property ipl\\\\Stdlib\\\\Filter\\\\Condition\\:\\:\\$column \\(string\\) does not accept array\\\\|string\\.$#" + count: 1 + path: src/Filter/In.php + + - + message: "#^Property ipl\\\\Stdlib\\\\Filter\\\\Condition\\:\\:\\$column \\(string\\) does not accept array\\\\|string\\.$#" + count: 1 + path: src/Filter/NotIn.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:cloneCte\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:columns\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:getColumns\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:getValues\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:getWith\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\Insert\\:\\:values\\(\\) has parameter \\$values with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Property ipl\\\\Sql\\\\Insert\\:\\:\\$columns type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Property ipl\\\\Sql\\\\Insert\\:\\:\\$values type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Property ipl\\\\Sql\\\\Insert\\:\\:\\$with type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Insert.php + + - + message: "#^Method ipl\\\\Sql\\\\OrderByInterface\\:\\:getOrderBy\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/OrderByInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\OrderByInterface\\:\\:orderBy\\(\\) has parameter \\$orderBy with no value type specified in iterable type array\\.$#" + count: 1 + path: src/OrderByInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assemble\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assembleDelete\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assembleInsert\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assembleSelect\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assembleSelect\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:assembleUpdate\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildCondition\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildDeleteFrom\\(\\) has parameter \\$from with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildExpression\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildFrom\\(\\) has parameter \\$from with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildFrom\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildGroupBy\\(\\) has parameter \\$groupBy with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildGroupBy\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildHaving\\(\\) has parameter \\$having with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildHaving\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildInsertColumnsAndValues\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildInsertColumnsAndValues\\(\\) has parameter \\$insertValues with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildInsertColumnsAndValues\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildInsertIntoSelect\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildInsertIntoSelect\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildJoin\\(\\) has parameter \\$joins with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildJoin\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildOrderBy\\(\\) has parameter \\$orderBy with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildOrderBy\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildSelect\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildSelect\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUnions\\(\\) has parameter \\$unions with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUnions\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUnions\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUpdateSet\\(\\) has parameter \\$set with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUpdateSet\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildUpdateTable\\(\\) has parameter \\$updateTable with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildWhere\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildWhere\\(\\) has parameter \\$where with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildWith\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildWith\\(\\) has parameter \\$with with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:unpackCondition\\(\\) has parameter \\$values with no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Method ipl\\\\Sql\\\\QueryBuilder\\:\\:unpackCondition\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Parameter \\#1 \\$joins of method ipl\\\\Sql\\\\QueryBuilder\\:\\:buildJoin\\(\\) expects array, array\\|null given\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Property ipl\\\\Sql\\\\QueryBuilder\\:\\:\\$separator has no type specified\\.$#" + count: 1 + path: src/QueryBuilder.php + + - + message: "#^Cannot access an offset on mixed\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Cannot access offset 0 on mixed\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Cannot access offset 1 on mixed\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Cannot cast mixed to string\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:buildCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:buildCondition\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:cloneCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:cloneCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:cloneCte\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:cloneOrderBy\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:cloneWhere\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:columns\\(\\) has parameter \\$columns with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:from\\(\\) has parameter \\$tables with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getColumns\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getFrom\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getGroupBy\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getHaving\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getJoin\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getOrderBy\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getUnion\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getWhere\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:getWith\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:groupBy\\(\\) has parameter \\$groupBy with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:having\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:join\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:join\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:joinLeft\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:joinLeft\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:joinRight\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:joinRight\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:mergeCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:mergeCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:notHaving\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:notWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:orHaving\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:orNotHaving\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:orNotWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:orWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:orderBy\\(\\) has parameter \\$orderBy with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:prepareConditionArguments\\(\\) has parameter \\$args with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:prepareConditionArguments\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Method ipl\\\\Sql\\\\Select\\:\\:where\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Parameter \\#1 \\$condition of method ipl\\\\Sql\\\\Select\\:\\:buildCondition\\(\\) expects array\\|string, array\\|ipl\\\\Sql\\\\ExpressionInterface\\|ipl\\\\Sql\\\\Select\\|string given\\.$#" + count: 7 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$columns type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$from type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$groupBy type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$having type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$join type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$orderBy type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$union type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$where type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Property ipl\\\\Sql\\\\Select\\:\\:\\$with type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Select.php + + - + message: "#^Argument of an invalid type array\\|null supplied for foreach, only iterables are supported\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Cannot access an offset on mixed\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Cannot access offset 0 on mixed\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Cannot access offset 1 on mixed\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Cannot cast mixed to string\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:buildCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:buildCondition\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:cloneCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:cloneCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:cloneCte\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:cloneWhere\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:getSet\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:getTable\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:getWhere\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:getWith\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:mergeCondition\\(\\) has no return type specified\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:mergeCondition\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:notWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:orNotWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:orWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:prepareConditionArguments\\(\\) has parameter \\$args with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:prepareConditionArguments\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:set\\(\\) has parameter \\$set with no value type specified in iterable type iterable\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:table\\(\\) has parameter \\$table with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\Update\\:\\:where\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Property ipl\\\\Sql\\\\Update\\:\\:\\$set type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Property ipl\\\\Sql\\\\Update\\:\\:\\$table type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Property ipl\\\\Sql\\\\Update\\:\\:\\$where type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Property ipl\\\\Sql\\\\Update\\:\\:\\$with type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/Update.php + + - + message: "#^Method ipl\\\\Sql\\\\WhereInterface\\:\\:getWhere\\(\\) return type has no value type specified in iterable type array\\.$#" + count: 1 + path: src/WhereInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\WhereInterface\\:\\:notWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/WhereInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\WhereInterface\\:\\:orNotWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/WhereInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\WhereInterface\\:\\:orWhere\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/WhereInterface.php + + - + message: "#^Method ipl\\\\Sql\\\\WhereInterface\\:\\:where\\(\\) has parameter \\$condition with no value type specified in iterable type array\\.$#" + count: 1 + path: src/WhereInterface.php diff --git a/phpstan.neon b/phpstan.neon index 63e1d14..2f3f28f 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,7 +1,12 @@ +includes: + - phpstan-baseline.neon + parameters: - level: 5 # Use 'max' instead when we got the time to fix all the claims + level: max - treatPhpDocTypesAsCertain: false # ignore phpDoc failure for now, remove it later + checkFunctionNameCase: true + checkInternalClassCaseSensitivity: true + treatPhpDocTypesAsCertain: false paths: - src @@ -17,6 +22,4 @@ parameters: - '#Call to an undefined method ipl\\Sql\\Connection::query\(\)#' - '#Call to an undefined method ipl\\Sql\\Connection::quote\(\)#' - - "#Strict comparison using === between 'AND'|'OR' and 'OR NOT' will always evaluate to false´#" - - '#Method .*\\(In|NotIn)::getValue\(\) should return ipl\\Sql\\Select but returns mixed.$#' From 56362f486d6ddc1f0bb893142ce35b251c900c04 Mon Sep 17 00:00:00 2001 From: Yonas Habteab Date: Wed, 23 Aug 2023 14:56:42 +0200 Subject: [PATCH 12/12] Add common ignore errors pattern to phpstan config --- phpstan.neon | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/phpstan.neon b/phpstan.neon index 2f3f28f..f58b54c 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -18,6 +18,12 @@ parameters: - ipl\Sql\Config ignoreErrors: + - + messages: + - '#Unsafe usage of new static\(\)#' + - '#. but return statement is missing#' + reportUnmatched: false + - '#Call to an undefined method ipl\\Sql\\Connection::exec\(\)#' - '#Call to an undefined method ipl\\Sql\\Connection::query\(\)#' - '#Call to an undefined method ipl\\Sql\\Connection::quote\(\)#'