-
Notifications
You must be signed in to change notification settings - Fork 362
Feature: Single tx safe apps interactions should not use multisend #1792
Conversation
CLA Assistant Lite All Contributors have signed the CLA. |
I wonder, is there anywhere, where we assume all Safe App txs to be Multisend? For example, I thought in our Dune Dashboards we approximate Safe App interactions by querying Multisend txs to a given smart contract (@tschubotz knows for sure). Maybe there are other places as well (tx list, backend, tx review modal, etc.) where this assumption is made? |
ESLint Summary View Full Report
Report generated by eslint-plus-action |
Travis automatic deployment: |
Travis automatic deployment: |
Yes, but these dashboards aren't super accurate anyway. + I think a single tx instead of a multisend is better UX and cheaper. I think we should find other ways of tracking then. Generally I'm in favor of this feature, I can't tell if this interferes with how the frontend/backend marks Safe app txs though. |
@tschubotz @lukasschor I tested it and didn't find any quirks, everything works smoothly. Disclaimer: currently there's a bug in gas calculations for safe apps transactions and they're failing, but everything app/tx decoding related shows as expected |
Travis automatic deployment: |
Travis automatic deployment: |
Travis automatic deployment: |
Travis automatic deployment: |
@francovenica you should check that you can execute transactions in safe apps normally |
Travis automatic deployment: |
Travis automatic deployment: |
I have a problem with a particular tx I want to create in the Tx builder. It fails only in this PR, since I gave it a try in rinkeby prod and the tx works fine there. My tx wants to send rinkeby DAI tokens to an account. DAI address: 0x5592EC0cfb4dbc12D3aB100b257153436a1f0FEa When I queue the 2 tx in the Tx builder and send it then it works just fine. But if I just queue 1 tx and send it then it always fail. Safe and env: https://rinkeby.gnosis-safe.io/app/#/safes/0x9913B9180C20C6b0F21B6480c84422F6ebc4B808/transactions Snapshots: In this one I did 1 transfer in the tx builder and failed. The tx above that one is the same case NOTE: The "Contract interaction" Tx is also a Tx builder type of tx, using the transfer method to 1 account. The reason is seen as "Contract interaction" and not as "tx builder" is because that one was done in the rinkeby prod env, and Richard told me that if you see those type of tx in another environment the label gets confused. If none of this has to do with this ticket then let me know. I tried other tx and the main idea of showing no "action" label when only 1 tx is being sent is working fine. |
Another example with the IDLE app. A withdrawal of tokens, the failed one below (on Jan 26, 2021 - 16:27:55) was done in this PR and the successful one was done in rinkeby prod (highlighted in the snapshot) Tx hashes for etherscan: |
@@ -110,7 +111,7 @@ export const ConfirmTransactionModal = ({ | |||
gasCostFormatted, | |||
txEstimationExecutionStatus, | |||
} = useEstimateTransactionGas({ | |||
txData: encodeMultiSendCall(txs), | |||
txData: txData || '', | |||
txRecipient: MULTI_SEND_ADDRESS, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The receipient needs to change. currently the tx is always sent to the multisend address, which is wrong
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤦♂️ 🤦♂️ 🤦♂️ 🤦♂️ 🤦♂️
@@ -137,8 +138,6 @@ export const ConfirmTransactionModal = ({ | |||
} | |||
|
|||
const confirmTransactions = async () => { | |||
const txData = encodeMultiSendCall(txs) | |||
|
|||
await dispatch( | |||
createTransaction( | |||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For to
and operation
here we need to make the same changes as mentined above
@@ -110,7 +111,7 @@ export const ConfirmTransactionModal = ({ | |||
gasCostFormatted, | |||
txEstimationExecutionStatus, | |||
} = useEstimateTransactionGas({ | |||
txData: encodeMultiSendCall(txs), | |||
txData: txData || '', | |||
txRecipient: MULTI_SEND_ADDRESS, | |||
operation: DELEGATE_CALL, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The opration should be a CALL for single transactions
…re/no-multisend-for-1-tx
Travis automatic deployment: |
Travis automatic deployment: |
Travis automatic deployment: |
Travis automatic deployment: |
The issues I've reported were fixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only minor thing might be that we should do nothing for an empty array of transactions, but that is maybe a different issue (as it existed before)
Travis automatic deployment: |
Travis automatic deployment: |
This PR:
encodeMultiSendCall
iftxs.length
is 1