-
-
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
#2926 Fix backslashes double escaping #3342
Conversation
Looks like a duplicate of #3330. |
Indeed 😢 What's odd though is that my testcase passes for oracle |
d9ed4cf
to
69e9d5d
Compare
Is it because the test doesn't perform any assertions? It should check that the table was created exactly as specified, not just the absence of an exception. |
I don't see a good, platform agnostic way to do that, do you? SchemaManager removes doctrine type from comments, so it's empty. |
Does it have to be tested this indirectly (custom type → column comment → escaping) if we're only modifying the way how escaping works?
And you don't have to unless there's an escaping-specific case apart from just escaping tested in #3330. |
Concern of this testcase isn't really about internals of escaping, but about ensuring whatever DBAL writes can read too. If it screws up the write part, at least it should also screw up read part same way, so it matches.
In theory yes, but it turns out indirect test passes for oracle, so there might be other things wrong. For the record - yes, your testcase should be enough, but we need to investigate what the heck is going on with oci8. |
It fails locally for me with oci8
So, now why does it fail as it should locally, but not on CI 🤔 |
cae4b80
to
132ac8d
Compare
132ac8d
to
cd9eb23
Compare
So this is because of shared connection between tests. Comments are init only once 🙄 |
Seems during #2442 these backslash strategies were added to several DB engines blindly, without verifying if they require such backslashes. What several people experience at least with Postgres then is that DBAL generates SQLs with duplicated backslashes and upon retrieving it from database can't match it with definition (where it's single backslashed).
I can't write backlash specific test case for every single DB operation, but I verified several operations manually (schema, foreign keys, closeActiveDatabaseConnectionsSQL...) and from that I see postgresql does not treat backslash as escape character anywhere.