v1.15.1
-
Fixed: a condition comparing a field to
nullpassed as a parameter was
encoded asfield = ?bound tonull.= NULLis never true in SQL, so the
query returned no rows instead of the rows whose column is null.ConditionSQLEncoderdid turn=/INagainst null intoIS NULL(and
!=/NOT INintoIS NOT NULL), but only when the null was written
straight into the statement. A null arriving as a parameter is encoded as a
placeholder, whose text never equals'null', so the conversion was skipped.
Entity queries take the parameter form, which is why it surfaced there:// Returned [] with matching rows present; now returns the rows whose // `state` is null. repository.selectByQuery(' state == ? && active == ? ', parameters: {'state': null, 'active': true});
The encoder is shared, so this affected every SQL adapter — SQLite,
PostgreSQL and MySQL alike — and any condition compared against a null
parameter, including compound ones whose other terms matched.Rewriting the comparison also leaves the parameter unmentioned by the
statement, so it is now dropped once the condition is encoded: PostgreSQL
rejects a statement carrying variables it does not use. A placeholder still
referenced by another operator (field > ?bound to null) keeps its binding.Covered now by the shared adapter test suite, so all three adapters exercise
it. -
reflection_factory:^2.8.1→^2.9.0.- 2.8.1 pinned
dart_styleto the formatter bundled with Dart 3.12, so on
Dart 3.13 the generated*.reflection.g.dartno longer matched this
package's owndart format, makingdart format --set-exit-if-changedand
test/ensure_build_test.dartmutually exclusive. 2.9.0 tracks the
formatter the SDK ships.
- 2.8.1 pinned