Skip to content

Conversation

@pxrl
Copy link
Collaborator

@pxrl pxrl commented Jul 18, 2024

The ProfitClient currently assumes that the value of a fill can be determined from the input token price * the output amount of the output token. This is roughly correct for most Across deposits, but falls over when the deposit includes an in-protocol swap to an output token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken AERO on Base.

Deposit hash:
0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
Copy link
Member

@nicholaspai nicholaspai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pxrl pxrl merged commit c27ebd4 into master Jul 22, 2024
@pxrl pxrl deleted the pxrl/profitUSD branch July 22, 2024 20:09
ishantiw pushed a commit to LiskHQ/across-relayer that referenced this pull request Aug 8, 2024
)

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
ishantiw pushed a commit to LiskHQ/across-relayer that referenced this pull request Aug 8, 2024
)

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
sameersubudhi pushed a commit to LiskHQ/across-relayer that referenced this pull request Sep 10, 2024
)

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
sameersubudhi pushed a commit to LiskHQ/across-relayer that referenced this pull request Sep 10, 2024
)

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
sameersubudhi pushed a commit to LiskHQ/across-relayer that referenced this pull request Sep 10, 2024
)

The ProfitClient currently assumes that the value of a fill can be
determined from the input token price * the output amount of the
output token. This is roughly correct for most Across deposits, but
falls over when the deposit includes an in-protocol swap to an output
token with a different number of decimals.

This was exposed on an Optimism deposit for inputToken USDC, outputToken
AERO on Base.

Deposit hash:
  0x4a3febcfb764467d9eae261b3a3938137db383289fe328050a2871eb407e1147
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants