diff --git a/mp_api/client/routes/materials/electrodes.py b/mp_api/client/routes/materials/electrodes.py index e2555ac06..4738b3ea5 100644 --- a/mp_api/client/routes/materials/electrodes.py +++ b/mp_api/client/routes/materials/electrodes.py @@ -16,7 +16,6 @@ class ElectrodeRester(BaseRester[InsertionElectrodeDoc]): def search( # pragma: ignore self, - material_ids: str | list[str] | None = None, battery_ids: str | list[str] | None = None, average_voltage: tuple[float, float] | None = None, capacity_grav: tuple[float, float] | None = None, @@ -43,8 +42,6 @@ def search( # pragma: ignore """Query using a variety of search criteria. Arguments: - material_ids (str, List[str]): A single Material ID string or list of strings - (e.g., mp-149, [mp-149, mp-13]). battery_ids (str, List[str]): A single battery ID string or list of strings (e.g., mp-22526_Li, [mp-22526_Li, mp-22526_Ca]). average_voltage (Tuple[float,float]): Minimum and maximum value of the average voltage for a particular @@ -85,12 +82,6 @@ def search( # pragma: ignore """ query_params = defaultdict(dict) # type: dict - if material_ids: - if isinstance(material_ids, str): - material_ids = [material_ids] - - query_params.update({"material_ids": ",".join(validate_ids(material_ids))}) - if battery_ids: if isinstance(battery_ids, str): battery_ids = [battery_ids] diff --git a/tests/materials/test_electrodes.py b/tests/materials/test_electrodes.py index 14b28f684..e4541af79 100644 --- a/tests/materials/test_electrodes.py +++ b/tests/materials/test_electrodes.py @@ -33,7 +33,6 @@ def rester(): } # type: dict custom_field_tests = { - "material_ids": ["mp-16722"], "battery_ids": ["mp-16722_Al"], "working_ion": Element("Li"), "formula": "CoO2", diff --git a/tests/materials/test_robocrys.py b/tests/materials/test_robocrys.py index 2b04436a1..74abb4628 100644 --- a/tests/materials/test_robocrys.py +++ b/tests/materials/test_robocrys.py @@ -25,9 +25,7 @@ def test_client(rester): assert doc.condensed_structure is not None -# TODO: switch this to the skipif once emmet PR 1261 is deployed to production -# @pytest.mark.skipif(os.getenv("MP_API_KEY", None) is None, reason="No API key found.") -@pytest.mark.skip(reason="Query with large result set fails with faceted pipeline") +@pytest.mark.skipif(os.getenv("MP_API_KEY", None) is None, reason="No API key found.") def test_client_large_result_set(rester): search_method = rester.search diff --git a/tests/test_client.py b/tests/test_client.py index 4001b0234..25bf18124 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -36,6 +36,7 @@ # "tasks", # "bonds", "materials_xas", + "materials_tasks", "materials_elasticity", "materials_fermi", "materials_alloys", diff --git a/tests/test_mprester.py b/tests/test_mprester.py index 7c4127d11..8eb55ef02 100644 --- a/tests/test_mprester.py +++ b/tests/test_mprester.py @@ -27,8 +27,7 @@ from pymatgen.entries.computed_entries import ComputedEntry, GibbsComputedStructureEntry from pymatgen.io.cif import CifParser from pymatgen.io.vasp import Chgcar -from pymatgen.phonon.bandstructure import PhononBandStructureSymmLine -from pymatgen.phonon.dos import PhononDos +from emmet.core.phonon import PhononDOS, PhononBS from mp_api.client import MPRester from mp_api.client.core.client import MPRestError @@ -291,10 +290,10 @@ def test_get_ion_entries(self, mpr): def test_get_phonon_data_by_material_id(self, mpr): bs = mpr.get_phonon_bandstructure_by_material_id("mp-2172") - assert isinstance(bs, PhononBandStructureSymmLine) + assert isinstance(bs, PhononBS) dos = mpr.get_phonon_dos_by_material_id("mp-2172") - assert isinstance(dos, PhononDos) + assert isinstance(dos, PhononDOS) def test_get_charge_density_from_material_id(self, mpr): chgcar = mpr.get_charge_density_from_material_id("mp-149")