You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure how all this works, so if my idea doesn't make sense or isn't feasible, no worries.
My thought is to have a generic type that could encompass objects like the pandas or polars dataframe without having to import those libraries. Maybe it's a collection? The motivation is that these libraries can be large and so their use could be made optional, but in order to type a function that could take one as an argument, the library or a stubs dependency would have to be added. There is the pandas-stubs, which is what make this DOA, but one doesn't exist for polars (which might make it out of scope here). Not sure if there are other libaries/objects that would benefit from something like this. Anyway, just had the thought and I think mostly answered it to myself as I typed but maybe someone else has more thoughts/suggestions.
example:
# something object could either be a string (json) or a dataframedefprocess_records(records: Union[str, typing.frame]) ->Union[dict, typing.frame]:
...
The text was updated successfully, but these errors were encountered:
I'm not sure how all this works, so if my idea doesn't make sense or isn't feasible, no worries.
My thought is to have a generic type that could encompass objects like the pandas or polars dataframe without having to import those libraries. Maybe it's a collection? The motivation is that these libraries can be large and so their use could be made optional, but in order to type a function that could take one as an argument, the library or a stubs dependency would have to be added. There is the pandas-stubs, which is what make this DOA, but one doesn't exist for polars (which might make it out of scope here). Not sure if there are other libaries/objects that would benefit from something like this. Anyway, just had the thought and I think mostly answered it to myself as I typed but maybe someone else has more thoughts/suggestions.
example:
The text was updated successfully, but these errors were encountered: