-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix collect on stateful iterators #42172
Conversation
Recursing into inference may be unreliable during inference.
This requires a manual backport against |
This seems to have broken
|
It looks like Unzip has a bug where it accidentally tries to return a |
Nope, that's not a bug, it's a choice. Unzip will fill in missing for iterators of differently sized tuples:
I found this while rewriting, so this is no longer an issue, but. |
zip is expected to truncate to the shortest input |
Hmm, well, I guess that implies that zip could never provide tuples of different sizes, so unzipping tuples of different sizes is undefined...I could error here, which would make the code a lot simpler but also less fun. As of now, I have my own version of the collect method, without a type assert, that will error for empty iterators if I can't guess the column types. https://github.com/bramtayl/Unzip.jl/blob/c239114b4b7faf71dab924c1832a11eaa0312d22/src/Unzip.jl#L317 |
Generalization of #41919
Fixes #42168
Needed to also fix some ssair code, which was unnecessarily relying on inference recursively, and led to some other fixes.