diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5e640b2..8b912ba 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,6 +11,7 @@ jobs: strategy: matrix: php: + - 8.5 - 8.4 - 8.3 - 8.2 @@ -26,7 +27,7 @@ jobs: - 5.4 - 5.3 steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} @@ -39,7 +40,7 @@ jobs: runs-on: ubuntu-24.04 continue-on-error: true steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - run: cp "$(which composer)" composer.phar && ./composer.phar self-update --2.2 # downgrade Composer for HHVM - name: Run hhvm composer.phar install uses: docker://hhvm/hhvm:3.30-lts-latest diff --git a/composer.json b/composer.json index f56cb23..0d33cdf 100644 --- a/composer.json +++ b/composer.json @@ -12,14 +12,14 @@ ], "require": { "php": ">=5.3", - "react/promise": "^3.2 || ^2.1 || ^1.2.1", - "react/socket": "^1.16", + "react/promise": "^3.3 || ^2.1 || ^1.2.1", + "react/socket": "^1.17", "ringcentral/psr7": "^1.2" }, "require-dev": { "phpunit/phpunit": "^9.6 || ^8.5 || ^5.7 || ^4.8.36", "react/async": "^4.3 || ^3 || ^2", - "react/event-loop": "^1.2", + "react/event-loop": "^1.6", "react/http": "^1.11", "react/promise-timer": "^1.11" }, diff --git a/src/ProxyConnector.php b/src/ProxyConnector.php index 0e7bcdb..3cb6b22 100644 --- a/src/ProxyConnector.php +++ b/src/ProxyConnector.php @@ -261,7 +261,9 @@ public function connect($uri) // avoid garbage references by replacing all closures in call stack. // what a lovely piece of code! $r = new \ReflectionProperty('Exception', 'trace'); - $r->setAccessible(true); + if (PHP_VERSION_ID < 80100) { + $r->setAccessible(true); + } $trace = $r->getValue($e); // Exception trace arguments are not available on some PHP 7.4 installs diff --git a/tests/ProxyConnectorTest.php b/tests/ProxyConnectorTest.php index 0839692..bf2e292 100644 --- a/tests/ProxyConnectorTest.php +++ b/tests/ProxyConnectorTest.php @@ -24,7 +24,9 @@ public function testConstructWithoutConnectorAssignsConnectorAutomatically() $proxy = new ProxyConnector('proxy.example.com'); $ref = new \ReflectionProperty($proxy, 'connector'); - $ref->setAccessible(true); + if (PHP_VERSION_ID < 80100) { + $ref->setAccessible(true); + } $connector = $ref->getValue($proxy); $this->assertInstanceOf('React\Socket\ConnectorInterface', $connector);