mirror of
https://github.com/nextcloud/server.git
synced 2026-06-11 01:30:50 -04:00
Merge pull request #49145 from nextcloud/ci/noid/php-8.4
feat(PHP): Allow PHP 8.4
This commit is contained in:
commit
78cf3129aa
18 changed files with 35 additions and 15 deletions
2
.github/workflows/files-external-ftp.yml
vendored
2
.github/workflows/files-external-ftp.yml
vendored
|
|
@ -43,7 +43,7 @@ jobs:
|
|||
# do not stop on another job's failure
|
||||
fail-fast: false
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.3']
|
||||
php-versions: ['8.1', '8.4']
|
||||
ftpd: ['proftpd', 'vsftpd', 'pure-ftpd']
|
||||
include:
|
||||
- php-versions: '8.1'
|
||||
|
|
|
|||
2
.github/workflows/files-external-s3.yml
vendored
2
.github/workflows/files-external-s3.yml
vendored
|
|
@ -41,7 +41,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.2', '8.3']
|
||||
php-versions: ['8.1', '8.2', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.2'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/files-external-sftp.yml
vendored
2
.github/workflows/files-external-sftp.yml
vendored
|
|
@ -43,7 +43,7 @@ jobs:
|
|||
# do not stop on another job's failure
|
||||
fail-fast: false
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.3']
|
||||
php-versions: ['8.1', '8.4']
|
||||
sftpd: ['openssh']
|
||||
include:
|
||||
- php-versions: '8.1'
|
||||
|
|
|
|||
2
.github/workflows/files-external-smb.yml
vendored
2
.github/workflows/files-external-smb.yml
vendored
|
|
@ -41,7 +41,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.3']
|
||||
php-versions: ['8.1']
|
||||
include:
|
||||
- php-versions: '8.1'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/files-external-webdav.yml
vendored
2
.github/workflows/files-external-webdav.yml
vendored
|
|
@ -41,7 +41,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.2', '8.3']
|
||||
php-versions: ['8.1', '8.2', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.2'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/files-external.yml
vendored
2
.github/workflows/files-external.yml
vendored
|
|
@ -40,7 +40,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.2', '8.3']
|
||||
php-versions: ['8.1', '8.2', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.2'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/lint-php.yml
vendored
2
.github/workflows/lint-php.yml
vendored
|
|
@ -47,7 +47,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: [ '8.1', '8.2', '8.3' ]
|
||||
php-versions: [ '8.1', '8.2', '8.3', '8.4' ]
|
||||
|
||||
name: php-lint
|
||||
|
||||
|
|
|
|||
2
.github/workflows/phpunit-mariadb.yml
vendored
2
.github/workflows/phpunit-mariadb.yml
vendored
|
|
@ -61,6 +61,8 @@ jobs:
|
|||
- php-versions: '8.3'
|
||||
mariadb-versions: '10.11'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
- php-versions: '8.4'
|
||||
mariadb-versions: '11.4'
|
||||
|
||||
name: MariaDB ${{ matrix.mariadb-versions }} (PHP ${{ matrix.php-versions }}) - database tests
|
||||
|
||||
|
|
|
|||
2
.github/workflows/phpunit-memcached.yml
vendored
2
.github/workflows/phpunit-memcached.yml
vendored
|
|
@ -55,7 +55,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.3']
|
||||
php-versions: ['8.1', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.2'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/phpunit-mysql.yml
vendored
2
.github/workflows/phpunit-mysql.yml
vendored
|
|
@ -61,6 +61,8 @@ jobs:
|
|||
- mysql-versions: '8.0'
|
||||
php-versions: '8.3'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
- mysql-versions: '8.4'
|
||||
php-versions: '8.4'
|
||||
|
||||
name: MySQL ${{ matrix.mysql-versions }} (PHP ${{ matrix.php-versions }}) - database tests
|
||||
|
||||
|
|
|
|||
2
.github/workflows/phpunit-nodb.yml
vendored
2
.github/workflows/phpunit-nodb.yml
vendored
|
|
@ -57,7 +57,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1', '8.3']
|
||||
php-versions: ['8.1', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.2'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
2
.github/workflows/phpunit-oci.yml
vendored
2
.github/workflows/phpunit-oci.yml
vendored
|
|
@ -66,6 +66,8 @@ jobs:
|
|||
php-versions: '8.2'
|
||||
- oracle-versions: '23'
|
||||
php-versions: '8.3'
|
||||
- oracle-versions: '23'
|
||||
php-versions: '8.4'
|
||||
|
||||
name: Oracle ${{ matrix.oracle-versions }} (PHP ${{ matrix.php-versions }}) - database tests
|
||||
|
||||
|
|
|
|||
2
.github/workflows/phpunit-pgsql.yml
vendored
2
.github/workflows/phpunit-pgsql.yml
vendored
|
|
@ -62,6 +62,8 @@ jobs:
|
|||
- php-versions: '8.3'
|
||||
postgres-versions: '16'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
- php-versions: '8.4'
|
||||
postgres-versions: '16'
|
||||
|
||||
name: PostgreSQL ${{ matrix.postgres-versions }} (PHP ${{ matrix.php-versions }}) - database tests
|
||||
|
||||
|
|
|
|||
2
.github/workflows/phpunit-sqlite.yml
vendored
2
.github/workflows/phpunit-sqlite.yml
vendored
|
|
@ -55,7 +55,7 @@ jobs:
|
|||
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.2', '8.3']
|
||||
php-versions: ['8.2', '8.3', '8.4']
|
||||
include:
|
||||
- php-versions: '8.1'
|
||||
coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,10 @@ class FileSearchBackendTest extends TestCase {
|
|||
private $davFolder;
|
||||
|
||||
protected function setUp(): void {
|
||||
if (PHP_VERSION_ID >= 80400) {
|
||||
$this->markTestSkipped('SearchDAV is not yet PHP 8.4 compatible');
|
||||
}
|
||||
|
||||
parent::setUp();
|
||||
|
||||
$this->user = $this->createMock(IUser::class);
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ class ExceptionSerializer {
|
|||
'validateUserPass',
|
||||
'loginWithToken',
|
||||
'{closure}',
|
||||
'{closure:*',
|
||||
'createSessionToken',
|
||||
|
||||
// Provisioning
|
||||
|
|
@ -200,7 +201,9 @@ class ExceptionSerializer {
|
|||
return $this->editTrace($sensitiveValues, $traceLine);
|
||||
}
|
||||
foreach (self::methodsWithSensitiveParameters as $sensitiveMethod) {
|
||||
if (str_contains($traceLine['function'], $sensitiveMethod)) {
|
||||
if (str_contains($traceLine['function'], $sensitiveMethod)
|
||||
|| (str_ends_with($sensitiveMethod, '*')
|
||||
&& str_starts_with($traceLine['function'], substr($sensitiveMethod, 0, -1)))) {
|
||||
return $this->editTrace($sensitiveValues, $traceLine);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -878,7 +878,12 @@ class OC_Util {
|
|||
* @return bool
|
||||
*/
|
||||
public static function isAnnotationsWorking() {
|
||||
$reflection = new \ReflectionMethod(__METHOD__);
|
||||
if (PHP_VERSION_ID >= 80300) {
|
||||
/** @psalm-suppress UndefinedMethod */
|
||||
$reflection = \ReflectionMethod::createFromMethodName(__METHOD__);
|
||||
} else {
|
||||
$reflection = new \ReflectionMethod(__METHOD__);
|
||||
}
|
||||
$docs = $reflection->getDocComment();
|
||||
|
||||
return (is_string($docs) && strlen($docs) > 50);
|
||||
|
|
|
|||
|
|
@ -13,10 +13,10 @@ if (PHP_VERSION_ID < 80100) {
|
|||
exit(1);
|
||||
}
|
||||
|
||||
// Show warning if >= PHP 8.4 is used as Nextcloud is not compatible with >= PHP 8.4 for now
|
||||
if (PHP_VERSION_ID >= 80400) {
|
||||
// Show warning if >= PHP 8.5 is used as Nextcloud is not compatible with >= PHP 8.5 for now
|
||||
if (PHP_VERSION_ID >= 80500) {
|
||||
http_response_code(500);
|
||||
echo 'This version of Nextcloud is not compatible with PHP>=8.4.<br/>';
|
||||
echo 'This version of Nextcloud is not compatible with PHP>=8.5.<br/>';
|
||||
echo 'You are currently running ' . PHP_VERSION . '.';
|
||||
exit(1);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue