Skip to content

Commit

Permalink
refactor: remove account version
Browse files Browse the repository at this point in the history
  • Loading branch information
obatirou committed Aug 19, 2024
1 parent a1d9739 commit 3a2ee5a
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 18 deletions.
11 changes: 0 additions & 11 deletions src/kakarot/accounts/account_contract.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,6 @@ func initialize{
return AccountContract.initialize(evm_address);
}

// @notice Returns the version of the account class.
// @dev The version is a packed integer with the following format: XXX.YYY.ZZZ where XXX is the
// major version, YYY is the minor version and ZZZ is the patch version.
@view
func version{
syscall_ptr: felt*, pedersen_ptr: HashBuiltin*, range_check_ptr, bitwise_ptr: BitwiseBuiltin*
}() -> (version: felt) {
let version = AccountContract.VERSION;
return (version=version);
}

// @notice Gets the evm address associated with the account.
// @return address The EVM address of the account.
@view
Expand Down
3 changes: 0 additions & 3 deletions src/kakarot/accounts/library.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,6 @@ const BYTES_PER_FELT = 31;
// @notice This file contains the EVM account representation logic.
// @dev: Both EOAs and Contract Accounts are represented by this contract. Owner is expected to be Kakarot.
namespace AccountContract {
// 000.001.000
const VERSION = 000001000;
// @notice This function is used to initialize the smart contract account.
// @dev The `evm_address` and `kakarot_address` were set during the uninitialized_account creation.
// Reading them from state ensures that they always match the ones the account was created for.
Expand Down
3 changes: 0 additions & 3 deletions src/kakarot/interfaces/interfaces.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,6 @@ namespace IAccount {
func set_implementation(implementation: felt) {
}

func version() -> (version: felt) {
}

func bytecode_len() -> (len: felt) {
}

Expand Down
2 changes: 1 addition & 1 deletion tests/fixtures/uninitialized_account_fixture.cairo
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: MIT
// ! A fixture of the Account Contract class, used to test the upgradeability flow, where version = 001.000.000
// ! A fixture of the Account Contract class, used to test the upgradeability flow
%lang starknet

from kakarot.accounts.uninitialized_account import (
Expand Down

0 comments on commit 3a2ee5a

Please sign in to comment.