-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update GMSO to work with pydantic 2.0 (#745)
* first pass using bump-pydantic per https://docs.pydantic.dev/2.0/migration/ * Further update syntax in abc and core * checkpoint * checkpoint * rip out json_encoder since it iss being deprecated, will need to fix serialization related functions later * fix up atom related files and tests * fix bond.py * fix up dihedral and improper * fix various import in tests, removed json handler import * re-add __hash__ method for atom type and parametric potential * replace parse_obj with model_validate * add serializer for several fields, fix everything but test_serialization and test_xml_handling * fix some of the serialization test * reimplement json_dict, parse_raw (since model_validate_json raised unimplemeted error), all serialization tests fixed * found workaround to avoid using parse_raw * fix remainder of xml handling test by change atom_type._etree_attrib to be consistent previous version * update potential templates to use expected_parameters_dimensions_ for consistency * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix typo * add the missing alias key * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * udpate env yml * remove pydantic from matrx in CI --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information
1 parent
c014a44
commit 096da71
Showing
43 changed files
with
559 additions
and
554 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
from gmso.abc.serialization_utils import GMSOJSONHandler, unyt_to_dict | ||
from gmso.abc.serialization_utils import unyt_to_dict |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.