From 621cdfbb9284d46cea97eb239e8458626a549248 Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Thu, 17 Oct 2024 12:07:35 -0700 Subject: [PATCH] Fix doc references. --- sdks/python/apache_beam/examples/snippets/snippets.py | 4 ++-- sdks/python/scripts/generate_pydoc.sh | 3 +++ .../www/site/content/en/documentation/programming-guide.md | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/sdks/python/apache_beam/examples/snippets/snippets.py b/sdks/python/apache_beam/examples/snippets/snippets.py index a16e4c7eef61..c849af4a00b3 100644 --- a/sdks/python/apache_beam/examples/snippets/snippets.py +++ b/sdks/python/apache_beam/examples/snippets/snippets.py @@ -1187,13 +1187,13 @@ def model_multiple_pcollections_flatten_with_transform(contents, output_path): SomeTransform = lambda: beam.Map(lambda x: x) SomeOtherTransform = lambda: beam.Map(lambda x: x) - # [START model_multiple_pcollections_flatten_with] + # [START model_multiple_pcollections_flatten_with_transform] merged = ( pcoll | SomeTransform() | beam.FlattenWith(beam.Create(['x', 'y', 'z'])) | SomeOtherTransform()) - # [END model_multiple_pcollections_flatten_with] + # [END model_multiple_pcollections_flatten_with_transform] merged | beam.io.WriteToText(output_path) diff --git a/sdks/python/scripts/generate_pydoc.sh b/sdks/python/scripts/generate_pydoc.sh index 3462429190c8..827df30861cb 100755 --- a/sdks/python/scripts/generate_pydoc.sh +++ b/sdks/python/scripts/generate_pydoc.sh @@ -244,6 +244,9 @@ ignore_identifiers = [ # IPython Magics py:class reference target not found 'IPython.core.magic.Magics', + + # Type variables. + 'apache_beam.transforms.util.T', ] ignore_references = [ 'BeamIOError', diff --git a/website/www/site/content/en/documentation/programming-guide.md b/website/www/site/content/en/documentation/programming-guide.md index 04f7bf62499d..f4058e604288 100644 --- a/website/www/site/content/en/documentation/programming-guide.md +++ b/website/www/site/content/en/documentation/programming-guide.md @@ -2085,7 +2085,7 @@ PCollection. {{< /paragraph >}} {{< highlight py >}} -{{< code_sample "sdks/python/apache_beam/examples/snippets/snippets.py" model_multiple_pcollections_flatten_with_transforms >}} +{{< code_sample "sdks/python/apache_beam/examples/snippets/snippets.py" model_multiple_pcollections_flatten_with_transform >}} {{< /highlight >}} {{< highlight go >}}