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

Update DictSet to allow direct initialisation #3031

Merged
merged 1 commit into from
Jun 1, 2023
Merged

Update DictSet to allow direct initialisation #3031

merged 1 commit into from
Jun 1, 2023

Conversation

kavanase
Copy link
Contributor

@kavanase kavanase commented Jun 1, 2023

This is a quick fix to allow direct initialisation of the DictSet class, which was possible before but broke in #2972 due to the Yb_2 check querying self.CONFIG, which is only defined if DictSet was being initialised from a subclass and not directly.

This fixes this behaviour by checking the config_dict which is a required input parameter so always defined (same as self.CONFIG if initialising from a subclass), and also updates this with the user_potcar_settings before checking, in case the user has explicitly specified to avoid the Yb_2 POTCAR.

Demo in the attached notebook and PDF!

pymatgen_DictSet_fix.zip

@shyuep shyuep merged commit 4b645c4 into materialsproject:master Jun 1, 2023
@shyuep
Copy link
Member

shyuep commented Jun 1, 2023

Thanks!

@janosh janosh added io Input/output functionality fix Bug fix PRs vasp Vienna Ab initio Simulation Package labels Jun 2, 2023
kavanase added a commit to SMTG-Bham/doped that referenced this pull request Aug 9, 2023
…d in materialsproject/pymatgen#3031, but still keeping fix for backwards compatibility with this `pymatgen` release
kavanase added a commit to SMTG-Bham/doped that referenced this pull request Oct 30, 2023
…d in materialsproject/pymatgen#3031, but still keeping fix for backwards compatibility with this `pymatgen` release

Former-commit-id: 0b72560
kavanase added a commit to SMTG-Bham/doped that referenced this pull request Nov 1, 2023
…d in materialsproject/pymatgen#3031, but still keeping fix for backwards compatibility with this `pymatgen` release

Former-commit-id: 0b72560
kavanase added a commit to SMTG-Bham/doped that referenced this pull request Nov 1, 2023
…d in materialsproject/pymatgen#3031, but still keeping fix for backwards compatibility with this `pymatgen` release

Former-commit-id: 55b021b [formerly 0b72560]
Former-commit-id: fe89a4c
kavanase added a commit to SMTG-Bham/doped that referenced this pull request Nov 1, 2023
…d in materialsproject/pymatgen#3031, but still keeping fix for backwards compatibility with this `pymatgen` release

Former-commit-id: 0b72560
Former-commit-id: fe89a4c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fix PRs io Input/output functionality vasp Vienna Ab initio Simulation Package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants