Add InfluxDB importer - #170
Conversation
There was a problem hiding this comment.
Pull request overview
Adds InfluxDB 3 as an import source across configuration, querying, CLI, tests, and documentation.
Changes:
- Adds InfluxDB connection and test configuration.
- Imports and normalizes Arrow query results.
- Adds dependencies, tests, CLI snapshots, and documentation.
Reviewed changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
uv.lock |
Locks InfluxDB client dependencies. |
pyproject.toml |
Adds the InfluxDB client dependency. |
otava/influxdb.py |
Implements the client wrapper. |
otava/importer.py |
Adds InfluxDB result importing. |
otava/config.py |
Wires connection configuration into the CLI. |
otava/test_config.py |
Parses InfluxDB test definitions. |
tests/influxdb_test.py |
Tests configuration and importing. |
tests/cli_help_test.py |
Updates CLI help snapshots. |
README.md |
Lists InfluxDB support. |
docs/README.md |
Links the InfluxDB guide. |
docs/INFLUXDB.md |
Documents InfluxDB usage. |
examples/influxdb/otava.yaml |
Provides an example configuration. |
Suppressed comments (1)
otava/importer.py:885
- InfluxDB 3 returns its Arrow
timecolumn as a timezone-less timestamp, andto_pylist()therefore yields a naive datetime.DataSelectorboundaries are timezone-aware, so this comparison raisesTypeError: can't compare offset-naive and offset-aware datetimesfor real query results. Normalize naive InfluxDB timestamps as UTC before filtering and converting to epoch seconds; the test currently constructs a timezone-aware Arrow schema and misses this production shape.
timestamp = row[time_index]
if timestamp < since_time or timestamp >= until_time:
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Gerrrr
left a comment
There was a problem hiding this comment.
Thanks for the contribution! This PR looks good overall, but needs a few changes to get ready for merge. Please also rebase against latest master - I had to update dependencies to fix CI.
a53da17 to
0e5b49f
Compare
|
@Gerrrr thanks for the comments, just now seeing your add'l notes. i'll update the PR with changes to account for those |
|
Follow-up commits 8757974 and 61dc2d6 are pushed. Local validation is green (204 tests, including the new authenticated InfluxDB SQL/InfluxQL E2E test; Ruff, Autoflake, isort, Flake8, license hooks, Compose config, and the Docker build/example workflow). Whenever is convenient, a maintainer would need to re-approve/run the Python 3.10–3.14 matrix and dependent docker-build job. The prior 3.14 failure was the version-specific |
Gerrrr
left a comment
There was a problem hiding this comment.
2 more minor changes + fix rebase conflict and it will be ready to merge.
61dc2d6 to
7c47ab5
Compare
|
Rebased onto 19882e9 and addressed the two latest review comments in 7c47ab5. Local validation is green: 220 tests (including the public-CLI SQL/InfluxQL Docker E2E), all configured lint/license checks, Compose config/build/example and seed idempotence, plus locked installs on Python 3.10–3.14. The refreshed Python application workflow is awaiting maintainer approval at https://github.com/apache/otava/actions/runs/32744967567; @Gerrrr, when convenient, please approve it so the Python matrix and dependent docker-build job can run. |
Add InfluxDB 3 configuration, query importing, Arrow result normalization, tests,
documentation, and CLI help snapshots.