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

Fix inconsistent methods syntax (read/write, get/set, etc.) #180

Open
aimalz opened this issue Jun 22, 2023 · 2 comments
Open

Fix inconsistent methods syntax (read/write, get/set, etc.) #180

aimalz opened this issue Jun 22, 2023 · 2 comments
Labels
bug Something isn't working documentation Improvements or additions to documentation good first issue Good for newcomers

Comments

@aimalz
Copy link
Collaborator

aimalz commented Jun 22, 2023

Under "storing/retrieving ensembles" in the demo, there's a mismatch between the code and the description (qp.Ensemble.read_from vs. qp.Ensemble.read).

Also, since the primary use case is RAIL, we should make a shortcut to opening a DataHandle directly without having to manually run it through tables_io. Perhaps this could be the difference between read/write and read_from/write_to, whether it's just dealing with the raw qp.Ensemble or the DataHandle?

EDIT: #192 covers a broader issue with qp.Ensemble.ancil but also has an example of .set() without .get(), which effectively has a totally different syntax of just .ancil(). It would be a lot more intuitive to users if we were consistent about using or not using these pairs of common methods, and it might prevent some pathological behavior at the same time.

@aimalz aimalz added bug Something isn't working documentation Improvements or additions to documentation good first issue Good for newcomers labels Jun 22, 2023
@aimalz aimalz changed the title Demo bugs/needs re: metrics and file i/o Fix inconsistent methods syntax (read/write, get/set, etc.) Aug 31, 2023
@eacharles
Copy link
Collaborator

Neither qp.Ensemble.read_from nor qp.Ensemble.read exist.

qp.factory.read does exist, and it is equivalent to qp.read. I'll go ahead an update the demo to use that.

@eacharles
Copy link
Collaborator

I'm not understanding what you want with data handles and tables_io here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants