-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Throw OptimisticLockException when connection::commit() returns false #7946
Throw OptimisticLockException when connection::commit() returns false #7946
Conversation
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.
Thank you for your PR. Please add unit tests that are covering your changes.
I'd like to but there are currently no tests for exception in commit process, or I should create another connection mock with commit that return false ? |
529d1e4
to
3418aac
Compare
Tests added and checks passed |
Thank you for the changes. You introduced changes in .scrutinizer.yml, the travis file and composer.json. Are these changes relevant to your feature? |
Yes since doctrine/dbal now needs at least php 7.2 |
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.
Lot of tests fail for me locally. Not sure why travis did not start here, but tests must run
8d976c8
to
06df782
Compare
@ostrolucky I think there is a problem with travis. The request is in status "Abuse detected"... By the way, I changed my unit test. There was already lot of tests failures in the 2.8.x branch for me locally. So I don't know what to do with that. |
8381c9b
to
fe4a5c1
Compare
Apparently the issue was transient, here is your build! |
Aand it shows failures I mentioned. I guess UPGRADE.md should also be upgraded, since this is minor BC break. |
fe4a5c1
to
720f9eb
Compare
I can't get travis to work with me... |
720f9eb
to
479f8c8
Compare
57185bb
to
d19e1c0
Compare
d19e1c0
to
09868c8
Compare
2b6f1ee
to
e83b91b
Compare
e83b91b
to
8e39aa9
Compare
8e39aa9
to
21bf46c
Compare
Is this still considered a WIP? |
@SenseException Not for me |
Any update ? |
I'm undecided for the usage of Otherwise I'm fine with the changes. |
@SenseException I don't know for master, the current commit without error may have be solve. But meanwhile, we have to do with the current interface that can return false |
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.
master has changed it to void
Good point. Fortunately that won't break this code, just make bool condition dead. I expect phpstan will alert us on it in future so we can remove it then.
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.
If postponing the issue with bool -> void is acceptable for this PR, then I'll give my approval.
Proposal for #7893 in order to handle silently failed commits