-
Notifications
You must be signed in to change notification settings - Fork 2
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
Feat/dex router #212
base: main
Are you sure you want to change the base?
Feat/dex router #212
Conversation
scripts/dex-router/src/index.ts
Outdated
).filter((acc) => acc !== null); | ||
|
||
return addressLookupTableAccountInfos.map((accountInfo, index) => { | ||
const addressLookupTableAddress = keys[index]; |
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.
the order might not be right if we filtered out a null account. we should do the filtering here and probbably also log it or even throw an error if the lookup table doesn't exist
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.
agreed on the indexing. but probably not throw an error since the tx should be valid without it. will throw a warning
|
||
const { | ||
tokenLedgerInstruction, | ||
computeBudgetInstructions, |
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.
don't you want to actually use them for now?
|
||
export class JupiterRouter implements Router { | ||
private chainId: string; | ||
private connection: Connection; |
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.
not used
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.
i designed the interface this way bc for other routers we may need to pass in a connection. for now i can remove it
This PR adds a script to route limit orders to on-chain liquidity