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

OutputFormat and Delivery enums do not make logical sense #139

Open
gordonwatts opened this issue Jun 6, 2024 · 0 comments
Open

OutputFormat and Delivery enums do not make logical sense #139

gordonwatts opened this issue Jun 6, 2024 · 0 comments
Labels
bug Something isn't working servicex Related to SX tests
Milestone

Comments

@gordonwatts
Copy link
Member

In the following code:

    spec = sx.ServiceXSpec(
        General=sx.General(
            ServiceX="atlasr22",
            Codegen=query[1],
            OutputFormat=sx.ResultFormat.root,  # type: ignore
            Delivery=("LocalCache" if download else "SignedURLs"),  # type: ignore
        ),

The OutputFormat and Delivery can be enums. However, they need to be "normalized":

  • The definition for OutputFormat uses OutputFormatEnum as its enum. However, code I've encountered uses ResultFormat, which is defined in a different place. And the two have seeminly identical definitions.

  • Same for Delivery (though that isn't defined in models.py)

  • The actual enums for this are really hard to figure out how to import.

It would be good if all of these enum's could be normalized, and importing them could be done in a straight forward way (currently deliver is at the top level import in servicex, but these enums are very deep)

@gordonwatts gordonwatts added bug Something isn't working servicex Related to SX tests labels Jun 6, 2024
@gordonwatts gordonwatts added this to the Post Test milestone Jun 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working servicex Related to SX tests
Projects
None yet
Development

No branches or pull requests

1 participant