Skip to content

Conversation

@mikekeke
Copy link
Collaborator

@mikekeke mikekeke commented Nov 1, 2022

With this PR BPI will try to create collateral before any user contract is executed, instead making it during transaction balancing.
If creation fails - contract execution will be aborted.

This behavior should fix the following possible scenario:

  1. user calls utxosAt in the contract (first contract executed with BPI in current session)
  2. gets 1st UTxO from the result of utxosAt and uses it as transaction input
  3. submits unbalanced or balances transaction
  4. transaction fails because UTxO used as input could be consumed during collateral creation, which happens during balancing

@mikekeke mikekeke merged commit cd192e5 into master Nov 4, 2022
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