Skip to content

eval() function does not try all declared types #3082

@BClappe

Description

@BClappe

Before submitting the issue

  • I have checked for Compatibility issues
  • I have searched among the existing issues
  • I am using a Python virtual environment

Description of the bug

eval() function seems not to try all declared types for a pin.

Steps To Reproduce

Let's use the export_symbolic_workflow operator:

import ansys.dpf.core as dpf
import ansys.dpf.core.operators as ops

serializer = ops.serialization.export_symbolic_workflow(workflow=dpf.Workflow())
content = serializer.eval()  # Crashes with: ansys.dpf.gate.errors.DPFServerException: The requested Data format"data_sources" is not valid for this pin

For the only output pin, the declared types are: "data_sources | string". In this case, we want a string (denoted by the fact we didn't give any file path on pin 2), but apparently only "data_sources" has been tested, and crashed.

Which Operating System causes the issue?

Windows, Linux

Which DPF/Ansys version are you using?

Ansys 2027 R1

Which Python version causes the issue?

3.13

Installed packages

ansys-dpf-core==0.14.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions