FAQ
When writing or interacting with Renec programs, there are common questions or challenges that often come up. Below are resources to help answer these questions.
If not addressed here, the Renec #developers Discord channel is a great resource.
CallDepth
error#
This error means that that cross-program invocation exceeded the allowed invocation call depth.
See cross-program invocation Call Depth
CallDepthExceeded
error#
This error means the BPF stack depth was exceeded.
See call depth
#
Computational constraints#
Float Rust typesSee float support
#
Heap sizeSee heap
#
InvalidAccountDataThis program error can happen for a lot of reasons. Usually, it's caused by passing an account to the program that the program is not expecting, either in the wrong position in the instruction or an account not compatible with the instruction being executed.
An implementation of a program might also cause this error when performing a cross-program instruction and forgetting to provide the account for the program that you are calling.
#
InvalidInstructionDataThis program error can occur while trying to deserialize the instruction, check
that the structure passed in matches exactly the instruction. There may be some
padding between fields. If the program implements the Rust Pack
trait then try
packing and unpacking the instruction type T
to determine the exact encoding
the program expects:
https://github.com/remitano/renec/blob/v1.4/sdk/program/src/program_pack.rs
#
MissingRequiredSignatureSome instructions require the account to be a signer; this error is returned if an account is expected to be signed but is not.
An implementation of a program might also cause this error when performing a
cross-program invocation that requires a signed program address, but the passed
signer seeds passed to invoke_signed
don't match the signer seeds used to create the program address
create_program_address
.
rand
Rust dependency causes compilation failure#
#
Rust restrictions#
Stack sizeSee stack