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

feat: stark tx auth #477

Merged
merged 3 commits into from
Aug 15, 2023
Merged

feat: stark tx auth #477

merged 3 commits into from
Aug 15, 2023

Conversation

Orland0x
Copy link
Contributor

No description provided.

@Orland0x Orland0x requested a review from pscott August 12, 2023 22:43
Copy link
Contributor

@pscott pscott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

starknet/src/authenticators/stark_tx.cairo Show resolved Hide resolved
starknet/src/authenticators/stark_tx.cairo Show resolved Hide resolved
starknet/src/authenticators/stark_tx.cairo Show resolved Hide resolved
starknet/src/tests/test_stark_tx_auth.cairo Show resolved Hide resolved
starknet/src/tests/test_stark_tx_auth.cairo Outdated Show resolved Hide resolved
let (factory, space) = deploy(@config);
let authenticator = setup_stark_tx_auth(space, config.owner);

let quorum = u256_from_felt252(1);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1_u256

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually can grep and replace u256_from_felt252(constant)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh theres a lot of other places where i used u256_from_felt252 or even u256 { 1, 0} so will fix on a diff pr

let authenticator = setup_stark_tx_auth(space, config.owner);

let quorum = u256_from_felt252(1);
let mut constructor_calldata = ArrayTrait::<felt252>::new();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we use let mut constructor_calldata: Array<felt252> = array![] here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

im not sure how to do this while serializing the types into the array of felts. any ideas?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you can do this in a one liner but here I was just referring to using array![] instead of ArrayTrait::<felt252>::new()

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

serializing will still need to be done on the line just after i'm afraid

Comment on lines +201 to +203
ArrayTrait::<felt252>::new(),
ArrayTrait::<felt252>::new()
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

array![] ?

@Orland0x Orland0x requested a review from pscott August 15, 2023 18:08
@Orland0x Orland0x merged commit 831369d into develop Aug 15, 2023
2 checks passed
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