Skip to content

Take gas fee into account for cross chain trade #3377

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

Merged

Conversation

Kailai-Wang
Copy link
Collaborator

Context

As topic - we should call pumpx api with adjusted amount_in.

@Kailai-Wang Kailai-Wang requested review from kziemianek, silva-fj and a team April 13, 2025 20:21
@Kailai-Wang Kailai-Wang self-assigned this Apr 13, 2025
Copy link

linear bot commented Apr 13, 2025

Copy link
Member

@kziemianek kziemianek left a comment

Choose a reason for hiding this comment

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

Is it ok that full amount is paid out by accounting contract ?
Shouldn't it take gas fee into amount?

@Kailai-Wang
Copy link
Collaborator Author

Is it ok that full amount is paid out by accounting contract ?
Shouldn't it take gas fee into amount?

@kziemianek The accounting contract is triggered by worker, so the worker will pay gas.
The gas will be considered when using pumpx : )

The only exception is the swap process errors out after paying out but before calling pumpx. In that case, yes we'll lose the gas fee we paid, but we consider the fee minimal and case is rare, so we live with it in the first version

@Kailai-Wang Kailai-Wang enabled auto-merge (squash) April 14, 2025 08:27
@Kailai-Wang Kailai-Wang merged commit 8f3656c into dev Apr 14, 2025
21 checks passed
@Kailai-Wang Kailai-Wang deleted the p-1460-take-gas-fee-into-account-for-cross-chain-trade branch April 14, 2025 09:11
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