Skip to content

Fix transaction building process and update SC invocation methods#11

Merged
itsMarcoSolis merged 1 commit intomainfrom
fix/sc-rpc-building
Aug 7, 2024
Merged

Fix transaction building process and update SC invocation methods#11
itsMarcoSolis merged 1 commit intomainfrom
fix/sc-rpc-building

Conversation

@itsMarcoSolis
Copy link
Copy Markdown
Member

Description

This PR addresses several issues related to the transaction building process and smart contract invocation methods. The main changes include:

Summary of Changes

  • AddLiquiditySection:

    • Updated to use gasEstimateSCArgs for accurate gas estimation.
    • Adjusted asset and Dero amount calculations to prevent rounding errors.
    • Added destination parameter in the transfer method to comply with RPC syntax.
  • CreatePairModalContent:

    • Updated to use gasEstimateSCArgs.
    • Fixed transaction parameters to ensure correct functionality.
  • RemoveLiquiditySection:

    • Modified to use gasEstimateSCArgs for smart contract invocation.
    • Ensured accurate parameter passing for the RemoveLiquidity entrypoint.
  • SwapForm:

    • Corrected SVG attributes (strokeWidth, strokeLinecap, strokeLinejoin) for proper rendering.

Rationale

These changes enhance the reliability and accuracy of the transaction building process. By using gasEstimateSCArgs, we ensure that gas estimations are precise, preventing potential transaction failures due to incorrect gas calculations. This change also fixes an issue where the transfer call would be sent without the proper SC_ACTION and SC_ID RPC arguments.

Testing

  • Verified that transactions are correctly built and sent using the updated methods.
  • Ensured that the application correctly handles the addition and removal of liquidity.

Related Issues

  • Fixes issues related to transaction building inaccuracies and incorrect smart contract invocation parameters.

@itsMarcoSolis itsMarcoSolis merged commit 68e0105 into main Aug 7, 2024
@itsMarcoSolis itsMarcoSolis deleted the fix/sc-rpc-building branch August 11, 2024 04:20
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.

1 participant