Update argv parsing to account for topic id

This commit is contained in:
conache 2024-03-13 19:49:56 +02:00
parent 1953bd0c3c
commit 87b800286c
No known key found for this signature in database
2 changed files with 5 additions and 4 deletions

View File

@ -1,5 +1,4 @@
FROM --platform=linux/amd64 696230526504.dkr.ecr.us-east-1.amazonaws.com/allora-inference-base:latest
# FROM --platform=linux/amd64 allora-inference-base:dev
FROM --platform=linux/amd64 alloranetwork/allora-inference-base:latest
USER root
RUN pip install requests

View File

@ -15,8 +15,10 @@ def process(token_name):
if __name__ == "__main__":
# Your code logic with the parsed argument goes here
try:
if len(sys.argv) >= 2:
token_name = sys.argv[1]
if len(sys.argv) >= 3:
# Not using to discriminate by topicId for simplicity.
# topic_id = sys.argv[1]
token_name = sys.argv[2]
else:
token_name = "ETH"
process(token_name=token_name)