Skip to main content

This WIP library runs the eth-portfolio and dao-treasury exporters for the Yearn Finance treasury.

Project description

This WIP library runs the dao-treasury exporter for the Yearn Finance treasury.

Installation

  • pip:

     pip install yearn-treasury
    
  • From Source:

    git clone https://github.com/BobTheBuidler/yearn-treasury
    cd yearn-treasury
    poetry install
    

Requirements

  • Python 3.10 or higher.
  • At least 16GB of RAM.
  • All dependencies installed as specified in the project’s pyproject.toml file.

Prerequisites

  • First, you will need to bring your own archive node. This can be one you run yourself, or one from one of the common providers (Tenderly, Alchemy, QuickNode, etc.). Your archive node must have tracing enabled (free-tier Alchemy nodes do not support this option).
  • You must configure a brownie network to use your RPC.
  • You will need an auth token for Etherscan's API. Follow their guide to get your key, and set env var ETHERSCAN_TOKEN with its value.
  • You'll also need Docker installed on your system. If on MacOS, you will need to leave Docker Desktop open while Yearn Treasury is running.

Usage

Run the treasury export tool:

# For pip installations:
GF_SECURITY_ADMIN_USER=admin GF_SECURITY_ADMIN_PASSWORD=... yearn-treasury --network mainnet --interval 12h

For local development (from source installation), use:

GF_SECURITY_ADMIN_USER=admin GF_SECURITY_ADMIN_PASSWORD=... poetry run yearn-treasury --network mainnet --interval 12h

CLI Options:

  • --network: The id of the brownie network the exporter will connect to (default: mainnet)
  • --interval: The time interval between each data snapshot (default: 12h)
  • --daemon: Run the export process in the background (default: False) (NOTE: currently unsupported)
  • --grafana-port: Set the port for the Grafana dashboard where you can view data (default: 3004)
  • --renderer-port: Set the port for the report rendering service (default: 8080)
  • --victoria-port: Set the port for the Victoria metrics reporting endpoint (default: 8430)

Grafana Auth:

  • Requires GF_SECURITY_ADMIN_USER and GF_SECURITY_ADMIN_PASSWORD.
  • Optional anonymous access via DAO_TREASURY_GRAFANA_ANON_ENABLED=true.

After running the command, the export script will run continuously until you close your terminal. To access the dashboard, open your browser and navigate to http://localhost:3004 for the dao-treasury dashboard and log in with your Grafana admin credentials.

Enjoy!

Screenshots

Transactions Dashboard

image

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yearn_treasury-0.2.2.tar.gz (63.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

yearn_treasury-0.2.2-cp312-cp312-win_amd64.whl (488.4 kB view details)

Uploaded CPython 3.12Windows x86-64

yearn_treasury-0.2.2-cp312-cp312-win32.whl (446.5 kB view details)

Uploaded CPython 3.12Windows x86

yearn_treasury-0.2.2-cp312-cp312-musllinux_1_2_x86_64.whl (726.1 kB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

yearn_treasury-0.2.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (725.2 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

yearn_treasury-0.2.2-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (754.7 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

yearn_treasury-0.2.2-cp312-cp312-macosx_11_0_arm64.whl (466.9 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

yearn_treasury-0.2.2-cp311-cp311-win_amd64.whl (486.9 kB view details)

Uploaded CPython 3.11Windows x86-64

yearn_treasury-0.2.2-cp311-cp311-win32.whl (443.5 kB view details)

Uploaded CPython 3.11Windows x86

yearn_treasury-0.2.2-cp311-cp311-musllinux_1_2_x86_64.whl (706.8 kB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

yearn_treasury-0.2.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (694.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

yearn_treasury-0.2.2-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (705.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

yearn_treasury-0.2.2-cp311-cp311-macosx_11_0_arm64.whl (467.4 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

yearn_treasury-0.2.2-cp310-cp310-win_amd64.whl (487.4 kB view details)

Uploaded CPython 3.10Windows x86-64

yearn_treasury-0.2.2-cp310-cp310-win32.whl (444.2 kB view details)

Uploaded CPython 3.10Windows x86

yearn_treasury-0.2.2-cp310-cp310-musllinux_1_2_x86_64.whl (727.1 kB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

yearn_treasury-0.2.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (713.8 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

yearn_treasury-0.2.2-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (724.4 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

yearn_treasury-0.2.2-cp310-cp310-macosx_11_0_arm64.whl (474.4 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file yearn_treasury-0.2.2.tar.gz.

File metadata

  • Download URL: yearn_treasury-0.2.2.tar.gz
  • Upload date:
  • Size: 63.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for yearn_treasury-0.2.2.tar.gz
Algorithm Hash digest
SHA256 adea9dcd8bb68abcef189600fae82cb5f67019f9e6c77c49eee719d5cac3248c
MD5 2faa8364563a3aeafedf5ea8b47a8744
BLAKE2b-256 cfdc988da61d5feb0389f090b6a176845d32bde969fd27abe79a25368ad6226b

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 a0552adc5c0f251436f1413ca437cc684916bf819c46a43a0e36bcfee3f43ca2
MD5 0e42275636de13ad101fa97e0856e4b2
BLAKE2b-256 44495667cf06e24b17b5c89a852d5da9cd3db4d13fe8a93f30df7895184c185e

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-win32.whl.

File metadata

  • Download URL: yearn_treasury-0.2.2-cp312-cp312-win32.whl
  • Upload date:
  • Size: 446.5 kB
  • Tags: CPython 3.12, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 fc4adfbd8356af355ddaabf7c8225447735ef61e5b12115a066a4cc285e86e61
MD5 a71f635422cab5bf17c0ae9e33c5f101
BLAKE2b-256 bacf56dad36e65d7481222a28ce818febc35b5621b90e154c97295820c19178a

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 d6268d472847c7fa37dd0eea4d9e258087ab02dfebcab1b4a02411f7bb0647fc
MD5 51f41bec2cee9e8d9e5fe14ad9b48b22
BLAKE2b-256 4ed6446dca1a5740e0b787d3ad8af126bb9db1863b79e268c1b342470bf58c0d

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 04bd4a7b4d9aed05c006deead8cc760624fe7bb06774f2d868a40366f1acc508
MD5 e0651d9c75b33f1d67d484becd662940
BLAKE2b-256 f173d370226e67277f68e8e966e49ae4f7213317960e4ba78bab4193ddc5b74d

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 349fb8c19a08144623fe3a9b893e79d053ab660f2bca7c1f95a523b2269ae213
MD5 87e5731f53188184496071b49431ccf8
BLAKE2b-256 b752ebdd1079e4f1130752e0ace4c8d599c934b20cfec2a48177f97e5a6003a8

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 fc6900224f0c073ad3e198b6dc1dc7ce392c9e1d666c45d154e335324d2b7ced
MD5 39dfa8a293c81dfe54e40e2012e6305e
BLAKE2b-256 42aba76f6b8b11b0ca25bc94009888373537a1c2f14c92f327fe7931eb04505f

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 0429284b9ce38fdca4a2ba1b55717dd13871fa4c62733e90293b85c27656798a
MD5 07ff3c86727023fa809f2435d1e0ecb2
BLAKE2b-256 722fc5035108cad72bc1170429abfd5fbc74b3005220859b5417ac6a72f65ede

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-win32.whl.

File metadata

  • Download URL: yearn_treasury-0.2.2-cp311-cp311-win32.whl
  • Upload date:
  • Size: 443.5 kB
  • Tags: CPython 3.11, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 62690b64a8503377d5c7c8f316454bb6703a859711e57a1396326d1ab4a76449
MD5 0ff92e6cf56e53bc892f96f9f22893da
BLAKE2b-256 b4f1f710f51501592404316ba6b2c39b8365f6b39533264d6fdae15307d4fd4d

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 e1861fb5ef682a386d0cbaec0992574b5c6c01d8c6b37968edfd2c28426ee765
MD5 fbeb61a2393f5af42d547b1edac8be19
BLAKE2b-256 a3dd697f13c6dda54e09a28898b5eefe6386a1f58d0cff6ebcd695cf9a7f9be6

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 774e1102faf1db268d2fc8573157923ef8f35bbe864e4f888216650436840fbb
MD5 fc10b170ad7d4f4e7eb669ea185ffb24
BLAKE2b-256 85e7c769605de06373ebfd0c737f85c00c86227a59775b2c323b423e5631b993

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 6409ce8cee5f835d537d655605d3f46a0072f8d1ffe81d715ad94a063ffabf32
MD5 54e9390692e128d174708a72806d4f3d
BLAKE2b-256 becd5ee4e784291bea8e298e8ed323be7b9a6090077095edd8eaf4e6753aebf7

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ec2e91e73a4ec2394cfb2dda6ee83f699eb5fc3265dc355dca3034a6854f72e3
MD5 290bb3682f719f84e0519fb7322e1525
BLAKE2b-256 f74a82daa7326591c36d25ffdab4418606e4fd01d218204bfe146b5a2d1df5f4

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 9963599eab2c4b3d66889c9df8136647419a9ffdaea1298181677a32f0b8db5a
MD5 cb1f49520e651ebc4a26c5d59559af43
BLAKE2b-256 60bbf12bf11fd437ef2cb1b2c89420afc3b5392533b10ab35077ca5d0f88c610

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-win32.whl.

File metadata

  • Download URL: yearn_treasury-0.2.2-cp310-cp310-win32.whl
  • Upload date:
  • Size: 444.2 kB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 034536bd173060d2fc638ecc5732b4b9224a0080822aa83364fdfc6f14e260a5
MD5 645efc665e6b2b4ec6a91833ea2dc6a2
BLAKE2b-256 7315207f8d8b912bd5105d1c9c9e429c1c5c2418feb9e2aa1c12567d05dbd0a5

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 0720ac662163a0ca29cb6d508acdbe34bf4241b757c4111ccaba96997159891e
MD5 0f057299bee52d809a2ff9556fc86d85
BLAKE2b-256 7958f0ec3a7c4d78a0a442da6e6934359b71e6a98a6466777d1819887dd8b356

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 070cdf026bbe628c9b48edc78a158a9685011b5e75d83de59d5bfaedb7d4b670
MD5 18f42e3b7a4bbeefa9668412b24f651c
BLAKE2b-256 3b993eeb62b47fce1e5fcaa7a9d9355146683211cac616a090f7bbde035b2702

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 e1762e445ac0ce9fa1f7b7d7f1755d3d7cf708f2aa1aec5cddc88aa83998107b
MD5 6d473ccd7b15720a6331ce67df8442c4
BLAKE2b-256 c5de334b627c27f392170acd9b94f337acd98c42c37e9cd150e6236f6e8cc2c6

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for yearn_treasury-0.2.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1484cc2876d775c82db2cfae5fe83df5c60cd0b58fba74189767a39e99b40a36
MD5 869350024f7d2f389b0e51ab2a084dcd
BLAKE2b-256 c43d472e0247674fb247699bb4a72060a4915efbfaf1aed045b83ba975aaa15a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page