-
Notifications
You must be signed in to change notification settings - Fork 868
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
TypeError: deprecated() got an unexpected keyword argument 'deadline' #3855
Comments
Yes we already noticed this #3752 (comment), please try to update |
@DanielYang59 Yes. Your tip does the trick. But, should the pymatgen/pymatgen/core/periodic_table.py Line 701 in 2982968
|
Great to know. Sorry I forgot to update the Line 32 in 2982968
Sorry I don't quite understand your question, this |
I mean, why wait until 2025-01-01, and not remove it immediately? |
We decided to schedule it for removal after 2025-01-01 in #3817 to minimize potential impact to other's code base. If we were to remove it immediately, all code relying on this would be broken without a grace period. |
Python version
Python 3.11.1
Pymatgen version
2024.5.31
Operating system version
Ubuntu 22.04.4 LTS
Current behavior
Description: When trying to import MPRester from mp_api.client, I encountered a TypeError related to the deprecated decorator in the pymatgen library. The error message indicates that the deprecated() function received an unexpected keyword argument 'deadline'.
Error Traceback:
TypeError: deprecated() got an unexpected keyword argument 'deadline'
Expected Behavior
The code should execute without errors, fetching materials data and generating VASP input files.
Actual Behavior:
The code execution is halted by a TypeError due to an unexpected keyword argument 'deadline' in the deprecated decorator.
Environment:
Additional Information:
The issue seems to be related to the deprecated decorator in the pymatgen library, specifically in the ElementBase class in periodic_table.py.
Possible Solution:
Check the implementation of the deprecated decorator and ensure it handles the 'deadline' keyword argument correctly.
This issue affects the usage of both mp-api and pymatgen libraries. Please investigate and provide a fix or workaround.
Minimal example
Relevant files to reproduce this bug
No response
Regards,
Zhao
The text was updated successfully, but these errors were encountered: