Skip to content
← All tracks

Laziness, Iteration and Pipelines

Python

Generators, iterators, `itertools` pipelines and the memory profile of doing the same work lazily.

This track is written for Python, which isn't the mode you're browsing in.

0 / 9 solved · 5 articles
  1. 1. Generators as a memory strategy Read
  2. 2. Iterator, Iterable, Generator, Sequence Read
  3. 3. Async iterators and async generators Read
  4. 4. Never yield inside a TaskGroup or timeout scope Read
  5. 5. zip(strict=True) and the silent-truncation bug Read
  6. 6. Not solved yet. Async iterators: the paginator you can actually close
  7. 7. Not solved yet. Batched async stream: never yield inside a cancel scope
  8. 8. Not solved yet. Bounded concurrency and backpressure
  9. 9. Not solved yet. Lazy record batches: what laziness moves
  10. 10. Not solved yet. Iterator, Iterable, Generator, Sequence — and what the annotation promises
  11. 11. Not solved yet. Streaming pipelines end to end
  12. 12. Not solved yet. The streaming sort-merge join
  13. 13. Not solved yet. The single-consumption contract
  14. 14. Not solved yet. zip(strict=True) and the silent-truncation bug

Check yourself

4 questions · one attempt each

These do not count toward finishing the track. They are here to catch the things that are easy to read past.

0 / 4

What does zip do when the inputs are different lengths?

list(zip([1, 2, 3], [1, 2]))
list(zip([1, 2, 3], [1, 2], strict=True))
Question 1 of 4