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

Add better enum support for "experimenttype" #171

Open
DominicOram opened this issue Mar 14, 2022 · 1 comment
Open

Add better enum support for "experimenttype" #171

DominicOram opened this issue Mar 14, 2022 · 1 comment

Comments

@DominicOram
Copy link
Contributor

As a user of the API I would like to avoid having accidentally sent invalid data to ispyb. One place in particular where this is easy to go wrong is with enums as I may have an accidental typo in the string representation of it. e.g. it would be nicer to be able to do something like:

from ispyb import open, ExperimentTypes

with open(config_file) as conn:
    params = conn.mx_acquisition.get_data_collection_params()
    params["experimenttype"] = ExperimentTypes.MESH
@DominicOram
Copy link
Contributor Author

Additionally aliasing GRID to MESH or having a comment that this terminology is equivalent in the enum definition would be good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant