From 4f58887f82724088f2c2b04574d60443c907d0bb Mon Sep 17 00:00:00 2001 From: Zike Date: Fri, 10 Nov 2023 11:35:53 -0500 Subject: [PATCH 1/4] Update Request.zep The Http request service cannot invoke filterService from container. --- phalcon/Http/Request.zep | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/phalcon/Http/Request.zep b/phalcon/Http/Request.zep index be9ed7e50b1..9e529c36f12 100644 --- a/phalcon/Http/Request.zep +++ b/phalcon/Http/Request.zep @@ -17,6 +17,7 @@ use Phalcon\Filter\FilterInterface; use Phalcon\Http\Message\RequestMethodInterface; use Phalcon\Http\Request\File; use Phalcon\Http\Request\FileInterface; +use Phalcon\Filter\FilterFactory; use Phalcon\Http\Request\Exception; use Phalcon\Support\Helper\Json\Decode; use UnexpectedValueException; @@ -1646,15 +1647,13 @@ class Request extends AbstractInjectionAware implements RequestInterface, Reques if typeof filterService != "object" { let container = this->container; - - if container === null { - throw new Exception( - "A dependency injection container is required to access the 'filter' service" - ); + if typeof container == "object" && container->has("filter") { + let filter = container->getShared("filter"), + this->filterService = filter; + } else { + this->filterService = (new FilterFactory())->newInstance(); } - - let filterService = container->getShared("filter"), - this->filterService = filterService; + this->filterService = filterService; } return this->filterService; From d2edea6bf55f6decf83cbd3da8fb6f97b82d9988 Mon Sep 17 00:00:00 2001 From: Nikolaos Dimopoulos Date: Mon, 2 Jun 2025 22:46:32 +0000 Subject: [PATCH 2/4] enable 8.4 DLLs --- .github/workflows/compile-windows.yml | 31 ++++++++++++++++++++------- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/.github/workflows/compile-windows.yml b/.github/workflows/compile-windows.yml index 8d009de3984..99d12a631b8 100644 --- a/.github/workflows/compile-windows.yml +++ b/.github/workflows/compile-windows.yml @@ -1,19 +1,34 @@ name: "[Windows] Build Phalcon" -on: [push, pull_request] + +on: + - push + - pull_request + +env: + # All versions should be declared here + PHALCON_VERSION: 5.9.3 jobs: windows: runs-on: windows-latest - name: "Build Phalcon (PHP ${{matrix.php}}-${{matrix.ts}}-${{matrix.arch}})" + name: "Build Phalcon (PHP ${{ matrix.php }}-${{ matrix.ts }}-${{ matrix.arch }})" defaults: run: shell: cmd strategy: fail-fast: false matrix: - php: ["8.0","8.1","8.2","8.3"] - arch: [x64,x86] - ts: [nts,ts] + php: + - '8.1' + - '8.2' + - '8.3' + - '8.4' + arch: + - x64 + - x86 + ts: + - nts + - ts experimental: [false] steps: - name: Checkout Phalcon @@ -31,7 +46,7 @@ jobs: - name: Setup PHP id: setup-php - uses: php/setup-php-sdk@v0.8 + uses: php/setup-php-sdk@v0.10 with: version: ${{matrix.php}} arch: ${{matrix.arch}} @@ -76,7 +91,7 @@ jobs: $phalconDllOpt = 'TEST_PHP_ARGS=-n -d zend_extension=' + $dir + '\php_phalcon.dll' echo $phalconDllOpt >> $env:GITHUB_ENV - $artifactName = 'php_phalcon-php${{matrix.php}}' + $artifactName = 'php_phalcon-${{ env.PHALCON_VERSION }}-php${{matrix.php}}' if ('nts' -ne '${{matrix.ts}}') { $artifactName = $artifactName + '-ts' } if ('nts' -eq '${{matrix.ts}}') { $artifactName = $artifactName + '-nts' } @@ -105,4 +120,4 @@ jobs: name: ${{env.ARTIFACT_NAME}} path: | ${{env.ARTIFACT}} - LICENSE.txt \ No newline at end of file + LICENSE.txt From a99584006adbccb8f9bae2665c5a9bd55f206cbd Mon Sep 17 00:00:00 2001 From: Sid Roberts Date: Sat, 27 Sep 2025 09:21:41 +0900 Subject: [PATCH 3/4] Suppressed Code Sniffer rule for missing namespace. --- .../Helper/DispatcherTestDefaultNoNamespaceController.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php b/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php index 9ac78e341aa..85ca75adf4a 100644 --- a/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php +++ b/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php @@ -1,10 +1,7 @@ - Date: Sat, 27 Sep 2025 09:21:54 +0900 Subject: [PATCH 4/4] Added explicit visibility to constants. --- .../Helper/DispatcherTestDefaultNoNamespaceController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php b/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php index 85ca75adf4a..a4c3ff9df85 100644 --- a/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php +++ b/tests/integration/Mvc/Dispatcher/Helper/DispatcherTestDefaultNoNamespaceController.php @@ -20,8 +20,8 @@ */ class DispatcherTestDefaultNoNamespaceController extends Controller { - const RETURN_VALUE_STRING = 'string'; - const RETURN_VALUE_INT = 5; + public const RETURN_VALUE_STRING = 'string'; + public const RETURN_VALUE_INT = 5; public function beforeExecuteRoute() {