Commit 771a6de
committed
refactor: Address code review feedback for field modifier ordering
Address valid GitHub Copilot feedback:
1. Replace magic number index access in FT.INFO parsing
- Changed info[7] to proper key-based lookup for 'attributes'
- More resilient to Redis response format changes
- Added helpful error message if key not found
2. Enhance time complexity documentation
- Added detailed breakdown of O(n + m) complexity
- Clarified set creation and lookup costs
Rejected feedback about testing implementation details - unit tests
appropriately test the _normalize_field_modifiers helper function
directly, while integration tests verify end-to-end behavior.1 parent 6342f2b commit 771a6de
File tree
2 files changed
+10
-2
lines changed- redisvl/schema
- tests/integration
2 files changed
+10
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
118 | 120 | | |
119 | 121 | | |
120 | 122 | | |
| |||
Lines changed: 7 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
300 | | - | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
301 | 307 | | |
302 | 308 | | |
303 | 309 | | |
| |||
0 commit comments