Skip to content

Extract and return tx id from accepted submissions #25

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

caike
Copy link
Member

@caike caike commented Apr 7, 2025

Tested with tx id 327ed556d42319af7c970d11fd5c8b404955a6d696e3ef2b83f947e8a9e8b3f9

The default :crypto module from Erlang is not able to generate Blake2b 256 which is why the hex package is necessary. I'm hesitant to add dependencies unless we have a strong reason to but I feel that the benefit of displaying the transaction id as the result is worth it.

Cursor_and_run_submit_tx_exs

@caike caike requested a review from daveminer April 7, 2025 19:26
@caike caike marked this pull request as ready for review April 7, 2025 19:26
@caike caike marked this pull request as draft April 7, 2025 20:49
error ->
Logger.warning("Error extracting tx id: #{inspect(error)}")
nil
end
Copy link
Member Author

Choose a reason for hiding this comment

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

Wrapped it all into a big ol' try block in order not to mess with the rest of the work in case this particular function fails.

@caike caike marked this pull request as ready for review April 16, 2025 10:55
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.

1 participant