-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for PHP 8.4 #160
Comments
GH-163 verifies support for PHP 8.4. No changes were needed. |
@amotl can you please make a new up-to-date release? the last is from 2023. thanks! |
crate-pdo 2.2.1 has been released. Can you check if this works well for you, @michabbb? |
i was forced to make these changes to avoid some deprecation warnings: #164 |
Thanks a stack for your support! 💯 |
i tested your version 2.2.1, with php 8.4.3 i´m getting these warnings: Deprecated: Crate\PDO\PDOStatementImplementationPhp8::fetchAll(): Implicitly marking parameter $mode as nullable is deprecated, the explicit nullable type must be used instead in /app/vendor/crate/crate-pdo/src/Crate/PDO/PDOStatementImplementationPhp8.php on line 54
Deprecated: Return type of Crate\PDO\PDOStatementImplementation::setFetchMode(int $mode, ...$args) should either be compatible with PDOStatement::setFetchMode(int $mode, mixed ...$args): true, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /app/vendor/crate/crate-pdo/src/Crate/PDO/PDOStatementImplementationPhp8.php on line 40 that´s why I made that changes on my side 🤷 |
Thanks for your report. I am observing more deprecation warnings, yet the software tests succeed, so I thought we can address them on subsequent iterations. Are those deprecation warnings causing more serious downstream issues, so that crate-pdo version 2.2.1 is effectively useless? php -v
PHP 8.4.3 (cli) (built: Jan 15 2025 01:03:17) (NTS)
Copyright (c) The PHP Group
Built by Homebrew
Zend Engine v4.4.3, Copyright (c) Zend Technologies
with Zend OPcache v8.4.3, Copyright (c), by Zend Technologies composer run test Deprecated: Crate\PDO\Exception\UnsupportedException::__construct(): Implicitly marking parameter $previous as nullable is deprecated, the explicit nullable type must be used instead in /Users/amo/dev/crate/drivers/crate-pdo/src/Crate/PDO/Exception/UnsupportedException.php on line 31
Deprecated: Crate\PDO\Http\ServerPool::__construct(): Implicitly marking parameter $client as nullable is deprecated, the explicit nullable type must be used instead in /Users/amo/dev/crate/drivers/crate-pdo/src/Crate/PDO/Http/ServerPool.php on line 75
Deprecated: The API interface `Crate\PDO\PDO` is deprecated and will be removed on one of the upcoming releases. Please use `Crate\PDO\PDOCrateDB` instead. in /Users/amo/dev/crate/drivers/crate-pdo/src/Crate/PDO/PDO.php on line 37
Deprecated: Crate\PDO\Exception\InvalidArgumentException::__construct(): Implicitly marking parameter $previous as nullable is deprecated, the explicit nullable type must be used instead in /Users/amo/dev/crate/drivers/crate-pdo/src/Crate/PDO/Exception/InvalidArgumentException.php on line 29 |
I wouldn't say useless, but for someone who is somewhat perfectionistic and doesn't want to do things halfway while wanting to use PHP 8.4, there's no way around adjusting a few things. I don't care if some changes don't fit somewhere between 8.0 and 8.4 because I'm only working with >=8.4 here – you, as the maintainer, of course, have the need to keep things compatible with older PHP 8 versions, which I understand and appreciate 😏 |
und btw... servus aus bayern nach bayern 😊 🍻 |
I am just trying to find out if those warnings have been hard errors for you, or if it's merely about a cosmetic issue. |
crate-pdo 2.2.2 has been released, including your improvements. Can you check if this works better for you now, @michabbb? |
i am working with laravel, so seeing these ugly notices all the time, pardon, that makes me crazy 🙈 |
yep, works.. no more deprecation warnings 👍 🥳 |
Excellent, thanks.
How do you handle this situation? Do you also need an updated Doctrine/DBAL driver? NB: Please add your comments over there when applicable. |
i am using laravel $connection = app(CrateDB::class)->createConnection();
$stmt = $connection->query('SELECT id FROM something LIMIT 3');
$rows = $stmt->doFetchAll(PDO::FETCH_ASSOC); and everything is working fine 🤷 😏 |
Thank you very much. I think it is safe to close the issue. |
About
PHP 8.4 has been released today.
The text was updated successfully, but these errors were encountered: