Skip to content

Conversation

@gRoussac
Copy link
Contributor

@gRoussac gRoussac commented Aug 18, 2025

Updated get_immediate_caller and Add key_as_account_or_package Key conversion

maintains CEP-18 compatibility, and standardizes caller Key for balances and allowances dictionaries.

  • Updated get_immediate_caller to clearly map different caller kinds (ACCOUNT, CONTRACT, ENTITY) to a Key, handling:

    Legacy accounts + New entities account → AccountHash

    Legacy contract packages → ContractPackageHash

    New entities (not account)→ PackageHash

  • Introduced key_as_account_or_package helper to convert new-style Key returned by get_immediate_caller into a compatible Key (AccountHash / Hash), ensuring backward compatibility. Storage keeps Key (AccountHash / Hash).

  • Documented behavior

  • Testing note: In tests enabling Addressable entities in test builder is depending on added feature test-enable-addressable-entity . Test are now run with or without addressable-entity

@gRoussac
Copy link
Contributor Author

gRoussac commented Aug 18, 2025

Will pass CI/CD on next release of casper node execution_engine_testing with uitls::create_run_genesis_request_with_chainspec_config

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants