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.1.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.1-cp312-cp312-win_amd64.whl (488.5 kB view details)

Uploaded CPython 3.12Windows x86-64

yearn_treasury-0.2.1-cp312-cp312-win32.whl (446.4 kB view details)

Uploaded CPython 3.12Windows x86

yearn_treasury-0.2.1-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.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (725.3 kB view details)

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

yearn_treasury-0.2.1-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.1-cp312-cp312-macosx_11_0_arm64.whl (466.9 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

yearn_treasury-0.2.1-cp311-cp311-win_amd64.whl (486.8 kB view details)

Uploaded CPython 3.11Windows x86-64

yearn_treasury-0.2.1-cp311-cp311-win32.whl (443.0 kB view details)

Uploaded CPython 3.11Windows x86

yearn_treasury-0.2.1-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.1-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.1-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.1-cp311-cp311-macosx_11_0_arm64.whl (467.4 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

yearn_treasury-0.2.1-cp310-cp310-win_amd64.whl (487.3 kB view details)

Uploaded CPython 3.10Windows x86-64

yearn_treasury-0.2.1-cp310-cp310-win32.whl (444.3 kB view details)

Uploaded CPython 3.10Windows x86

yearn_treasury-0.2.1-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.1-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.1-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.1-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.1.tar.gz.

File metadata

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

File hashes

Hashes for yearn_treasury-0.2.1.tar.gz
Algorithm Hash digest
SHA256 7a7fbbef290e78f63b7308465bcd9c38b12532bb52b82dcf7d6ef5eb65c39ca2
MD5 4948483200075f5a3527b0221bb5911d
BLAKE2b-256 3d575a933843cfcf9caeb0860865f59fa65255343c654d0e757b2ed41d2e5a01

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 a447ff09e52eff67cd9e18d075fd528c41ded31f2d3e1a8b1ebe94bdeee81c88
MD5 c1cb7edb52a00b715e5f837b26a32566
BLAKE2b-256 157c57b5b22eb516f4a8f54a767237a603f8c1590ce706a2c16b44f02831d101

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for yearn_treasury-0.2.1-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 fb0afb390b71166666ef9191ee7fb37824bb85cde15f1315eec98bd4aade4c71
MD5 41510a94d74ae3992f90f9802aff1cef
BLAKE2b-256 f0ef9c2e156c597cde94d92f8b912663ac4d57dd4f3e0f4da5935d43e9da78af

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 5be46d5cff951b4252cbbc3ae599b6cb26b2f244d2224c5923b45f09d7b3a936
MD5 428ade52c751540c574dcc2732e3f9c1
BLAKE2b-256 664578a9572e181fea2db2364c29613b39665d5537e7231ad385d39754c68bdd

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.1-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.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 1fed78944f503ff810b8d2e2e4b3c3a512618808de3263daf94b92c5ab367b43
MD5 04e99d02192ab1ce132d5bc5fc334343
BLAKE2b-256 b72de7c8379353977637293f2b865a972fc11988f0e6f6d993fd74c8b2a929e2

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 3996e7d4c51c1916d1faf78b15222da528b8725ea49c676d7b90b59a31f78ea9
MD5 25d6cfc1287725deaa55035381c4b554
BLAKE2b-256 45e88b638a2cfe4144306e2e00d7a93ec334add34487aebf523344bdd4215dc7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 d153756028ce56945937f4786e467922949399e143f8838d5290ca896347d57c
MD5 dfd867a9056b4b60502d4a9fa0f8addf
BLAKE2b-256 7e888c08766397cdbbc20c30881017908bc5a0e6aa7b3ed72a263f114f45929f

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 ac9aa830224a0f016673385746eb30cd4f914d5079ff9d6003bfec817e2bee53
MD5 57722f1c26d2413c473fe73c081473f3
BLAKE2b-256 1f48a3ff2caea879373c755f9b5eeb622f4d18a8c5e7dfcc43d694a7f1056ab3

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for yearn_treasury-0.2.1-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 7c72ea1dedb2ba299e3bd0cb873a57da2e5876593715159793f8397a54692f15
MD5 104fbaf5ee9d898a1e80da79ba0c8326
BLAKE2b-256 7e8cec8d612a359015e51eb4dcd0ea676e9bd58f45a5e017cb9525d1925aeb3a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 a6a719989483027d3fb508b6b23059dac31cdfa7ce13097115214a816a5bf163
MD5 f910e0aadb3c0840f85c526c93c03f64
BLAKE2b-256 86ddd91f87f5d362d1e3337eef7196ff1ee60f0b6caf370b4301b52912d9b268

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.1-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.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 a79b38f0ed9892dc42cbb809a52249f357d6d461c7d6da1014f91ee9e4e5dac5
MD5 358640adcfc0fdf9272e7462af5a41b3
BLAKE2b-256 9f1ceec538883843830dc62b2df924e4e1b238ecba2e864bcd7e9e0d1eabf654

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 9bac17fd6a8263a788486a4f94efec7fdb7e3d849ef4d05c0aec5a10775ff1b3
MD5 d86a008f6a24ecb2b608b8ec1d4f2576
BLAKE2b-256 9630d64f5dade47b91340c05997f8d41c4454d8ace79a3164fb637148ff43a25

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8f4f3d5164e7884b418ee9cc1d60e443110a111e0ca66878d033231004c8cd9a
MD5 fe31de90d1857692001dda683ddad6bc
BLAKE2b-256 366f5859740e19b7533738ff96535d963c3190939c7bff0651b43dc90c86363a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 cd23cb20320b9a4b18847315e3877ec633c25a204a7f4bcfbfc75ae7d484b2fc
MD5 5d3b9f1a81800257397aff4af8867282
BLAKE2b-256 9c515d48a58b2c942ba937ea54a268fac3ded7b659e02fad1791b187d3dfde5d

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for yearn_treasury-0.2.1-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 e616c8a8b579db598e554c721bfecea88676602ddfdfec83f3add1c8ab7d1545
MD5 443c08abfe92b17068a7e2a64d6e5fc9
BLAKE2b-256 42a6bfbb8619fd6522c58ca778c94e46dc606b1ceda0ae4d8479816e0e85c262

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 22fa551314edf83a2596cad5c13dd2ca0f1ec174b6bb60a4f43a324cd44eca8e
MD5 988e97890a64d26aab4827716db1a0a8
BLAKE2b-256 3651485aec6e287f65953041dbbc9fe08091c312697d55d7ee2fd770f002383b

See more details on using hashes here.

File details

Details for the file yearn_treasury-0.2.1-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.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 afdb2c88a8012a431702be294f29d1066311f86d7b05236b376d87bb6dbc3ee0
MD5 29a95bae884b68a894debcb744f35f61
BLAKE2b-256 eeb8d475af7b8276564f29b50e1716fc5d4236fddda6c6ffa2717cb656d21b7d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 5254f6ae4496013101960abb632ae4f2d6b53589a231a20ecaf26c150db1fa08
MD5 2dd2a369bd6a8af8107008e82b772566
BLAKE2b-256 e39c22ff0d1315913b643760a4a78e7ff2a47cbf05523a2ec4867037a3fd5339

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for yearn_treasury-0.2.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 96b3ad579147b978bfb63d2225ad957aadcaa81b4263d98aa1aaf9e14d840db3
MD5 820c3ab5450fccc4f64fae2acaa3dfe7
BLAKE2b-256 25a0c6774a3d49fc69ceb4d9984a5324b3844000faafddad34db88f9ac12bc35

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