Skip to content
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

price in price bar should be the execution price, not price of 1 base #2648

Open
moodysalem opened this issue Oct 19, 2021 · 5 comments
Open
Labels
bug Something isn't working good first issue Good for newcomers p1 Great to have, implement first thing after p0s

Comments

@moodysalem
Copy link
Contributor

moodysalem commented Oct 19, 2021

image
example on arbitrum, selling 35k eth but it says 1 eth = 3800 dai even though there's huge price impact

e.g. here it should say something like 1 ETH = 3.206 DAI ($3.21)

@moodysalem moodysalem added bug Something isn't working p1 Great to have, implement first thing after p0s labels Oct 19, 2021
@justindomingue justindomingue added the good first issue Good for newcomers label Oct 20, 2021
@prakashsanker
Copy link

@justindomingue I'm taking this while waiting on reviews from you for the other two open PRs.

@prakashsanker
Copy link

@moodysalem I'm quite confused by your description. Isn't the screenshot doing exactly what you want it to?

@justindomingue
Copy link
Contributor

@prakashsanker @GruDev325 is right. The execution price 1 ETH = 3.206 DAI includes price impact of 99.9%. However, the $ value of the execution price does not take that price impact into account.

That's because we useUSDPrice(baseToken=EDH)=3000$ instead of useUSDPrice(quoteToken=DAI)=3$

NickEU pushed a commit to NickEU/interface that referenced this issue Apr 2, 2022
…ts and Currency/Token classes for a proper one
davarg5 pushed a commit to davarg5/uniswap-interface that referenced this issue Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers p1 Great to have, implement first thing after p0s
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants
@justindomingue @prakashsanker @moodysalem and others