Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[2.x] Fix CI #363

Merged
merged 7 commits into from
Feb 22, 2025
Merged

[2.x] Fix CI #363

merged 7 commits into from
Feb 22, 2025

Conversation

jtojnar
Copy link
Collaborator

@jtojnar jtojnar commented Feb 22, 2025

Cherry-picking backwards compatible changes from master.

jtojnar and others added 7 commits February 22, 2025 14:59
Makes hacking on Graby more convenient.

(cherry picked from commit 8ce0ec6)
PHP-CS-Fixer 3.17.0 enables new rules, let’s apply them to code.

(partially cherry picked from commit 22ac9ca)

Fix coding style with newer PHP-CS-Fixer

- Fix newly detected `native_function_invocation` and `array_indentation` rule violations.
- ~~Disable union_types option in `phpdoc_to_*_type` rules since we still support PHP 7.4.~~ Not relevant
- Fix the following warning:
  > Option "use_nullable_type_declaration" for rule "nullable_type_declaration_for_default_null_value" is deprecated and will be removed in version 4.0. Behaviour will follow default one.

This happened was needed when I upgraded PHP-CS-Fixer from v3.51.0 to v3.64.0.

(cherry picked from commit cd13fbb)
Otherwise the date tests will fail locally, when user does not have timezone set.

Fixes: #318
(cherry picked from commit e157035)
(cherry picked from commit aac2f73)
The `testWithEmptyReplaceString` page now returns 410 Gone HTTP response.

Not including the rector config changes since I do not want to bother maintaining it in the 2.x branch.

(partially cherry picked from commit bc5ec79)
Since we install `php-http/guzzle6-adapter` by default and our Guzzle 5 CI job just removes it and installs `php-http/guzzle5-adapter` instead, we already have a lockfile, which prevents installation of the older adapter:

    Your requirements could not be resolved to an installable set of packages.

      Problem 1
        - Root composer.json requires php-http/guzzle5-adapter * -> satisfiable by php-http/guzzle5-adapter[dev-master, v0.1.0, ..., v0.6.0, v1.0.0, v1.0.1, 2.0.0, 2.0.x-dev].
        - guzzlehttp/guzzle[5.1.0, ..., 5.2.0] require guzzlehttp/ringphp ~1.0 -> satisfiable by guzzlehttp/ringphp[1.0.0, ..., 1.1.x-dev].
        - guzzlehttp/guzzle[5.3.0, ..., 5.3.1] require guzzlehttp/ringphp ^1.1 -> satisfiable by guzzlehttp/ringphp[1.1.0, 1.1.1, 1.1.x-dev].
        - guzzlehttp/guzzle[5.3.2, ..., 5.3.x-dev] require react/promise ^2.2 -> found react/promise[v2.2.0, ..., 2.x-dev] but the package is fixed to v3.2.0 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
        - guzzlehttp/ringphp[1.0.0, ..., 1.1.x-dev] require react/promise ~2.0 -> found react/promise[v2.0.0, ..., 2.x-dev] but the package is fixed to v3.2.0 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
        - php-http/guzzle5-adapter v0.1.0 requires php-http/discovery ^0.1 -> found php-http/discovery[v0.1.0, v0.1.1] but it conflicts with your root composer.json require (^1.19).
        - php-http/guzzle5-adapter v0.1.1 requires php-http/httplug ^1.0.0-beta -> found php-http/httplug[v1.0.0-beta, v1.0.0-RC1, v1.0.0, v1.1.0] but it conflicts with your root composer.json require (^2.4).
        - php-http/guzzle5-adapter[v0.2.0, ..., v0.6.0, v1.0.0, ..., v1.0.1] require php-http/httplug ^1.0 -> found php-http/httplug[v1.0.0-alpha, ..., v1.1.0] but it conflicts with your root composer.json require (^2.4).
        - php-http/guzzle5-adapter[dev-master, 2.0.0, ..., 2.0.x-dev] require guzzlehttp/guzzle ^5.1 -> satisfiable by guzzlehttp/guzzle[5.1.0, ..., 5.3.x-dev].

On master we have removed it in 49939fb. But here, we still want to support it so let’s force the installation using `php-http/guzzle6-adapter`.
@jtojnar jtojnar merged commit dc2c4a5 into 2.x Feb 22, 2025
15 checks passed
@jtojnar jtojnar deleted the backport-ci branch February 22, 2025 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants