Save the date! Google I/O returns May 18-20 Register now


Collects tagged values from a function.

Transforms a function to return the original output and intermediate collected values. In implementation, returns partial(harvest(f), {}). See harvest for more details.

f a function to be transformed
tag str, the harvest tag that will be reaped.
**harvest_kwargs additional keyword arguments that will be passed to harvest.

A function that returns tagged values (a dictionary mapping names to values that were collected).