Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sequencer: use address bytes directly in handle_check_tx() logic #1620

Open
Lilyjjo opened this issue Oct 3, 2024 · 3 comments
Open

sequencer: use address bytes directly in handle_check_tx() logic #1620

Lilyjjo opened this issue Oct 3, 2024 · 3 comments
Assignees
Labels
ignore-stale Override for issues or PRs which should not be removed if stale. performance sequencer pertaining to the astria-sequencer crate stale

Comments

@Lilyjjo
Copy link
Contributor

Lilyjjo commented Oct 3, 2024

In the handle_check_tx() logic we're using a heavy weight address computation instead of using the address bytes directly. We should change this to just use the bytes. We should also remove the associated metric when making the change.

// TODO: change rest of code to allow just using bytes instead of having to
// generate this function
let address = match state
        .try_base_prefixed(signed_tx.verification_key().address_bytes())
        .await
        .context("failed to generate address for signed transaction")
    {
        Err(err) => {
            return Err(response::CheckTx {
                code: Code::Err(AbciErrorCode::INTERNAL_ERROR.value()),
                info: AbciErrorCode::INTERNAL_ERROR.info(),
                log: format!("failed to generate address because: {err:#}"),
                ..response::CheckTx::default()
            });
        }
        Ok(address) => address,
    };

┆Issue Number: ENG-903
@joroshiba
Copy link
Member

This issue is stale because it has been open 45 days with no activity. Remove stale label or this issue
be closed in 7 days.

@joroshiba
Copy link
Member

This issue was closed because it was stale

@joroshiba joroshiba closed this as not planned Won't fix, can't repro, duplicate, stale Dec 20, 2024
@Fraser999 Fraser999 added the ignore-stale Override for issues or PRs which should not be removed if stale. label Feb 14, 2025
@Fraser999
Copy link
Contributor

Still worthwhile to do this - should be fairly simple to implement I think.

@Fraser999 Fraser999 reopened this Feb 14, 2025
@Fraser999 Fraser999 self-assigned this Feb 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ignore-stale Override for issues or PRs which should not be removed if stale. performance sequencer pertaining to the astria-sequencer crate stale
Projects
None yet
Development

No branches or pull requests

3 participants