delvtech / agent0

Analysis & simulation repo for Delv
https://agent0.readthedocs.io/en/latest/
Apache License 2.0
45 stars 18 forks source link

Connect existing postgres #1504

Closed slundqui closed 1 month ago

slundqui commented 1 month ago

This PR allows the agent0 pipeline to connect to an existing postgres resource instead of managing it's own container.

NOTE: actual implementation of this in the infra repo is blocked by registry updates to query registered pools (https://github.com/delvtech/hyperdrive/pull/1039). Currently, we use events to get registered pools, but since infra uses anvil's save/load state, register events get lost. Need follow up after the hyperdrive registry update to get list of registered pools from contract call.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 65.78947% with 13 lines in your changes are missing coverage. Please review.

Project coverage is 81.09%. Comparing base (2f053b4) to head (aaa08ba).

:exclamation: Current head aaa08ba differs from pull request most recent head 64ddf86

Please upload reports for the commit 64ddf86 to get more accurate results.

Files Patch % Lines
src/agent0/chainsync/exec/acquire_data.py 28.57% 5 Missing :warning:
src/agent0/chainsync/exec/analyze_data.py 0.00% 2 Missing :warning:
src/agent0/core/hyperdrive/interactive/chain.py 90.00% 2 Missing :warning:
src/agent0/ethpy/hyperdrive/addresses.py 33.33% 2 Missing :warning:
src/agent0/chainsync/db/base/interface.py 50.00% 1 Missing :warning:
src/agent0/chainsync/postgres_config.py 66.66% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1504 +/- ## ========================================== + Coverage 80.92% 81.09% +0.16% ========================================== Files 97 97 Lines 6806 6819 +13 ========================================== + Hits 5508 5530 +22 + Misses 1298 1289 -9 ``` | [Flag](https://app.codecov.io/gh/delvtech/agent0/pull/1504/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=delvtech) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/delvtech/agent0/pull/1504/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=delvtech) | `81.09% <65.78%> (+0.16%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=delvtech#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.