Closed inmanturbo closed 3 years ago
Hi @inmanturbo,
First of all thanks a lot for your sponsorship, I greatly appreciate it. Regarding the composer.json changes, Unfortunately in my experience upgrading to DBAL 3.1 leads to problems with the PDOSqlite driver with the error Error: Class 'Doctrine\DBAL\Driver\PDOSqlite\Driver'
. Additionally, wouldn't it be misleading to new users of the package to add php 8.0 in the composer file while the package simply does not run on that version of php? I've tried installing it but so many of its dependecies which support php 8 are still in dev phase that I put it off for the moment. What do you think?
Cheers, Edward
DBAL was the only dependency I needed to update in order to get it working for me, currently using my fork in a project and haven't encountered any errors yet. It is still early though, maybe we can leave it open for a bit and see if we get any other feedback? If I get time tomorrow maybe I'll help set up a workflow for testing different versions of php.
Also could you please give a list of dependencies that aren't working with php 8 and any errors that you've encountered when attempting to install? I may reach out to them as well and see if I'm able to help them get up to speed.
Oh and you are most welcome! I like what you are doing here, and the dev community could definitely use more people coming over from professional backgrounds. It can be very helpful. This project is a perfect example as to how and why.
I suppose I will try some more things with sqlite as well. It looks like that is what you are using by default in phpunit, which is what I usually do myself. I'll run through the tests with a few different version tags on DBAL 3, see if I can encounter the error, and check if it has been patched since.
@ekmungai please review again when you get a chance, after updated a couple of the dev dependecies I can confirm that all test are successful with php 8:
➜ IFRS git:(master) ✗ ./vendor/bin/phpunit PHPUnit 9.4.3 by Sebastian Bergmann and contributors.
Runtime: PHP 8.0.8 Configuration: phpunit.xml
............................................................... 63 / 193 ( 32%) ............................................................... 126 / 193 ( 65%) ............................................................... 189 / 193 ( 97%) . White-Ratke Balance Sheet For the Period: Jan 01 2021 to Dec 31 2021
Total Assets 432
Total Liabilities 232
. Gerlach, Corwin and Nolan Cash Flow Statement For the Period: Jul 04 2021 to Aug 05 2021
Total Operations Cash Flow 630
Total Investment Cash Flow -150
Total Financing Cash Flow 200
---------------
. Nikolaus PLC Income Statement For the Period: Jan 01 2021 to Dec 31 2021
Operating Revenues Operating Revenue 245
Gross Profit 145
Total Revenue 350
. 193 / 193 (100%)
Time: 00:36.796, Memory: 54.00 MB
OK (193 tests, 1062 assertions)
➜ IFRS git:(main) ✗ php --version
PHP 8.0.8 (cli) (built: Jul 1 2021 15:27:21) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.8, Copyright (c) Zend Technologies
with Zend OPcache v8.0.8, Copyright (c), by Zend Technologies
➜ IFRS git:(main) ✗
I am going to squash these commits to clean up the history a bit, then re-submit this with a new composer.lock file.
These upgrades won't break anything, and will remain backwards compatible so long as we don't start using new php 8 language features.