File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
website/www/site/content/en/documentation Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -955,9 +955,10 @@ the actual processing logic. You don't need to manually extract the elements
955955from the input collection; the Beam SDKs handle that for you. Your ` process ` method
956956should accept an argument ` element ` , which is the input element, and return an
957957iterable with its output values. You can accomplish this by emitting individual
958- elements with ` yield ` statements. You can also use a ` return ` statement
959- with an iterable, like a list or a generator. Don't mix ` yield ` and
960- ` return ` statements in the same ` process ` method - this leads to [ undefined behavior] ( https://github.com/apache/beam/issues/22969 ) .
958+ elements with ` yield ` statements, and use ` yield from ` to emit all elements from
959+ an iterable, such as a list or a generator. Using ` return ` statement
960+ with an iterable is also acceptable as long as you don't mix ` yield ` and
961+ ` return ` statements in the same ` process ` method, since that leads to [ incorrect behavior] ( https://github.com/apache/beam/issues/22969 ) .
961962{{< /paragraph >}}
962963
963964{{< paragraph class="language-go">}}
You can’t perform that action at this time.
0 commit comments