-
Notifications
You must be signed in to change notification settings - Fork 3
Add latest position blocks to portfolio queries #1846
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
} catch (e) { | ||
console.error( | ||
`Error fetching longs for ${hyperdrive.address}:`, | ||
e, | ||
); | ||
return { | ||
hyperdrive, | ||
openLongs: [], | ||
}; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This prevents the entire query from failing when one of the chains fails.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
out of curiosity, why do long, short and lp have different latest position blocks? did you actually find the latest ones for each chain?
Partial patch to the portfolio queries which limits the "toBlock" of event queries for the longs and shorts. Some of the queries are still failing and will need to be broken up into smaller queries, but this gets us half way there so at least some positions will show up.