mp-api 0.45.2__tar.gz → 0.45.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mp_api-0.45.2 → mp_api-0.45.4}/PKG-INFO +3 -2
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/core/client.py +2 -9
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/summary.py +4 -4
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api.egg-info/PKG-INFO +3 -2
- {mp_api-0.45.2 → mp_api-0.45.4}/.coveragerc +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.github/workflows/lint.yml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.github/workflows/release.yml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.github/workflows/testing.yml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.github/workflows/upgrade_dependencies.yml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.gitignore +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/.pre-commit-config.yaml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/CODE_OF_CONDUCT.md +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/LICENSE +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/README.md +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/Makefile +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/_templates/custom-class-template.rst +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/_templates/custom-module-template.rst +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/conf.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/index.rst +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/make.bat +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/docs/modules.rst +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/core/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/core/settings.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/core/utils.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/mprester.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/_general_store.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/_messages.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/_user_settings.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/absorption.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/alloys.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/bonds.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/chemenv.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/dielectric.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/doi.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/elasticity.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/electrodes.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/electronic_structure.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/eos.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/grain_boundaries.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/magnetism.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/materials.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/oxidation_states.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/phonon.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/piezo.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/provenance.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/robocrys.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/similarity.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/substrates.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/summary.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/surface_properties.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/synthesis.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/tasks.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/thermo.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/materials/xas.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/bonds.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/jcesr.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/molecules.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/orbitals.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/partial_charges.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/partial_spins.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/redox.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/tasks.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/thermo.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api/client/routes/molecules/vibrations.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api.egg-info/SOURCES.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api.egg-info/dependency_links.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api.egg-info/requires.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/mp_api.egg-info/top_level.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/pyproject.toml +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/requirements/requirements-ubuntu-latest_py3.10.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/requirements/requirements-ubuntu-latest_py3.10_extras.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/requirements/requirements-ubuntu-latest_py3.11.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/requirements/requirements-ubuntu-latest_py3.11_extras.txt +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/setup.cfg +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/Si_mp_149.cif +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/calcs_reversed_mp_1031016.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/materials_Li_Fe_V.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/synth_doc.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/synth_doc_adaptor.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/synth_doc_adaptor_synpro.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/test_files/tasks_Li_Fe_V.json +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/core_function.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_bonds.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_chemenv.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_dielectric.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_elasticity.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_electrodes.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_electronic_structure.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_eos.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_grain_boundary.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_magnetism.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_materials.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_oxidation_states.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_piezo.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_provenance.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_robocrys.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_substrates.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_summary.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_surface_properties.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_synthesis.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_tasks.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_thermo.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/materials/test_xas.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/molecules/__init__.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/molecules/core_function.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/molecules/test_jcesr.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/molecules/test_summary.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/test_client.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/test_core_client.py +0 -0
- {mp_api-0.45.2 → mp_api-0.45.4}/tests/test_mprester.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: mp-api
|
|
3
|
-
Version: 0.45.
|
|
3
|
+
Version: 0.45.4
|
|
4
4
|
Summary: API Client for the Materials Project
|
|
5
5
|
Author-email: The Materials Project <feedback@materialsproject.org>
|
|
6
6
|
License: modified BSD
|
|
@@ -40,6 +40,7 @@ Requires-Dist: mypy-extensions; extra == "test"
|
|
|
40
40
|
Requires-Dist: typing-extensions; extra == "test"
|
|
41
41
|
Requires-Dist: types-setuptools; extra == "test"
|
|
42
42
|
Requires-Dist: types-requests; extra == "test"
|
|
43
|
+
Dynamic: license-file
|
|
43
44
|
|
|
44
45
|
# The Materials Project API
|
|
45
46
|
|
|
@@ -14,7 +14,6 @@ import sys
|
|
|
14
14
|
import warnings
|
|
15
15
|
from concurrent.futures import FIRST_COMPLETED, ThreadPoolExecutor, wait
|
|
16
16
|
from copy import copy
|
|
17
|
-
from datetime import datetime
|
|
18
17
|
from functools import cache
|
|
19
18
|
from importlib.metadata import PackageNotFoundError, version
|
|
20
19
|
from json import JSONDecodeError
|
|
@@ -223,18 +222,12 @@ class BaseRester(Generic[T]):
|
|
|
223
222
|
remains unchanged and available for querying via its task_id.
|
|
224
223
|
|
|
225
224
|
The database version is set as a date in the format YYYY_MM_DD,
|
|
226
|
-
where "_DD" may be optional. An additional numerical suffix
|
|
225
|
+
where "_DD" may be optional. An additional numerical or `postN` suffix
|
|
227
226
|
might be added if multiple releases happen on the same day.
|
|
228
227
|
|
|
229
228
|
Returns: database version as a string
|
|
230
229
|
"""
|
|
231
|
-
|
|
232
|
-
# Convert the string to a datetime object
|
|
233
|
-
date_obj = datetime.strptime(date_str, "%Y.%m.%d")
|
|
234
|
-
|
|
235
|
-
# Format the datetime object as a string
|
|
236
|
-
formatted_date = date_obj.strftime("%Y.%m.%d")
|
|
237
|
-
return formatted_date
|
|
230
|
+
return requests.get(url=endpoint + "heartbeat").json()["db_version"]
|
|
238
231
|
|
|
239
232
|
def _post_resource(
|
|
240
233
|
self,
|
|
@@ -19,7 +19,7 @@ class MoleculesSummaryRester(BaseRester[MoleculeSummaryDoc]):
|
|
|
19
19
|
spin_multiplicity: int | None = None,
|
|
20
20
|
nelements: tuple[int, int] | None = None,
|
|
21
21
|
chemsys: str | list[str] | None = None,
|
|
22
|
-
deprecated: bool | None = None,
|
|
22
|
+
# deprecated: bool | None = None,
|
|
23
23
|
elements: list[str] | None = None,
|
|
24
24
|
exclude_elements: list[str] | None = None,
|
|
25
25
|
formula: str | list[str] | None = None,
|
|
@@ -52,7 +52,7 @@ class MoleculesSummaryRester(BaseRester[MoleculeSummaryDoc]):
|
|
|
52
52
|
# ["wB97X-V/def2-TZVPPD/SMD(VACUUM)", "wB97M-V/def2-QZVPPD/SMD(SOLVENT=WATER)"])
|
|
53
53
|
chemsys (str, List[str]): A chemical system, list of chemical systems
|
|
54
54
|
(e.g., Li-C-O, [C-O-H-N, Li-N]).
|
|
55
|
-
deprecated (bool): Whether the material is tagged as deprecated.
|
|
55
|
+
#deprecated (bool): Whether the material is tagged as deprecated.
|
|
56
56
|
elements (List[str]): A list of elements.
|
|
57
57
|
exclude_elements (List(str)): List of elements to exclude.
|
|
58
58
|
formula (str, List[str]): An alphabetical formula or list of formulas
|
|
@@ -98,8 +98,8 @@ class MoleculesSummaryRester(BaseRester[MoleculeSummaryDoc]):
|
|
|
98
98
|
if spin_multiplicity:
|
|
99
99
|
query_params.update({"spin_multiplicity": spin_multiplicity})
|
|
100
100
|
|
|
101
|
-
if deprecated is not None:
|
|
102
|
-
|
|
101
|
+
# if deprecated is not None:
|
|
102
|
+
# query_params.update({"deprecated": deprecated})
|
|
103
103
|
|
|
104
104
|
if formula:
|
|
105
105
|
if isinstance(formula, str):
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: mp-api
|
|
3
|
-
Version: 0.45.
|
|
3
|
+
Version: 0.45.4
|
|
4
4
|
Summary: API Client for the Materials Project
|
|
5
5
|
Author-email: The Materials Project <feedback@materialsproject.org>
|
|
6
6
|
License: modified BSD
|
|
@@ -40,6 +40,7 @@ Requires-Dist: mypy-extensions; extra == "test"
|
|
|
40
40
|
Requires-Dist: typing-extensions; extra == "test"
|
|
41
41
|
Requires-Dist: types-setuptools; extra == "test"
|
|
42
42
|
Requires-Dist: types-requests; extra == "test"
|
|
43
|
+
Dynamic: license-file
|
|
43
44
|
|
|
44
45
|
# The Materials Project API
|
|
45
46
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|