From 2b968a62eeff45a4ecc5a07671007a6daa0a8270 Mon Sep 17 00:00:00 2001
From: bgeels <bgeels@usgs.gov>
Date: Tue, 2 Apr 2024 07:21:44 -0600
Subject: [PATCH] Revert "Exclude invalid entries in
 get_instrument_calibrations"

This reverts commit 86e257d3f4fba5d5bacd11515f9c8e3ccc7f3552.
---
 .../metadata/instrument/InstrumentCalibrations.py     | 11 +----------
 1 file changed, 1 insertion(+), 10 deletions(-)

diff --git a/geomagio/metadata/instrument/InstrumentCalibrations.py b/geomagio/metadata/instrument/InstrumentCalibrations.py
index 330ab8e8..d3f52a9a 100644
--- a/geomagio/metadata/instrument/InstrumentCalibrations.py
+++ b/geomagio/metadata/instrument/InstrumentCalibrations.py
@@ -2,8 +2,6 @@ from obspy import UTCDateTime
 
 from geomagio.metadata import Metadata, MetadataFactory, MetadataCategory
 
-# REMOVE ANY INSTRUMENT METADATA ELEMENTS W/ "DATA_VALID=FALSE"
-
 
 class InstrumentCalibrations:
     """
@@ -307,8 +305,7 @@ def get_instrument_calibrations(
       observatory: observatory code
       start_time: start time to match, or None to match any.
       end_time: end time to match, or None to match any.
-      calibrations: use custom list, defaults to pulling and converting instrument metadata
-      metadata_url: metadata database url
+      calibrations: use custom list, defaults to pulling and converting metadata
     Returns:
       list of applicable instrument calibrations
     """
@@ -324,12 +321,6 @@ def get_instrument_calibrations(
             station=observatory,
         )
         metadata = factory.get_metadata(query=query)
-
-        # remove invalid metadata entries
-        for i, m in enumerate(metadata):
-            if not m.data_valid:
-                metadata.pop(i)
-
         instrumentCalibrations = InstrumentCalibrations(metadata)
         calibrations = instrumentCalibrations.get_calibrations()
 
-- 
GitLab