algorand / ledger-app-algorand

MIT License
23 stars 35 forks source link

Increase appl type transaction limits #42

Closed Alex99y closed 2 years ago

Alex99y commented 3 years ago

The current implementation of the Algorand ledger app is limiting the amount of the appl type transaction inputs: It is defined as:

#define MAX_ACCT 2
#define MAX_ARG 2
#define MAX_ARGLEN 32
#define MAX_FOREIGN_APPS 1
#define MAX_FOREIGN_ASSETS 1

https://github.com/algorand/ledger-app-algorand/blob/master/src/algo_tx.h#L81

It is much less than the network consensus allowed, which is:

v24.MaxAppTxnAccounts = 4
v24.MaxAppArgs = 16
v24.MaxAppTotalArgLen = 2048
v24.MaxAppTxnForeignApps = 2
v24.MaxAppTxnForeignAssets = 2

https://github.com/algorand/go-algorand/blob/master/config/consensus.go#L845

This will not allow users to interact completely with an application (Maybe can opt-in, but cannot make NoOp calls), or can operate normally but cannot close out the application because it needs more than 2 arguments.

Is it possible to increase those limits?. Especially for maxAppArgs and maxAppArgLen.

Thank you.

id-ms commented 3 years ago

Hi!

Unfortunately, this is not a very straightforward implementation. The reason for that is that the Nano S has a small amount of RAM.

We will have to investigate the amount of space left on the device first.

teious commented 2 years ago

Hello! any updates about this?

rotemh commented 2 years ago

Fixed with the last version. Thanks for reporting it!