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

Deprecate from_string #3158

Merged
merged 5 commits into from Jul 15, 2023
Merged

Deprecate from_string #3158

merged 5 commits into from Jul 15, 2023

Conversation

janosh
Copy link
Member

@janosh janosh commented Jul 15, 2023

Some classes have static method from_string (Poscar, CifParser, ...), other's from_str (Structure, Molecule, ...).

from_str is shorter and clear enough, so rename methods to that and add deprecated from_string fallbacks for backwards compatibility.

@janosh janosh added api Application programming interface deprecation Code deprecations labels Jul 15, 2023
@janosh janosh enabled auto-merge (squash) July 15, 2023 21:01
@janosh janosh merged commit ed09fe7 into master Jul 15, 2023
27 checks passed
@janosh janosh deleted the deprecate-from-string branch July 15, 2023 21:41
wanghan-iapcm pushed a commit to deepmodeling/dpgen that referenced this pull request Oct 31, 2023
#1302)

To be compatible with old and new versions of Pymatgen
(materialsproject/pymatgen#3158)

---------

Signed-off-by: Levi Zhou  <31941107+ZhouXY-PKU@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Application programming interface deprecation Code deprecations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant