Skip to content

Conversation

@Frozen
Copy link
Collaborator

@Frozen Frozen commented Nov 18, 2025

Transient storage additional tests.

@Frozen Frozen self-assigned this Nov 18, 2025
@Frozen Frozen merged commit b7c8374 into update-1.10.25 Nov 19, 2025
3 checks passed
Frozen added a commit that referenced this pull request Nov 19, 2025
* Test: add transient storage opcodes test case

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: configure EVM with ExtraEips for transient storage opcodes

* Refactor: implement EIP-1153 for transient storage opcodes TLOAD and TSTORE

* Refactor: update contract code to use PUSH1 for transient storage opcodes

* Refactor: enhance TestTransientStorageOpcodes for opcode testing and update Makefile for improved test command

* Refactor: add support for EIP-1153 transient storage in ChainConfig and update instruction set
GheisMohammadi pushed a commit that referenced this pull request Nov 20, 2025
* Add Docker support for Go tests with new Makefile target and Dockerfile

* Refactor Dockerfile for Go tests: remove unnecessary commands and ensure proper dependency installation

* update 1.9.25

* update 1.9.25

* update 1.9.25

* update 1.9.25

* Fixed code

* Fixed StructLog

* compiled

* BlockContext

* Fixed interpreter.

* Fixed tests partially.

* Passed unit tests.

* Fixed imports

* Removed commented block

* Fixed StructLog initialization

* Fixed formatting

* Removed unused

* Fixed code generation

* Removed intpool

* Fixed rpc override.go

* Fixed rpc override_test.go

* Add gas prices for BLS12-381 elliptic curve operations

* Add gas discount table for BLS12-381 G1 and G2 multi exponentiation operations

* Refactor CaptureStart method to remove unused EVM parameter

* Fix chain rules check in readonly mode to use Byzantium instead of S3

* Update gas calculations to reflect EIP-150 and EIP-158 rules

* Add EIP flags for gas calculations in config

* Refactor precompiled contracts to use WriteCapablePrecompiledContract interface and add BLS12-381 precompile implementations

* Refactor precompiled contract tests to use RequiredGas method with updated parameters

* Add readOnly parameter to RunPrecompiledContract and implement IsWrite method for precompiled contracts

* Update RunPrecompiledContract calls in tests to include readOnly parameter

* Update RunPrecompiledContract calls in tests to include gas parameter

* Add BLS12-381 failure test cases and implement IsWrite method for dummy precompile

* Fix code hash retrieval in contract execution for precompiled contracts

* Handle validator addresses in EVM to avoid using code and codeHash fields

* Fixed issue with tests running.

* Remove commented-out test data for bn256 addition and scalar multiplication precompiled contracts

* Refactor precompiled contracts to use wrapper for write capability and remove unused gas parameters

* Refactor precompiled contracts to use wrapper for write capability and remove unused gas parameters

* Update EVM initialization in TestEIP2537Precompile to include BlockContext and TxContext

* Skip tests for EIP 2565 precompiled modexp implementation

* Fix gas calculation in precompiled contract tests to ensure accurate error handling

* Update IsWrite method in precompiled contracts to reflect correct write capability and add tests for validation

* Refactor precompiled contract tests to remove unused variables and improve error handling

* Fix read-only write protection check and enhance precompiled contract tests

* Reorder precompiled contract mappings for improved readability

* Uncomment execution reverted error in errors.go and update related comments

* update 1.9.25

* BlockContext

* Fixed imports

* Added access list.

* Provided eips.

* Add EIP implementations and Harmony-specific support to EVM

Enhanced the EVM with support for EIPs 3855, 3529, and 3198, including new opcodes and gas optimizations. Integrated Harmony-specific functionalities such as validator checks, staking-related operations, and cross-shard transfer support. Refactored gas calculation logic to accommodate both EIP and Harmony enhancements, ensuring extensibility and improved maintenance.

* Add new function signatures for validator and staking precompiles in EVM

* Add RosettaLogAddressItem struct and RosettaTracer interface to EVM

* Remove obsolete error definitions and add new error types for EVM execution

* Refactor opcode definitions for clarity and consistency in opcodes.go

* Refactor contract code by removing unused validJumpSubdest function and simplifying GetByte method

* Add TODO comment to check precompiles in EVM precompile method

* Refactor gas calculations and update function names for clarity in gas_table.go

* Refactor EVM context by removing unused BlockContext and TxContext types in evm.go

* Refactor EVM code by updating chain configuration and simplifying contract execution logic

* Uncomment execution reverted error and clean up commented code in EVM

* Add WithDataCopyFix field to contract struct for EVM execution

* Use ErrWriteProtection constant for error handling in contracts.go

* Refactor EVM contract handling by updating precompile execution logic and improving code structure

* Update chain configuration to include London hard fork in precompiles

* Refactor opAdd function to use ScopeContext for stack operations

* Update EVM instruction handling for S3 chain rules and adjust difficulty operation

* Fix EVM configuration reference for debugging in evm.go

* Add gas parameters for KECCAK256 operations in protocol_params.go

* Rename memorySha3 function to memoryKeccak256 for clarity

* Rename memorySha3 function to memoryKeccak256 for clarity

* Update SetCode method call to include 'false' parameter for state database

* Refactor gas usage validation in interpreter to simplify logic

* Comment out StateDB.Prepare() calls in runtime and state_transition for EIP 1153

* Add SetTxContext method to reset EVM with new transaction context

* Remove unnecessary return statement in CaptureEnd method of ParityBlockTracer

* Implement stubs for transaction capture methods in ParityBlockTracer

* Refactor ParityBlockTracer to replace uint256.Int with big.Int for value handling

* Update Tracer methods to include EVM context in state capture

* Fix CaptureFault method to include memory and stack in fault logging

* Enhance state capture in interpreter by including memory, stack, and contract details

* Fix logger to use big.Int for stack logging and remove unused PaddedBytes function

* Refactor RosettaBlockTracer to use big.Int for value initialization

* Refactor RosettaLogItem to use uint256 for value representation

* Update CaptureStart method to return an error for improved error handling

* Refactor tracer to use uint256 for stack representation

* Add CaptureEnter and CaptureExit methods to Tracer for enhanced tracing functionality

* Add CaptureEnter method to StructLogger and refactor stack logging to use uint256

* Refactor JSONLogger methods and improve stack logging functionality

* Refactor JSONLogger methods and improve stack logging functionality

* Refactor block tracer tests to replace uint256 with big.Int for value handling

* Refactor EVMInterpreter initialization to use env.Config instead of env.vmConfig

* Refactor EVMInterpreter initialization to use env.Config instead of env.vmConfig

* Refactor test utility functions to improve clarity and update file writing method

* Refactor test utility functions to improve clarity and update file writing method

* Refactor instructions tests to replace callCtx with ScopeContext and simplify stack handling

* Add storage field to StructLogger for improved state management

* Refactor TestStoreCapture to remove unused return stack parameter

* Fix TestBigToHash to dereference uint256.NewInt for correct comparison

* Update ChainConfig.Rules to accept isMerge parameter and adjust runtime usage

* Remove isMerge parameter from ChainConfig.Rules and clean up related code

* Fix uint256ToHash function to use common.BigToHash and enhance TestBigToHash with additional test cases

* Fix uint256ToHash function to use common.BigToHash and enhance TestBigToHash with additional test cases

* Refactor EVM contract initialization to streamline code execution flow

* Comment out Stack field in structLogMarshaling for clarity

* Rename variable for clarity in GetState method

* Skip TestStoreCapture due to misconfiguration

* Update go:generate directive to specify gencodec version

* Update go:generate directive to simplify command for AccessTuple

* Add JSON marshaling and unmarshaling for AccessTuple and StructLog

* Refactored consensus decider access and improved thread safety.

* Refactored consensus decider access and improved thread safety.

* Feature: transient storage (#4950)

* Transient storage functionality

* Commented code block in blockchain_test.go

* Refactor state transition rules and remove commented-out Prepare method

* Remove commented-out code block in chain_makers_test.go

* Remove unnecessary parameter from ChainConfig.Rules calls in runtime.go

* Refactor ActivePrecompiles function to use rules parameter instead of evm.chainRules

* Refactor state transition preparation to use statedb.Prepare method

* Feature: replaced duktape with goja (#4958)

* Refactor tracing implementation to replace duktape with goja and clean up unused code

* Update transaction context handling in tracer to use SetTxContext method

* Refactor tracing implementation to use hmyapi for state and block overrides

* Refactor trace event subscriptions to use events package and clean up unused code

* fix(ci): change if condition to build all RPs without checkin a base branch, previously only dev and main

* Refactor jsTracer methods to improve parameter handling and remove unused context

* Refactor logger_test.go to update import paths for Harmony package

* Refactor tracer_test.go to update import paths and improve state handling

* Refactor tracer_test.go to comment out a test case for bad arguments to stack peeks

* Refactor Makefile to run specific test for TestTracer in go-test target

* Refactor Makefile to run TestTracer specifically in the js tracer directory

* Refactor tracer_test.go to improve error handling and logging in test cases

* Refactor tracer_test.go to simplify error message formatting in test cases

* Refactor Makefile to enable verbose output for TestTracer tests

* Refactor tracer_test.go to enhance logging of tracer results during test execution

* Add logging for contract code in EVMInterpreter Run method

* Add debug logging for contract input in EVMInterpreter Run method

* Enable debug mode in EVM configuration for enhanced tracing during tests

* Refactor tracer_test.go to improve test case formatting and readability

* Refactor tracer_test.go to comment out unused test cases for clarity

* Refactor tracer_test.go to uncomment and enable relevant test cases for improved coverage

* Refactor tracer_test.go to add a test case for intrinsic gas calculation

* Refactor goja.go to store intrinsic gas calculation in context

* Refactor tracer_test.go to improve test case clarity and formatting

* Refactor goja.go to update gasUsed assignment and add time context

* Refactor goja.go to remove unused gasUsed assignment in CaptureTxEnd

* Refactor tracer_test.go to improve test case formatting and clarity

* Refactor tracer_test.go to simplify error reporting in test cases

* Refactor tracer_test.go to remove unnecessary debug print statements

* Refactor interpreter.go to remove unused debug print statement

* Refactor Makefile to enhance go test command with race detection and vetting

* Refactor gen_structlog.go to add omitempty for Memory and ReturnData fields and reorder CallerAddress and ContractAddress

* Refactor logger.go to simplify go:generate command for gencodec

* Refactor Makefile to run specific tracer tests and enhance tracer result logging

* Refactor tracer_test.go to comment out specific test cases for memory access and intrinsic gas

* Refactor Makefile to enable verbose output for tracer tests

* Refactor tracer_test.go to print tracer results as a string for better readability

* Refactor tracer_test.go to enhance logging of tracer results for improved debugging

* Refactor tracer.go to log trace results and errors for improved visibility

* Add debug logging for tracer type and configuration in tracer.go

* Add logging for execution results in logger.go for improved traceability

* Add logging for gas limit and remaining gas in CaptureTxEnd for better traceability

* Add debug tracing for transaction start and end in state_transition.go

* Add contract and caller address to StructLog for enhanced logging

* Add caller and contract addresses to structured logs for enhanced traceability

* Improve error message for tracer not found in tracers.go

* Enhance error message for tracer not found in tracers.go to include lookup count

* Add native tracers for transaction analysis: fourByteTracer, callTracer, prestateTracer, revertReasonTracer, and noopTracer

* Add debug log for lookup registration count in tracers.go

* Add panic message for unregistered JS tracer and implement RegisterLookupCount function

* Add panic message in init function for debugging purposes

* Update import path for tracers to use Harmony's package

* Import JS tracers package in hmy.go

* Refactor import paths to use Harmony's core and tracers packages

* Remove debug panic statements from init function in goja.go

* Add time field to callFrame struct in call.go

* Clean up tracer_test.go by removing unnecessary debug print statements

* Update contract code in tracer_test.go to use STOP instruction

* Update logger fields to be omitempty and adjust test expectations

* Remove rosetta checker from Travis CI configuration

* Update CallerAddress and ContractAddress fields to be omitempty in gen_structlog.go

---------

Co-authored-by: Uladzislau Muraveika <[email protected]>

* Refactor: remove unused function and clean up tracer code

* Refactor: remove unused testBackend struct and related functions

* Refactor: improve Makefile test command and enhance state transition logic

* Refactor: fix contract creation condition in state transition logic

* Transient storage additional tests. (#4967)

* Test: add transient storage opcodes test case

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: configure EVM with ExtraEips for transient storage opcodes

* Refactor: implement EIP-1153 for transient storage opcodes TLOAD and TSTORE

* Refactor: update contract code to use PUSH1 for transient storage opcodes

* Refactor: enhance TestTransientStorageOpcodes for opcode testing and update Makefile for improved test command

* Refactor: add support for EIP-1153 transient storage in ChainConfig and update instruction set

* Activation epoch for transient storage on devnet (#4968)

* Test: add transient storage opcodes test case

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: update go test command to run specific transient storage opcodes test

* Refactor: configure EVM with ExtraEips for transient storage opcodes

* Refactor: implement EIP-1153 for transient storage opcodes TLOAD and TSTORE

* Refactor: update contract code to use PUSH1 for transient storage opcodes

* Refactor: enhance TestTransientStorageOpcodes for opcode testing and update Makefile for improved test command

* Refactor: add support for EIP-1153 transient storage in ChainConfig and update instruction set

* Activation epoch for transient storage

---------

Co-authored-by: Uladzislau Muraveika <[email protected]>
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