Problem/Motivation
As noted in #3177660: Remove public properties from StatementInterface implementations and commented in https://git.drupalcode.org/project/drupal/-/merge_requests/68#note_5800,
[...] it seems that this option is not used at all in core runtime, only to prevent exceptions being thrown in some tests - probably dating back to pre-PHPUnit era. That entire option seems vestigial at this point, we may think to remove it [...]
Proposed resolution
- Deprecate the option
- Remove its usages
Remaining tasks
None
User interface changes
None
API changes
The query option "throw_exception" has been deprecated. The default value for the option will be how it works in D10.
Data model changes
None
Release notes snippet
N/a
Issue fork drupal-3189680
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3189680-deprecate-the-throwexception changes, plain diff MR !374
Comments
Comment #2
mondrakePostponed on #3186934: Introduce an ExceptionHandler class in the database API, deprecate Connection::handleQueryException
Comment #3
mondrakeOn this.
Comment #5
mondrakeComment #6
mondrakeRerolled
Comment #7
daffie CreditAttribution: daffie commentedThere is only 1 deprecation message testing and we have added 3 deprecation messages. I think we should add testing for all of them.
Patch looks good.
Comment #8
daffie CreditAttribution: daffie commentedAlso 'needs work' for the fact that the testbot fails for PostgreSQL and SQLite.
Comment #9
mondrakeAll deprecations triggered should be covered by tests now.
Comment #10
daffie CreditAttribution: daffie commentedThe option 'throw_exception' has been deprecated.
Deprecation messages are being thrown and testing has been added.
All usage of the option has been removed without bracking BC.
The CR and the IS have been updated.
For me it is RTBC.
Comment #11
alexpottThis looks really close - just one bit of test that's being removed that I think should be converted to a legacy test. I've commented on the MR.
Comment #12
mondrakeThanks @alexpott, changes in the MR.
Comment #14
mondrakeComment #16
daffie CreditAttribution: daffie commentedAll points of @alexpott have been addressed.
Back to RTBC.
Comment #17
mondrakeComment #18
alexpottCommitted and pushed 0bff06df0d to 9.3.x and d1461d6b53 to 9.2.x. Thanks!
Comment #19
alexpottI think this is too low level to need a release note and highlighting on the release note. The change record should suffice.