Problem/Motivation
Supported Versions
Currently Supported Versions
https://www.php.net/supported-versions.php
Please, list any PHP 8.0 or PHP 8.1 issues in this issue
Test building and installing Varbase 9.0.x-dev and 9.1.0.x under PHP 8.0 / PHP 8.1 and MySQL 8
composer create-project vardot/varbase-project:9.0.x-dev PROJECT_DIR_NAME --stability dev --no-interaction
or
composer create-project vardot/varbase-project:9.1.x-dev PROJECT_DIR_NAME --stability dev --no-interaction
Proposed resolution
Have support for PHP 8.0 and PHP 8.1
Have support for MySQL 8
Add rule for PHP 8 promotion constructor in PSR-12
Remaining tasks
- ✅ File an issue about this project
- ✅ Addition/Change/Update/Fix to this project
- ✅ Testing to ensure no regression
- ✅ Automated unit/functional testing coverage
Varbase 9.1.x
Varbase 9.0.x
- ✅ Developer Documentation support on feature change/addition
- ➖ User Guide Documentation support on feature change/addition
- ✅ Update Release Notes and Update Helper on new feature change/addition
- ✅ Code review from 1 Varbase core team member
- ✅ Full testing and approval
- ✅ Credit contributors
- ✅ Review with the product owner
- ✅ Release varbase-9.0.6
Varbase update type:
- ✅ No Update
- ➖ Optional Update
- ➖ Forced Update
- ➖ Forced Update if Unchanged
User interface changes
- N/A
API changes
- N/A
Data model changes
- N/A
Release notes snippet
- Issue #3217859: Support PHP8.1 and MySQL 8 for Varbase ~9.0 and all used components with automated testing
| Comment | File | Size | Author |
|---|---|---|---|
| #73 | Screenshot 2022-04-26 at 12-07-11 PHP Supported Versions.png | 117.34 KB | rajab natshah |
| #68 | PHP-2022-03-07---Supported-Vrsions----Currently-Supported-Versions.png | 156.95 KB | rajab natshah |


Comments
Comment #2
rajab natshahComment #3
rajab natshahComment #4
rajab natshahComment #5
rajab natshahAt this point of time
On running the following composer command under PHP 8.0
Facing the following problem on Resolving dependencies with PHP 8.0
Comment #6
rajab natshahComment #7
rajab natshahComment #8
rajab natshahComment #9
mhawwari commentedPHP 7.4 is now under security support only
https://www.php.net/supported-versions.php
And the library abraham/twitteroauth now support PHP 8.1
Comment #10
rajab natshahThanks, Hawwari for following up
A full testing round for building and installing Varbase 9.0.x
composer create-project Vardot/varbase-project:9.0.x-dev PROJECT_DIR_NAME --no-dev --no-interactionand Varbase 9.1.0.x
composer create-project Vardot/varbase-project:9.1.x-dev PROJECT_DIR_NAME --no-dev --no-interactionPlus the automated functional testing
Changed that in my fork
https://github.com/Natshah/varbase/blob/9.0.x/.circleci/config.yml
With the automated testing running now .. on the 9.0.x branch
https://app.circleci.com/pipelines/github/Natshah/varbase/208/workflows/...
Comment #11
rajab natshahComment #12
rajab natshahComment #13
mhawwari commentedComment #14
rajab natshahComment #15
rajab natshahComment #16
rajab natshahComment #17
rajab natshahComment #18
rajab natshahComment #19
rajab natshahComment #20
rajab natshahComment #21
rajab natshahComment #22
rajab natshahComment #23
rajab natshahComment #24
rajab natshahComment #25
rajab natshahComment #26
rajab natshahComment #27
rajab natshahComment #28
rajab natshahComment #29
rajab natshahComment #30
rajab natshahComment #31
rajab natshahAdd rule for PHP 8 promotion constructor in PSR-12
Comment #32
rajab natshahComment #33
rajab natshahComment #34
rajab natshahComment #35
rajab natshahComment #36
rajab natshahComment #37
rajab natshahComment #38
oliver huynh commentedComment #39
rajab natshahComment #40
rajab natshah#3261492: In php 8.1 the explode function throws a notice when default value is null
Comment #41
rajab natshah#3261487: In php 8.1 the explode function throws a notice when default value is null
Comment #42
rajab natshahComment #43
rajab natshahComment #44
rajab natshahComment #45
rajab natshahComment #46
rajab natshahComment #47
rajab natshahComment #48
rajab natshahComment #49
rajab natshahComment #50
rajab natshahComment #51
rajab natshahComment #52
rajab natshahComment #53
rajab natshahComment #54
rajab natshahComment #55
rajab natshahTEMP fix for #3253991: Update abraham/twitteroauth to use ^3.0 to support PHP8.0 and later
Add the following in the root composer.json for projects:
"abraham/twitteroauth": "3.3.0 as 1.2.0",To test building Varbase 9.0.x under PHP 8.0 or PHP 8.1
Comment #56
rajab natshahSocial Aauth Twitter 8.x-2.0-alpha4 was released 22 Feb 2022 by: Abdullah Yassin
Comment #57
rajab natshah#3265826: Update Social Aauth Twitter module from 2.x-dev to ~2.0 and remove committed patches
Comment #58
rajab natshahComment #59
rajab natshahNow remove
"abraham/twitteroauth": "3.3.0 as 1.2.0",from the root composer.json in projects under PHP 8.0Then update Varbase Auth to 9.0.2
Comment #60
rajab natshahComment #63
rajab natshah✅ Automated unit/functional testing coverage
Varbase 9.1.x
Varbase 9.0.x
A small number of warnings, after a full round of testing under PHP 8.0 and PHP 8.1
The Functional Automated Acceptance Testing is passing with Green builds.
Having one more round of testing, and fixes to ensure no warnings, notices, or fatal errors.
Comment #64
rajab natshahComment #65
rajab natshah#3266406: PHP 8.1 error with Views integration: Argument #1 ($first_row_tokens) must be of type array, null given
Comment #66
rajab natshahInline Entity Form 8.x-1.0-rc10 was released 3 Mar 2022 by geek-merlin
https://www.drupal.org/project/inline_entity_form/releases/8.x-1.0-rc10
#3217493: PHP 8 incompatibility on call_user_func_array()
Comment #67
rajab natshahBlazy 8.x-2.8 was released 6 Mar 2022 by: gausarts
https://www.drupal.org/project/blazy/releases/8.x-2.8
#3265909: Warning with PHP 8.1: Deprecated function: trim()
Comment #68
rajab natshah#3268094: PHP 8.1 deprecated functions + General fix
Comment #69
rajab natshahCommitted, but not released yet.
#3265567: PHP8 undefined array key "description"
Comment #70
rajab natshah#3266417: PHP 8.1 error with Metatag Trimming Options: Argument #3 ($offset) must be contained in argument #1 ($haystack) in strpos()
Comment #71
rajab natshahClosing this issue
Farther PHP 8.0 or PHP 8.1 issues could be reported to be fixed on used cases.
✅ Automated unit/functional testing coverage
Varbase 9.1.x
Varbase 9.0.x
A small number of warnings, after a full round of testing under PHP 8.0 and PHP 8.1
The Functional Automated Acceptance Testing is passing with Green builds.
Having one more round of testing, and fixes to ensure no warnings, notices, or fatal errors.
Comment #73
rajab natshahComment #74
rajab natshah✅ Released varbase-9.0.6
Comment #75
rajab natshahComment #76
rajab natshah✅ Developer Documentation support on feature change/addition
Requirements
PHP 7.4 or higher. PHP 8.0 is recommended.
Comment #77
rajab natshahComment #78
rajab natshahComment #79
rajab natshah✅ Developer Documentation support on feature change/addition
Requirements
PHP 7.4 or higher. PHP 8.0 is recommended.
Varbase Project Template for Platform.sh
The runtime the application uses
type: 'php:8.0'Varbase Project Template for Lando
Lando PHP config
php: '8.0'Comment #80
paskainos commentedFresh install of Varbase 9.0.6 on PHP 8.1.5 with Varbase Style guide selected to be installed throws
Deprecated function: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in Drupal\styleguide\Theme\StyleguideThemeNegotiator->applies() (line 60 of ... ~/modules/contrib/styleguide/src/Theme/StyleguideThemeNegotiator.php)on 'welcome' (home) page, which is addressed in #3258816: Fix [PHP 8.1] Deprecated function: strpos(): Passing null to parameter #1.Comment #81
rajab natshahThank you Chris Hinkley (paskainos) for reporting :)
Fixed in #3277617: Fix Style Guide issue on [PHP 8.1] Deprecated function: strpos(): Passing null to parameter
Released Varbase Style Guide 9.0.4
https://www.drupal.org/project/varbase_styleguide/releases/9.0.3
Comment #82
rajab natshah#3272720: hash(): Passing null to parameter #2 ($data) of type string is deprecated in generateFieldTableName