Skip to content

Conversation

slee-lab
Copy link
Contributor

Summary

Issue: when temperature %100==0 but is type float, you get KeyError because G_ELEMS has keys of integer values.

Major changes:

  • feature 1: updated to handle float temperature values
  • fix 1: G_ELEMS[str(self.temp)] is changed to G_ELEMS[str(int(self.temp))]

Checklist

  • Google format doc strings added. Check with ruff.
  • Type annotations included. Check with mypy.
  • Tests added for new features/fixes.
  • If applicable, new classes/functions/modules have duecredit @due.dcite decorators to reference relevant papers by DOI (example)

Tip: Install pre-commit hooks to auto-check types and linting before every commit:

pip install -U pre-commit
pre-commit install

@shyuep shyuep enabled auto-merge (squash) March 22, 2025 16:23
@shyuep
Copy link
Member

shyuep commented Mar 22, 2025

Thanks,.

@shyuep shyuep disabled auto-merge April 20, 2025 19:38
@shyuep shyuep merged commit c71ae6f into materialsproject:master Apr 20, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants