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

Allow AttributeClasses to be initialized with values #605

Open
lilyminium opened this issue Jan 21, 2025 · 0 comments · May be fixed by #606
Open

Allow AttributeClasses to be initialized with values #605

lilyminium opened this issue Jan 21, 2025 · 0 comments · May be fixed by #606

Comments

@lilyminium
Copy link
Contributor

lilyminium commented Jan 21, 2025

Currently all subclasses of AttributeClasses need their attributes to be set separately to instantiation, e.g.:

batch = Batch()
batch.id = ...
batch.force_field_id = ...

It'd be quite handy to be able to initialize attributes e.g. Batch(id=..., force_field_id=...).

Some classes define __init__ methods to allow this, so there may be a reason why this isn't more generally supported?

@lilyminium lilyminium linked a pull request Jan 21, 2025 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant