ksyang2013 / aimsgb

Ab-initio Interface Materials Simulation Project for Grain Boundaries (AIMSGB)
Other
57 stars 19 forks source link

Pass through all args/kwargs in Grain.__init__ #9

Closed pmrv closed 1 year ago

pmrv commented 1 year ago

I've run into a version incompatibility with newer version of pymatgen, since aimsgb doesn't specify a range. Here's a small fix for it.

In version 2023.7.11 pymatgen added a new keyword argument to the Structure constructor. Grain doesn't know about it, so Grain.from_sites would break with this or later version of pymatgen.

I decided to pass everything through as *args/**kwargs because adding a label kwarg manually would require a version bump of the pymatgen dependency as it wouldn't be backwards compatible.

Let me know if you want me to change anything.