Sometimes the default symprec and angle_tolerance used by pymatgen.core.Structure.get_space_group_info are too tight or loose to accurately determine the crystalline symmetry. In those cases, Structure.get_space_group_info throws an error 'NoneType' object is not subscriptable and building a ValidationDoc fails during both the kpoint and incar checks.*
This PR adds a new deprecation message for this by checking if get_space_group_info can be called on the input structure during validation, as well as a test for this behavior.
* Long explanation: in pymatgen, the Kpoints object checks the space group to see if a lattice is face-centered, because only Gamma-centered grids and not Monkhorst-Pack k-points grids should be used for face-centered lattices, per VASP. The symmetry check was added to pymatgen in PR #3245, and relies on get_space_group_info
Sometimes the default
symprec
andangle_tolerance
used bypymatgen.core.Structure.get_space_group_info
are too tight or loose to accurately determine the crystalline symmetry. In those cases,Structure.get_space_group_info
throws an error'NoneType' object is not subscriptable
and building a ValidationDoc fails during both the kpoint and incar checks.*This PR adds a new deprecation message for this by checking if
get_space_group_info
can be called on the input structure during validation, as well as a test for this behavior.* Long explanation: in pymatgen, the Kpoints object checks the space group to see if a lattice is face-centered, because only Gamma-centered grids and not Monkhorst-Pack k-points grids should be used for face-centered lattices, per VASP. The symmetry check was added to pymatgen in PR #3245, and relies on
get_space_group_info