Commit 9bb5158
committed
[fix] Addressed review comments
- Replaced the assert authorizing websocket connections with an explicit
conditional, which python -O cannot strip
- Rechecked permissions and organization scope on every websocket request
and pushed update, closing the socket when access was revoked
- Accepted binary frames in BatchCommandConsumer.receive() and ignored them
- Revalidated batch ownership when creating child commands and before
executing each one, skipping devices transferred to another organization
- Made the batch status write conditional on the status the calculation
started from, so a stale result cannot overwrite a newer one
- Evaluated the confirm page device ids once, so the reviewed set and the
executed set cannot diverge
- Rotated the wizard token when the target set changes, dropping the
exclusions of the previous set
- Sent the active filters with the reconnect request, applied them before
pagination and reconciled the table against the filtered snapshot
- Moved the batch command signal receivers to connection/handlers.py
- Moved skipped device counting, filtering and row building to the model
- Broadcast canonical status and ISO timestamps, rendering them in the
browser like the single command page does
- Derived the device admin URLs from the swapped model
- Restored the wizard when the confirm page Back link is used
- Returned the union of the schemas available to superusers
- Made the password masking of the input summary case insensitive
- Restored the punctuation of the command validation messages
- Pluralized the device count of the confirm page
- Documented mass commands as asynchronous with a concurrency which
depends on the celery workers
- Removed the leftovers of the dropped Django 4.2 support1 parent 73b2315 commit 9bb5158
21 files changed
Lines changed: 1632 additions & 466 deletions
File tree
- docs/user
- openwisp_controller
- config/base
- connection
- base
- channels
- migrations
- static/connection/js
- templates/admin/connection/batch_command
- tests
- tests/openwisp2/sample_connection
- migrations
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
245 | | - | |
246 | | - | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
247 | 249 | | |
248 | 250 | | |
249 | 251 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
204 | 204 | | |
205 | 205 | | |
206 | 206 | | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
207 | 212 | | |
208 | | - | |
| 213 | + | |
| 214 | + | |
209 | 215 | | |
210 | 216 | | |
211 | 217 | | |
212 | 218 | | |
213 | 219 | | |
214 | 220 | | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
215 | 225 | | |
216 | 226 | | |
217 | 227 | | |
| |||
221 | 231 | | |
222 | 232 | | |
223 | 233 | | |
| 234 | + | |
| 235 | + | |
224 | 236 | | |
225 | | - | |
226 | 237 | | |
227 | | - | |
| 238 | + | |
| 239 | + | |
228 | 240 | | |
| 241 | + | |
229 | 242 | | |
230 | 243 | | |
231 | 244 | | |
| |||
239 | 252 | | |
240 | 253 | | |
241 | 254 | | |
242 | | - | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
243 | 263 | | |
244 | 264 | | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
245 | 270 | | |
246 | 271 | | |
247 | 272 | | |
248 | 273 | | |
249 | 274 | | |
250 | 275 | | |
251 | | - | |
252 | | - | |
253 | | - | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
254 | 281 | | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
35 | 39 | | |
36 | | - | |
37 | 40 | | |
38 | | - | |
| 41 | + | |
39 | 42 | | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
45 | 48 | | |
46 | 49 | | |
47 | 50 | | |
| |||
0 commit comments