-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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 to disable schema emulation on SQLite #5517
Conversation
Guys, can this PR be merged as is as no tests is failing after the "eat prefixed tables" hack from 2011 has been removed? Or what test you want me to write? |
Looks like a duplicate of #4804. |
Yes, it was fixed as part of #4804. Can it be backported to DBAL 3.3.x or to 3.4.x at least? |
If you find a backwards-compatible way to do so, we can probably discuss it. But this PR in its current form is a BC break unfortunately. |
I will update this PR to move the |
015bc79
to
583d56a
Compare
done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. @morozov, what do you think?
@derrabus is there anything againt to land this into 3.3.x? It is a kind of a bugfix. |
You're creating a new extension point which is beyond what a bugfix should do imho. |
I am fixing "unhacked table name" support (see https://github.com/doctrine/dbal/pull/5517/files#r922818649) in BC way. As long as the user does not override |
I'm not saying that there is one, am I? Why does it matter so much to you that we rush this into a bugfix release? |
In atk4/data framework, I need to support working with multiple Sqlite databases. Without this PR, I would have to override and copy paste the fixed impl. in every method of |
Introducing a protected method to allow overriding it to disable its functionality looks like a hack. If we want this behavior to be configurable, we need to add an API, e.g. dbal/src/Platforms/PostgreSQLPlatform.php Lines 73 to 76 in 25c27dd
The pull request is missing a description (as well as the linked issue) and tests. As for whether to backport it to 3.3.x, most likely, 3.4.0 and 3.3.8 will be released together, so there's no point in backporting the patch IMO. |
I will add the option as in PostgreSQLPlatform. And a test /w ATTACH if the no other SqlitePlatform fixes will be needed. About the targeting - if 3.4 will be out soon, it seems ok. |
cfa1afa
to
8cf3ff6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The name of the new switch should reflect the feature that we're about to remove.
That being said, should that switch affect the return value of canEmulateSchemas()
as well?
Good point, I think yes to be consistent with #4804 |
Please squash the commits before the merge. The history of code changes in the feature branch isn't necessary to be stored in the repository history. |
a60239e
to
dd52646
Compare
Feedback addressed and squashed. |
Summary
Needed for atk4/data#1033