ObjectVar __getitem__ typing issues#4380
Conversation
|
|
|
I think in the example above it could lose the typing ? I can take a look into that. |
Reflex always supported accessing vars in that way, so I think the general goal should be to add full typing support for this. (Edit: Unless you plan to migrate away from this syntax) |
|
by lose typing i meant runtime typing, reflex should maintain runtime typing as long as possible to limit the need for |
|
i believe before, all vars supported |
|
Sounds like you are hitting some of python's typing limits? :/ I have just added another test (1384514) which is quite interesting. |
i hit them very long time ago 😅 the issues are not particularly fixable.
yea! i will take a look once i'm done with another PR that overhauls functions first |
|
@adhami3310 any news regarding the objectvar |
since that other PR is taking forever, sure, we can fix it in the meantime |
@adhami3310 do you have any idea on how to fix the typing test?
reflex/tests/units/vars/test_object.py:112:5 - error: "__getitem__" method not defined on type "ObjectItemOperation" (reportGeneralTypeIssues)