Incomplete mysqli extension stubs #9851
Labels
easy problems
Issues that can be fixed without background knowledge of Psalm
enhancement
internal stubs/callmap
The current
mysqli
extension stubs contain only a handful of the classes and methods that the extension defines. Notable absences that have tripped up my project in CI environments that do not install themysqli
extension (e.g. while usingpsalm/psalm-github-actions
) include:class mysqli_sql_exception
const MYSQLI_ASSOC
const MYSQLI_USE_RESULT
const MYSQLI_REPORT_ERROR
const MYSQLI_REPORT_STRICT
const MYSQLI_OPT_CONNECT_TIMEOUT
While fixing these gaps, I think it would be worthwhile to fill in all of the missing constants defined by this extension. Looks like the
acpu
anddom
extensions both define globally-namespaced constants as well, although the stubs for those extensions use different syntax for defining them (define
vs.const
).If it's acceptable to copy stubs from
php/php-src
, we could go ahead and fill in all of themysqli
-defined class APIs and procedural function stubs based on https://github.com/php/php-src/blob/master/ext/mysqli/mysqli.stub.php as well, although I get the sense from other issues/PRs that thephp/php-src
stubs are not necessarily 100% accurate/current.The text was updated successfully, but these errors were encountered: