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

Symfony 7 support #1933

Closed
wants to merge 35 commits into from
Closed

Symfony 7 support #1933

wants to merge 35 commits into from

Conversation

l-you
Copy link
Contributor

@l-you l-you commented Dec 4, 2023

Fixes #1932. Add PHP 8.3 tests.

This PR replaces #1931 and #1930.

@l-you
Copy link
Contributor Author

l-you commented Dec 4, 2023

There is an issue with dependencies.
doctrine/phpcr-odm locked to symfony/[email protected].
There is a ready PR that adds support for Symfony 7 in doctrine/phpcr-odm. Take a look at doctrine/phpcr-odm#846.

@l-you
Copy link
Contributor Author

l-you commented Dec 4, 2023

The second reason tests are failing is that jms/serializer-bundle has no support for Symfony 7 components.
There is a draft PR that would fix that: schmittjoh/JMSSerializerBundle#937 but merge state is unknown.

@l-you
Copy link
Contributor Author

l-you commented Dec 4, 2023

.github/workflows/continuous-integration.yaml Outdated Show resolved Hide resolved
composer.json Outdated Show resolved Hide resolved
composer.json Outdated Show resolved Hide resolved
@evertharmeling
Copy link
Contributor

@XWB do you or somebody else be able to check this PR and move it forward? @rusted-love could you check the Code style errors in the CI flow (/ re-push code to re-run the CI which should have the other errors fixed since the mentioned blocked issues are merged)? 🚀

@XWB
Copy link
Member

XWB commented Jan 10, 2024

I can only merge when all pipelines have passed.

@l-you
Copy link
Contributor Author

l-you commented Jan 11, 2024

@rusted-love could you check the Code style errors in the CI flow (/ re-push code to re-run the CI which should have the other errors fixed since the mentioned blocked issues are merged)? 🚀

@evertharmeling Yes, doctrine/phpcr-odm#846 was merged a few days ago, but it was not released under next minor version (1.8.0 -> 1.8.1). Still waiting for a release tag to move forward.

.gitignore Outdated Show resolved Hide resolved
src/Index/AliasProcessor.php Outdated Show resolved Hide resolved
@Seb33300
Copy link

Seb33300 commented Feb 6, 2024

What version of PHP-CS-fixer did you use to update the code style?
The workflow is using version 3.8.0

tools: 'composer-normalize, php-cs-fixer:3.8.0'

You may need to update the workflow version to prevent it to fail

@llupa
Copy link
Contributor

llupa commented Feb 27, 2024

Hey 👋 @rusted-love Do you still have time/interest to work on this PR?

@l-you
Copy link
Contributor Author

l-you commented Feb 27, 2024

Hey 👋 @rusted-love Do you still have time/interest to work on this PR?

@llupa Yes, but I need a community suggestion how to move forward. Should I wait for a stable phpcr-odm v2 release or there is a way to release current PR with beta version of 'phpcr-odm' today?

@llupa
Copy link
Contributor

llupa commented Feb 27, 2024

but I need a community suggestion how to move forward.

I think first it would be great if you can run php-cs-fixer at 3.8.0 on your code and update this branch so Continuous integration / Coding style (pull_request) passes.

And dbu asked (in the same PR your linked):

have you been able to build FOSElasticaBundle with the latest dev-2.x version? that would be a good check to know if we break anything for you.

Since you have all this work done, you could switch to their upcoming v2 and see if this pipeline will keep working. I personally would update in this same PR and mark it as Draft just in case. Or if you feel unsure, make another branch out of this branch and try it out.

If the tests pass, pinging David will only add reassurance for his ~planned release end of this month.

What do you think? @rusted-love

@l-you
Copy link
Contributor Author

l-you commented Feb 29, 2024

@llupa I've done what you said. There are issues with dependencies again. For some reason composer does not use RC-1 and beta releases. I would be glad to get help again. :)

@evertharmeling
Copy link
Contributor

For some reason composer does not use RC-1 and beta releases. I would be glad to get help again. :)

Probably due to not having minimum-stablity defined in the composer.json, which defaults to stable (see).

...
    "minimum-stability": "RC",
    "prefer-stable": true,
...

This should do the trick, allowing specific RC versions when defined, but rely on stable otherwise. But we should also be careful using RC/beta releases from a bundle perspective of course.

@evertharmeling evertharmeling mentioned this pull request Mar 20, 2024
3 tasks
XWB pushed a commit that referenced this pull request Mar 20, 2024
* Update dependencies

* add php 8.3

* add symfony 7 to tests

* exclude php 7.4 from tests for symfony 7

* Exclude all php versions prior to 8.2 for Symfony 7. Minimum supported Symfony 7 php version is 8.2 https://symfony.com/releases/7.0

* Require minimum doctrine/phpcr-odm 1.5.3. This is the lowest version with support for php 8.*

* Exclude php 8.3 symfony 7 lowest dependencies from CI. Higher doctrine/phpcr-odm version should be used for php 8.3

* Revert "Exclude php 8.3 symfony 7 lowest dependencies from CI. Higher doctrine/phpcr-odm version should be used for php 8.3"

This reverts commit 22c8a4c.

* Run cs fixer

* fix code style

* fix a suddenly excluded case

* Lock to symfony/console@^6.1 because of issue with doctrine/phpcr-odm as described in #1933 (comment)

* run cs fixer

* Bump jms/serializer-bundle to v5

* Remove jms/serializer-bundle v3 support because php 7.2 has reached an end of life https://www.php.net/supported-versions.php

* add php 8.3 to phpstan

* Update all Symfony references to ^6.3

* Add symfony/console 7.0 to dependencies.

* Normalize continuous integration matrix.

* Normalize continuous integration matrix.

* update gitignore

* fix gitignore

* fix typo

* Replace php-cs-fixer with a shim version. It allows us to lock with any desired version without the need to update the rest of dependencies.

* Run php-cs-fixer with locked version 3.8.0.

* Add support for doctrine/phpcr-odm 2-beta release.

* Cs fixer fix

* Bump knplabs/knp-components

* Fix php cs fixer version.

* CS Fixer fixes with version 3.8.0.

* Add symfony/stopwatch because it's required by project

* Bumb jackalope/jackalope-doctrine-dbal to RC-1

* Normalize composer

* Disable symfony testing with php 8.2 and 8.3

* minimum stability RC

* [cs] Fix composer.json

* [phpunit] Fix 'framework.annotations' error

* [phpunit] Fix 'getAliasNamespace' error

* [phpunit] Not use CodeExtension anymore

* [phpunit] Variable 'profile_type' does not exist

* Make use of 'AsMessageHandler' attribute in favor of MessageHandlerInterface + dropped support for SF 4.4 (as AsMessageHandler is available in SF 5.4)

* [phpstan] Excluded AsyncPersistPageHandler as attributes are not supported

* [phpstan] Fix ContainerAwareInterface not found

---------

Co-authored-by: Liakhovskyi Vladyslav <[email protected]>
Co-authored-by: Liakhovskyi Vladyslav <[email protected]>
@evertharmeling
Copy link
Contributor

This issue may be closed due to the merge of #1938

@XWB
Copy link
Member

XWB commented Mar 20, 2024

Closing in favor of #1938

@XWB XWB closed this Mar 20, 2024
7ochem pushed a commit to 7ochem/FOSElasticaBundle that referenced this pull request Apr 18, 2024
* Update dependencies

* add php 8.3

* add symfony 7 to tests

* exclude php 7.4 from tests for symfony 7

* Exclude all php versions prior to 8.2 for Symfony 7. Minimum supported Symfony 7 php version is 8.2 https://symfony.com/releases/7.0

* Require minimum doctrine/phpcr-odm 1.5.3. This is the lowest version with support for php 8.*

* Exclude php 8.3 symfony 7 lowest dependencies from CI. Higher doctrine/phpcr-odm version should be used for php 8.3

* Revert "Exclude php 8.3 symfony 7 lowest dependencies from CI. Higher doctrine/phpcr-odm version should be used for php 8.3"

This reverts commit 22c8a4c.

* Run cs fixer

* fix code style

* fix a suddenly excluded case

* Lock to symfony/console@^6.1 because of issue with doctrine/phpcr-odm as described in FriendsOfSymfony#1933 (comment)

* run cs fixer

* Bump jms/serializer-bundle to v5

* Remove jms/serializer-bundle v3 support because php 7.2 has reached an end of life https://www.php.net/supported-versions.php

* add php 8.3 to phpstan

* Update all Symfony references to ^6.3

* Add symfony/console 7.0 to dependencies.

* Normalize continuous integration matrix.

* Normalize continuous integration matrix.

* update gitignore

* fix gitignore

* fix typo

* Replace php-cs-fixer with a shim version. It allows us to lock with any desired version without the need to update the rest of dependencies.

* Run php-cs-fixer with locked version 3.8.0.

* Add support for doctrine/phpcr-odm 2-beta release.

* Cs fixer fix

* Bump knplabs/knp-components

* Fix php cs fixer version.

* CS Fixer fixes with version 3.8.0.

* Add symfony/stopwatch because it's required by project

* Bumb jackalope/jackalope-doctrine-dbal to RC-1

* Normalize composer

* Disable symfony testing with php 8.2 and 8.3

* minimum stability RC

* [cs] Fix composer.json

* [phpunit] Fix 'framework.annotations' error

* [phpunit] Fix 'getAliasNamespace' error

* [phpunit] Not use CodeExtension anymore

* [phpunit] Variable 'profile_type' does not exist

* Make use of 'AsMessageHandler' attribute in favor of MessageHandlerInterface + dropped support for SF 4.4 (as AsMessageHandler is available in SF 5.4)

* [phpstan] Excluded AsyncPersistPageHandler as attributes are not supported

* [phpstan] Fix ContainerAwareInterface not found

---------

Co-authored-by: Liakhovskyi Vladyslav <[email protected]>
Co-authored-by: Liakhovskyi Vladyslav <[email protected]>
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.

Support for Symfony 7
5 participants