Commit 83f90ec
committed
fix(world_state): restructure is-not-None guard for pylint 4.0.4 type narrowing
Pylint 4.0.4 does not narrow Optional types through early-return None guards
on instance attributes. Restructure the membership-test block inside an
positive guard instead of using an
early-exit pattern.
Semantically equivalent; resolves E1135/E1133 pylint errors:
- world_state.py:295: E1135 unsupported-membership-test
- world_state.py:298/301: E1133 not-an-iterable
Fixes #2591 parent 89b6fbd commit 83f90ec
1 file changed
Lines changed: 12 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
290 | 290 | | |
291 | 291 | | |
292 | 292 | | |
293 | | - | |
294 | | - | |
295 | | - | |
296 | | - | |
297 | | - | |
298 | | - | |
299 | | - | |
300 | | - | |
301 | | - | |
302 | | - | |
303 | | - | |
304 | | - | |
305 | | - | |
306 | | - | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
307 | 305 | | |
308 | 306 | | |
309 | 307 | | |
| |||
0 commit comments