-
-
Notifications
You must be signed in to change notification settings - Fork 203
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
Allow data-fixtures v2 #457
Open
greg0ire
wants to merge
1
commit into
doctrine:3.7.x
Choose a base branch
from
greg0ire:data-fixtures-2-compat
base: 3.7.x
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The interfaces introduced in 1.5.0 allow to test without mocking a final class.
greg0ire
force-pushed
the
data-fixtures-2-compat
branch
from
November 13, 2024 18:21
d78551a
to
d7ec426
Compare
The CI failure makes me think that |
This should help: symfony/symfony#58861 |
nicolas-grekas
added a commit
to symfony/symfony
that referenced
this pull request
Nov 20, 2024
…v2 (greg0ire) This PR was merged into the 5.4 branch. Discussion ---------- Dynamically fix compatibility with doctrine/data-fixtures v2 | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Issues | see explanation below | License | MIT While working on [allowing v2 of doctrine/data-fixtures in the bundle](doctrine/DoctrineFixturesBundle#457), I stumbled upon an issue that only affects some versions of Symfony that still have a `ContainerAwareLoader` class. The signature of `ContainerAwareLoader::addFixture()` is not compatible with the v2 signature of the `Loader` interface from `doctrine/data-fixtures`, as per this fatal error: ``` Declaration of Symfony\Bridge\Doctrine\DataFixtures\ContainerAwareLoader::addFixture(Doctrine\Common\DataFixtures\FixtureInterface $fixture) must be compatible with Doctrine\Common\DataFixtures\Loader::addFixture(Doctrine\Common\DataFixtures\FixtureInterface $fixture): void ``` Classes that extend ContainerAwareLoader have to also extend Loader, meaning this is no breaking change because it can be argued that the incompatibility of the extending class would be with the Loader interface. Closes #58861, Closes #58863 Commits ------- 1812aaf Dynamically fix compatibility with doctrine/data-fixtures v2
symfony-splitter
pushed a commit
to symfony/doctrine-bridge
that referenced
this pull request
Nov 20, 2024
…v2 (greg0ire) This PR was merged into the 5.4 branch. Discussion ---------- Dynamically fix compatibility with doctrine/data-fixtures v2 | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Issues | see explanation below | License | MIT While working on [allowing v2 of doctrine/data-fixtures in the bundle](doctrine/DoctrineFixturesBundle#457), I stumbled upon an issue that only affects some versions of Symfony that still have a `ContainerAwareLoader` class. The signature of `ContainerAwareLoader::addFixture()` is not compatible with the v2 signature of the `Loader` interface from `doctrine/data-fixtures`, as per this fatal error: ``` Declaration of Symfony\Bridge\Doctrine\DataFixtures\ContainerAwareLoader::addFixture(Doctrine\Common\DataFixtures\FixtureInterface $fixture) must be compatible with Doctrine\Common\DataFixtures\Loader::addFixture(Doctrine\Common\DataFixtures\FixtureInterface $fixture): void ``` Classes that extend ContainerAwareLoader have to also extend Loader, meaning this is no breaking change because it can be argued that the incompatibility of the extending class would be with the Loader interface. Closes #58861, Closes #58863 Commits ------- 1812aafe065 Dynamically fix compatibility with doctrine/data-fixtures v2
3 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The interfaces introduced in 1.5.0 allow to test without mocking a final class.
Closes #456