Skip to content

Commit

Permalink
Merge branch 'v1.x' into merge-v1.20-into-v1.x-1726733540824
Browse files Browse the repository at this point in the history
* v1.x: (87 commits)
  Performance: Keep collections and indexes between GridFS tests (#1421)
  Add final annotations to non-internal Operation classes (#1410)
  Fix types accepted by $round (#1401)
  Replace arrayHasKey with assertArrayHasKey in tests (#1403)
  PHPLIB-1514 Make data providers static (#1404)
  PHPLIB-1515 Replace assertObjectHasAttribute with assertObjectHasProperty (#1405)
  Restore Prose22_RangeExplicitEncryptionTest (#1400)
  Remove Prose22_RangeExplicitEncryptionTest that requires ext-mongodb < 1.20 (#1394)
  Use `match` instead of `switch` when a simple value is returned (#1393)
  Remove PHPUnit functions polyfill (#1395)
  Update branch names for GHA workflows (#1390)
  PHPLIB-1419 Encode Agg builder objects in Collection methods (#1383)
  PHPLIB-1420 Integrate query builder for non-aggregation APIs (#1385)
  Fix optional parameter declared before required parameter (#1384)
  PHPLIB-1505 Add driver option "builderEncoder" (#1382)
  Exclude rector.php from the artifact
  Check generated files are up-to-date
  Replace composer package mongodb/builder
  Skip Pedentry method sort for generated files
  Remove composer constraints already imposed by the main package
  ...
  • Loading branch information
alcaeus committed Sep 19, 2024
2 parents 50d1db7 + b27a61d commit 7e2925a
Show file tree
Hide file tree
Showing 1,140 changed files with 66,258 additions and 5,372 deletions.
1 change: 0 additions & 1 deletion .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,3 @@ include:
- filename: .evergreen/config/generated/test/require-api-version.yml
- filename: .evergreen/config/generated/test/csfle.yml
- filename: .evergreen/config/generated/test-variant/modern-php-full.yml
- filename: .evergreen/config/generated/test-variant/legacy-php-full.yml
14 changes: 1 addition & 13 deletions .evergreen/config/build-task-groups.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,10 @@ task_groups:
# Builds all versions of PHP
- name: "build-all-php"
# Keep this number in sync with the number of PHP versions to allow for parallel builds
max_hosts: 4
max_hosts: 3
setup_task: *build_setup
setup_task_can_fail_task: true
setup_task_timeout_secs: 1800
teardown_task: *build_teardown
tasks:
- ".build"

# Builds all versions of PHP that support OpenSSL 3 (PHP 8.1+)
- name: "build-php-openssl3"
# Keep this number in sync with the number of PHP versions to allow for parallel builds
# Subtract 2 versions as PHP 7.4 and 8.0 are not built with OpenSSL 3
max_hosts: 2
setup_task: *build_setup
setup_task_can_fail_task: true
setup_task_timeout_secs: 1800
teardown_task: *build_teardown
tasks:
- ".build !.php7.4 !.php8.0"
8 changes: 4 additions & 4 deletions .evergreen/config/build-variants.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ buildvariants:
tags: ["build", "debian", "x64"]
run_on: debian12-small
tasks:
- name: "build-php-openssl3"
- name: "build-all-php"
- name: build-debian11
display_name: "Build: Debian 11"
tags: ["build", "debian", "x64", "pr", "tag"]
Expand All @@ -34,7 +34,7 @@ buildvariants:
tags: ["build", "rhel", "x64", "pr", "tag"]
run_on: rhel90-small
tasks:
- name: "build-php-openssl3"
- name: "build-all-php"
- name: build-rhel83-zseries
display_name: "Build: RHEL 8.3 Zseries"
tags: ["build", "rhel", "zseries", "tag"]
Expand Down Expand Up @@ -66,13 +66,13 @@ buildvariants:
tags: ["build", "ubuntu", "x64", "pr", "tag"]
run_on: ubuntu2204-small
tasks:
- name: "build-php-openssl3"
- name: "build-all-php"
- name: build-ubuntu2204-arm64
display_name: "Build: Ubuntu 22.04 ARM64"
tags: ["build", "ubuntu", "arm64", "tag"]
run_on: ubuntu2204-arm64-small
tasks:
- name: "build-php-openssl3"
- name: "build-all-php"
- name: build-ubuntu2004
display_name: "Build: Ubuntu 20.04 x64"
tags: ["build", "ubuntu", "x64", "pr", "tag"]
Expand Down
10 changes: 2 additions & 8 deletions .evergreen/config/generate-config.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,11 @@
<?php

// Supported PHP versions. Add new versions to the beginning of the list
$modernPhpVersions = [
$supportedPhpVersions = [
'8.3',
'8.2',
'8.1',
];
$legacyPhpVersions = [
'8.0',
'7.4',
];
$supportedPhpVersions = array_merge($modernPhpVersions, $legacyPhpVersions);

$latestPhpVersion = max($supportedPhpVersions);
$lowestPhpVersion = min($supportedPhpVersions);
Expand Down Expand Up @@ -59,8 +54,7 @@
$allFiles[] = generateConfigs('tasks', 'test', 'mongodbVersion', 'csfle.yml', $csfleServerVersions);

// Test variants
$allFiles[] = generateConfigs('buildvariants', 'test-variant', 'phpVersion', 'modern-php-full.yml', $modernPhpVersions);
$allFiles[] = generateConfigs('buildvariants', 'test-variant', 'phpVersion', 'legacy-php-full.yml', $legacyPhpVersions);
$allFiles[] = generateConfigs('buildvariants', 'test-variant', 'phpVersion', 'modern-php-full.yml', $supportedPhpVersions);
// TODO: Re-enable when 1.20.0 is released
// $allFiles[] = generateConfigs('buildvariants', 'test-variant', 'phpVersion', 'phpc.yml', [$latestPhpVersion]);
// $allFiles[] = generateConfigs('buildvariants', 'test-variant', 'phpVersion', 'lowest.yml', [$lowestPhpVersion]);
Expand Down
84 changes: 0 additions & 84 deletions .evergreen/config/generated/build/build-extension.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

114 changes: 0 additions & 114 deletions .evergreen/config/generated/test-variant/legacy-php-full.yml

This file was deleted.

56 changes: 0 additions & 56 deletions .evergreen/config/templates/test-variant/legacy-php-full.yml

This file was deleted.

8 changes: 8 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ tests export-ignore
benchmark export-ignore
docs export-ignore
examples export-ignore
generator export-ignore
mongo-orchestration export-ignore
stubs export-ignore
tools export-ignore
Expand All @@ -14,6 +15,13 @@ phpunit.evergreen.xml export-ignore
phpunit.xml.dist export-ignore
psalm.xml.dist export-ignore
psalm-baseline.xml export-ignore
rector.php export-ignore

# Prevent generated build files from showing diffs in pull requests
.evergreen/config/generated/** linguist-generated=true
/src/Builder/Accumulator/*.php linguist-generated=true
/src/Builder/Expression/*.php linguist-generated=true
/src/Builder/Query/*.php linguist-generated=true
/src/Builder/Projection/*.php linguist-generated=true
/src/Builder/Stage/*.php linguist-generated=true
/tests/Builder/*/Pipelines.php linguist-generated=true
4 changes: 4 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ inputs:
description: "INI values to pass along to setup-php action"
required: false
default: ""
working-directory:
description: "The directory where composer.json is located, if it is not in the repository root."
required: false

runs:
using: composite
Expand Down Expand Up @@ -49,3 +52,4 @@ runs:
# Revert when psalm supports PHP 8.4
# composer-options: "--no-suggest"
composer-options: "--no-suggest ${{ inputs.php-version == '8.4' && '--ignore-platform-req=php+' || '' }}"
working-directory: "${{ inputs.working-directory }}"
Loading

0 comments on commit 7e2925a

Please sign in to comment.