Commit 1e92a71
fix: don't clobber unset interface fields on partial update
update_interface dumped the full InterfaceUpdate model without
exclude_unset, so any partial update (e.g. description only) sent None
for every other field including port, tripping interface.port's NOT
NULL constraint and 500ing. Now the DB write only applies fields the
caller actually sent; configure_interface still gets the full merged
state since it indexes port/mode/etc unconditionally.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>1 parent 847dd05 commit 1e92a71
1 file changed
Lines changed: 9 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
111 | | - | |
112 | | - | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
113 | 114 | | |
114 | 115 | | |
115 | 116 | | |
116 | 117 | | |
117 | 118 | | |
118 | | - | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
119 | 122 | | |
120 | | - | |
| 123 | + | |
121 | 124 | | |
122 | | - | |
123 | | - | |
| 125 | + | |
| 126 | + | |
124 | 127 | | |
125 | 128 | | |
126 | 129 | | |
| |||
0 commit comments