Respect missing values in session's conflict resolver#1230
Respect missing values in session's conflict resolver#1230gwenn merged 2 commits intorusqlite:masterfrom
Conversation
Codecov ReportBase: 77.08% // Head: 77.16% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #1230 +/- ##
==========================================
+ Coverage 77.08% 77.16% +0.07%
==========================================
Files 48 48
Lines 6223 6244 +21
==========================================
+ Hits 4797 4818 +21
Misses 1426 1426
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
|
https://sqlite.org/session/sqlite3changeset_new.html
So only |
|
I believe so ... |
I mean |
|
A precaution |
|
I checked again SQLite source code.
|
|
Sorry for the delay... |
When applying a
changeset(e.g. forUPDATE), the conflict resolver’sitemmay include "missing" values since only changed columns are provided. Trying to read unexisting columns will cause the conflict resolver to panic.The current code properly handles
SqliteFailurerelated errors (e.g.ParameterOutOfRange) but will panic for operations performed on valid but at the same time missing values.This small PR adds checks in
ChangesetItemobject that eliminate these issues and thus properly handle theResult<ValueRef>by throwingInvalidColumnIndexwhen a column is missing.