This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ghcr.io/foundry-rs/foundry | |
WORKDIR /app | |
ENV INFURA_URL="" | |
ENV ALCHEMY_URL="" | |
CMD ["sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from eth_bloom import BloomFilter | |
def check_bloom(): | |
logs_bloom = "0x123..." | |
logs_bloom_bytes = int(logs_bloom, 16) | |
topic = "0x321..." | |
topic_bytes = bytes.fromhex(topic[2:]) | |
filter = BloomFilter(logs_bloom_bytes) |