Install & Compatibility
Where this runs
tested against v2.1.1 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 1.348s · 39.1MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 3.4s · import 1.198s · 40MB
38MB installed
● package 38MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
connect
✓ import gwdatafind
✗ from gwdatafind import connect
Since v2.0, connect is a function in the top-level namespace. Using old import will raise AttributeError.
DataFindAPI
✓ import gwdatafind
✗ from gwdatafind import DataFindAPI
DataFindAPI was removed in v2.0; use the connect function instead.
This example connects to the GWDataFind server, finds frame URLs for LIGO Hanford around the first GW detection, and lists available data types. No authentication required for public data.
import os
import gwdatafind
# Set token if available (optional for public data)
os.environ.get('IGWN_AUTH_TOKEN', '')
# Connect to the default LIGO/Virgo archive
connection = gwdatafind.connect()
# Find all frames for a specific observatory and GPS time
frames = connection.find_frames('H1', 1126257414, 1126257416)
for frame in frames:
print(frame.url)
# Find specific types of data (e.g., trend data)
trends = connection.find_types('H1', 'H1_TREND')
print(trends)
Errors
Common errors & fixes
AttributeError: module 'gwdatafind' has no attribute 'DataFindAPI'
Code using the older v1.x API with v2.x installed.
fixUse `import gwdatafind` and call `gwdatafind.connect()` instead.
gwdatafind.exceptions.AuthenticationError: No authentication token found
Connecting to a protected endpoint without setting IGWN_AUTH_TOKEN.
fixSet the IGWN_AUTH_TOKEN environment variable or install ligo-auth-tokens and run `ligo-token`.
TypeError: connect() got an unexpected keyword argument 'host'
The `host` parameter was removed in v2.0; use `service` to specify the service endpoint.
fixUse `gwdatafind.connect(service='https://datafind.ligo.org:443')` instead of `host=`.
Upgrade
Version history
2.1.1latest on PyPI · released Oct 31, 2025
Audit
Dependencies
ligo-auth-tokensoptionalAuthentication for protected data endpoints
igwn-auth-utilsoptionalAlternative authentication using IGWN SciToken