mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-22 15:38:11 +00:00
src/apps+tests: use TODO consistently across whole codebase
This commit is contained in:
parent
69344f34b6
commit
585e9842f8
@ -7,8 +7,8 @@ from ubinascii import hexlify
|
||||
from . import networks
|
||||
|
||||
|
||||
async def confirm_tx(ctx, to, value, chain_id, token=None): # todo wording
|
||||
str_to = '0x' + hexlify(to).decode() # todo use ethereum address format
|
||||
async def confirm_tx(ctx, to, value, chain_id, token=None): # TODO: wording
|
||||
str_to = '0x' + hexlify(to).decode() # TODO: use ethereum address format
|
||||
content = Text('Confirm transaction', ui.ICON_RESET,
|
||||
ui.BOLD, format_amount(value, token, chain_id),
|
||||
ui.NORMAL, 'to',
|
||||
@ -16,7 +16,7 @@ async def confirm_tx(ctx, to, value, chain_id, token=None): # todo wording
|
||||
return await confirm(ctx, content, ButtonRequestType.SignTx) # we use SignTx, not ConfirmOutput, for compatibility with T1
|
||||
|
||||
|
||||
async def confirm_fee(ctx, spending, gas_price, gas_limit, chain_id, token=None): # todo wording
|
||||
async def confirm_fee(ctx, spending, gas_price, gas_limit, chain_id, token=None): # TODO: wording
|
||||
content = Text('Confirm fee', ui.ICON_RESET,
|
||||
'Sending: %s' % format_amount(spending, token, chain_id),
|
||||
'Gas: %s' % format_amount(gas_price, token, chain_id),
|
||||
@ -24,7 +24,7 @@ async def confirm_fee(ctx, spending, gas_price, gas_limit, chain_id, token=None)
|
||||
return await hold_to_confirm(ctx, content, ButtonRequestType.SignTx)
|
||||
|
||||
|
||||
async def confirm_data(ctx, data, data_total): # todo wording
|
||||
async def confirm_data(ctx, data, data_total): # TODO: wording
|
||||
str_data = hexlify(data[:8]).decode() + '..'
|
||||
content = Text('Confirm data:', ui.ICON_RESET,
|
||||
ui.MONO, str_data,
|
||||
|
@ -85,7 +85,7 @@ def get_total_length(msg: EthereumSignTx, data_total: int) -> int:
|
||||
|
||||
async def send_request_chunk(ctx, data_left: int):
|
||||
from trezor.messages.wire_types import EthereumTxAck
|
||||
# todo layoutProgress ?
|
||||
# TODO: layoutProgress ?
|
||||
req = EthereumTxRequest()
|
||||
if data_left <= 1024:
|
||||
req.data_length = data_left
|
||||
|
@ -18,7 +18,7 @@ class TestSegwitBip143(unittest.TestCase):
|
||||
prev_hash=unhexlify('77541aeb3c4dac9260b68f74f44c973081a9d4cb2ebe8038b2d70faa201b6bdb'),
|
||||
prev_index=1,
|
||||
amount=1000000000, # 10 btc
|
||||
script_type=InputScriptType.SPENDP2SHWITNESS, # todo is this correct?
|
||||
script_type=InputScriptType.SPENDP2SHWITNESS, # TODO: is this correct?
|
||||
sequence=0xfffffffe)
|
||||
out1 = TxOutputType(address='1Fyxts6r24DpEieygQiNnWxUdb18ANa5p7',
|
||||
amount=0x000000000bebb4b8,
|
||||
|
@ -135,7 +135,7 @@ class TestSignSegwitTxNativeP2WPKH(unittest.TestCase):
|
||||
address='2N4Q5FhU2497BryFfUgbqkAJE87aKHUhXMp',
|
||||
amount=5000000,
|
||||
script_type=OutputScriptType.PAYTOADDRESS,
|
||||
address_n=None, # @todo ask honza about sanitizing
|
||||
address_n=None, # TODO: ask honza about sanitizing
|
||||
)
|
||||
out2 = TxOutputType(
|
||||
address=None,
|
||||
|
@ -141,7 +141,7 @@ class TestSignSegwitTxP2WPKHInP2SH(unittest.TestCase):
|
||||
address_n=[49 | 0x80000000, 1 | 0x80000000, 0 | 0x80000000, 1, 0],
|
||||
script_type=OutputScriptType.PAYTOP2SHWITNESS,
|
||||
amount=123456789 - 11000 - 12300000,
|
||||
address=None, # todo ask about sanitizing
|
||||
address=None, # TODO: ask about sanitizing
|
||||
)
|
||||
tx = SignTx(coin_name='Testnet', version=None, lock_time=None, inputs_count=1, outputs_count=2)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user