Skip to content

Instantly share code, notes, and snippets.

@Danpi3141
Danpi3141 / get hyUSD_supply.py
Created March 13, 2024 22:48
get hyUSD_supply.py
from web3 import Web3
import matplotlib.pyplot as plt
import pandas as pd
# Initialize Web3
w3 = Web3(Web3.HTTPProvider("https://eth.llamarpc.com"))
# Load your contract
contract_address = "0xaCdf0DBA4B9839b96221a8487e9ca660a48212be"
contract = w3.eth.contract(address=contract_address, abi='[{"inputs":[],"name":"UIntOutOfBounds","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint192","name":"oldBasketsNeeded","type":"uint192"},{"indexed":false,"internalType":"uint192",
from web3 import Web3
import matplotlib.pyplot as plt
import pandas as pd
# Initialize Web3
w3 = Web3(Web3.HTTPProvider("https://eth.llamarpc.com"))
# Load your contract
contract_address = "0xaCdf0DBA4B9839b96221a8487e9ca660a48212be"
contract = w3.eth.contract(address=contract_address, abi='[{"inputs":[],"name":"UIntOutOfBounds","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint192","name":"oldBasketsNeeded","type":"uint192"},{"indexed":false,"internalType":"uint192",
@Danpi3141
Danpi3141 / ethplus.py
Created March 13, 2024 22:40
Get balance of Ethplus overtime
from web3 import Web3
import json
import matplotlib.pyplot as plt
import pandas as pd
# Initialize Web3
w3 = Web3(Web3.HTTPProvider("https://eth.llamarpc.com"))
contract_address = "0xE72B141DF173b999AE7c1aDcbF60Cc9833Ce56a8"
contract = w3.eth.contract(address=contract_address, abi='[{"inputs":[],"name":"UIntOutOfBounds","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint192","name":"oldBasketsNeeded","type":"uint192"},{"indexed":false,"internalType":"uint192","name":"n
from web3 import Web3
import json
import matplotlib.pyplot as plt
import pandas as pd
# Initialize Web3
w3 = Web3(Web3.HTTPProvider("https://eth.llamarpc.com"))
# Load your contract
contract_address = "0x7fb53345f1B21aB5d9510ADB38F7d3590BE6364b"
@Danpi3141
Danpi3141 / keybase.md
Created October 23, 2020 17:28
keybase.md

Keybase proof

I hereby claim:

  • I am Danpi3141 on github.
  • I am danpi314 (https://keybase.io/danpi314) on keybase.
  • I have a public key whose fingerprint is C29C 9564 D999 4358 0037 16B5 1166 AB7B 6FD6 5413

To claim this, I am signing this object: