Just because, from missingbuiltins import * items = chunker(range(5), 2) jsonl_dump("my_items.jsonl", items) # => 5 got = list(jsonl_load("my_items.jsonl")) # => [[1, 2], [3, 4], [5]]https://github.com/jbn/missingbuiltins …
-
Show this thread
-
Replying to @generativist
If you want some input, not a fan of extractor. If a caller needs to do that, they should just use tuple comprehension. Instead of: jsonl_dump('fname', itemlist, lambda x: x['foo']) just do: jsonl_dump('fname', (x['foo'] for x in itemlist))
1 reply 0 retweets 0 likes
Replying to @encthenet
Yea good point — needless complexity. Changed, pushed, and bumped to v.0.0.2
4:50 PM - 4 Mar 2020
0 replies
0 retweets
1 like
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.