Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Add check for self-referencing input in YAML transform #32339

Open
1 of 17 tasks
Polber opened this issue Aug 27, 2024 · 0 comments
Open
1 of 17 tasks

[Bug]: Add check for self-referencing input in YAML transform #32339

Polber opened this issue Aug 27, 2024 · 0 comments

Comments

@Polber
Copy link
Contributor

Polber commented Aug 27, 2024

What happened?

The following pipeline will fail

pipeline:
  transforms:
    - type: Create
      name: Source
      config:
        elements:
          - id: 1
      input: Source
    - type: LogForTesting
      input: Source

with following error:

  ...
  File "/Users/jkinard/beam/sdks/python/apache_beam/yaml/yaml_transform.py", line 163, in strip_metadata
    if isinstance(spec, Mapping):
       ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/jkinard/.pyenv/versions/3.11.6/lib/python3.11/typing.py", line 1305, in __instancecheck__
    return self.__subclasscheck__(type(obj))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/jkinard/.pyenv/versions/3.11.6/lib/python3.11/typing.py", line 1583, in __subclasscheck__
    return issubclass(cls, self.__origin__)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RecursionError: maximum recursion depth exceeded in __subclasscheck__

Due to self-referencing transform - this should be a more clear error and caught earlier

Issue Priority

Priority: 2 (default / most bugs should be filed as P2)

Issue Components

  • Component: Python SDK
  • Component: Java SDK
  • Component: Go SDK
  • Component: Typescript SDK
  • Component: IO connector
  • Component: Beam YAML
  • Component: Beam examples
  • Component: Beam playground
  • Component: Beam katas
  • Component: Website
  • Component: Infrastructure
  • Component: Spark Runner
  • Component: Flink Runner
  • Component: Samza Runner
  • Component: Twister2 Runner
  • Component: Hazelcast Jet Runner
  • Component: Google Cloud Dataflow Runner
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant