[Bug] EMALFORMED_METADATA_SIGNATURE onchain transaction errors
🐛 Bug
backend-worker_1 | [2021-03-03 19:57:14,626] [PID 262] [Thread-1] [dramatiq.worker.ConsumerThread(default)] [DEBUG] Pushing message 'eaec5a30-e055-49a2-96f4-72d10c223d8f' onto work queue.
backend-worker_1 | [2021-03-03 19:57:15,302] [PID 262] [Thread-3] [wallet-service:transaction] [ERROR] Error in _async_start_onchain_transfer
backend-worker_1 | Traceback (most recent call last):
backend-worker_1 | File "./wallet/services/transaction.py", line 415, in submit_onchain
backend-worker_1 | sender_sub_address=transaction.source_subaddress,
backend-worker_1 | File "./context/context.py", line 66, in p2p_by_general
backend-worker_1 | currency, amount, receiver_vasp_address, metadata, b""
backend-worker_1 | File "./context/context.py", line 93, in _p2p_transfer
backend-worker_1 | return self._submit_and_wait(txn)
backend-worker_1 | File "./context/context.py", line 99, in _submit_and_wait
backend-worker_1 | return self.jsonrpc_client.wait_for_transaction(txn, 30)
backend-worker_1 | File "/usr/local/lib/python3.7/site-packages/diem/jsonrpc/client.py", line 448, in wait_for_transaction
backend-worker_1 | timeout_secs,
backend-worker_1 | File "/usr/local/lib/python3.7/site-packages/diem/jsonrpc/client.py", line 483, in wait_for_transaction2
backend-worker_1 | raise TransactionExecutionFailed(f"VM status: {txn.vm_status}")
backend-worker_1 | diem.jsonrpc.client.TransactionExecutionFailed: VM status: type: "move_abort"
backend-worker_1 | location: "00000000000000000000000000000001::DualAttestation"
backend-worker_1 | abort_code: 775
backend-worker_1 | explanation {
backend-worker_1 | category: "INVALID_ARGUMENT"
backend-worker_1 | category_description: " An argument provided to an operation is invalid. Example: a signing key has the wrong format."
backend-worker_1 | reason: "EMALFORMED_METADATA_SIGNATURE"
backend-worker_1 | reason_description: " Cannot parse this as an ed25519 signature (e.g., != 64 bytes)"
backend-worker_1 | }
backend-worker_1 | [2021-03-03 19:57:15,308] [PID 262] [Thread-3] [root] [DEBUG] On Chain Transfer Failed: submit_onchain in ./wallet/services/transaction.py:404
Steps to reproduce
ran the MW testing framework, and saw this error across multiple tests
Can we get more context on this bug?
Yes absolutely- wasn't sure if this was enough or not. Will add dmw to makefile tomorrow so can easily replicate :-)
On latest master, this is replicable via the following DMW test: pipenv run dmw -- test --verbose=true --target http://127.0.0.1:3130 --pytest-args '-ktest_payment_meets_travel_rule_threshold[sender-valid_kyc_data-valid_kyc_data-exchange_states0-completed]'
and the documentation to run above is at:
https://github.com/diem/reference-wallet/blob/master/backend/README.md#running-the-diem-mini-wallet-dmw-testsuite