Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

EntryPointExecutionContext::new_invoke is a crazy misleading name #1761

Open
tdelabro opened this issue Apr 5, 2024 · 0 comments · May be fixed by starkware-libs/sequencer#220
Open

EntryPointExecutionContext::new_invoke is a crazy misleading name #1761

tdelabro opened this issue Apr 5, 2024 · 0 comments · May be fixed by starkware-libs/sequencer#220

Comments

@tdelabro
Copy link
Contributor

tdelabro commented Apr 5, 2024

    pub fn new_validate(
        tx_context: Arc<TransactionContext>,
        limit_steps_by_resources: bool,
    ) -> TransactionExecutionResult<Self> {
        Self::new(tx_context, ExecutionMode::Validate, limit_steps_by_resources)
    }

    pub fn new_invoke(
        tx_context: Arc<TransactionContext>,
        limit_steps_by_resources: bool,
    ) -> TransactionExecutionResult<Self> {
        Self::new(tx_context, ExecutionMode::Execute, limit_steps_by_resources)
    }

It should be new_execute we are talking about execution modes that can be "validate" or "execute".
Invoke refers to a transaction type, not an execution mode.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant