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

Add signatures result in transaction output #271

Merged
merged 4 commits into from
Jul 30, 2024

Conversation

amishas157
Copy link
Contributor

@amishas157 amishas157 commented Jul 29, 2024

PR Checklist

PR Structure

  • This PR has reasonably narrow scope (if not, break it down into smaller PRs).
  • This PR avoids mixing refactoring changes with feature changes (split into two PRs
    otherwise).
  • This PR's title starts with the jira ticket associated with the PR.

Thoroughness

  • This PR adds tests for the most critical parts of the new functionality or fixes.
  • I've updated the README with the added features, breaking changes, new instructions on how to use the repository. I updated the description of the fuction with the changes that were made.

Release planning

  • I've decided if this PR requires a new major/minor/patch version accordingly to
    semver, and I've changed the name of the BRANCH to release/_ , feature/_ or patch/* .

What

This PR adds export of signatures field in history_transactions table.

Why

There are instances when a payment is initiated by child account, however the balance is cut from parent account. To verify that parent account adds signatures to those payment, we require this feature.

Known limitations

None. Signatures is added as repeated string. To use it downstream, we would need to unnest it. However, there are no alternatives of it.

@amishas157 amishas157 force-pushed the feature/hubble-500/export-signatures branch from 25e0f58 to ced69a3 Compare July 29, 2024 21:03
@amishas157 amishas157 marked this pull request as ready for review July 29, 2024 21:49
@amishas157 amishas157 requested a review from a team as a code owner July 29, 2024 21:49
@amishas157
Copy link
Contributor Author

Test Results:

  1. Local
root@94c16c371f6a:/etl/data# stellar-etl export_transactions --start-ledger 4729339 --end-ledger 4729939 --output exported_transactions.txt
INFO[2024-07-29T17:51:53.229Z] Number of bytes written: 9607                 pid=20
INFO[2024-07-29T17:51:53.231Z] {"attempted_transforms":5,"failed_transforms":0,"successful_transforms":5}  pid=20
INFO[2024-07-29T17:51:53.231Z] No cloud provider specified for upload. Skipping upload.  pid=20
root@94c16c371f6a:/etl/data# head exported_transactions.txt
root@94c16c371f6a:/etl/data# head exported_transactions.txt
{"account":"GDPBVCYEQCVPE66UQPFSGCF6WCFYQC4CW7BESWR4DVD7HUI3FELKUT4K","account_sequence":18020046391476225,"closed_at":"2016-06-08T21:13:08Z","created_at":"2016-06-08T21:13:08Z","extra_signers":null,"fee_charged":100,"id":20312356336701440,"inclusion_fee_bid":0,"inclusion_fee_charged":0,"ledger_bounds":"","ledger_sequence":4729339,"max_fee":100,"memo":"3598160","memo_type":"MemoTypeMemoText","min_account_sequence":null,"min_account_sequence_age":null,"min_account_sequence_ledger_gap":null,"non_refundable_resource_fee_charged":0,"operation_count":1,"refundable_resource_fee_charged":0,"rent_fee_charged":0,"resource_fee":0,"resource_fee_refund":0,"signatures":["pwvX5/Zr91oRUaijPXdtUQ6zNY/w38sKVoUxO7CcAdm6OsZEuPGT5hXo3iF2dz5ArE7LWz3gsjGkmrSKgIqDCA=="],"soroban_resources_instructions":0,"soroban_resources_read_bytes":0,"soroban_resources_write_bytes":0,"successful":false,"time_bounds":"","transaction_hash":"dfce4ce6818623afb10a85f0ad51f877ad2b6627dcdaf6f4655de981fee6fbca","transaction_result_code":"TransactionResultCodeTxFailed","tx_envelope":"AAAAAN4aiwSAqvJ71IPLIwi+sIuIC4K3wklaPB1H89EbKRaqAAAAZABABSMAAAABAAAAAAAAAAEAAAAHMzU5ODE2MAAAAAABAAAAAAAAAAEAAAAAjNsoSdqPFb2bmzzfj3buFDSVfgawK5btZGeeQ95hGZ8AAAAAAAAAC6hnkIYAAAAAAAAAARspFqoAAABApwvX5/Zr91oRUaijPXdtUQ6zNY/w38sKVoUxO7CcAdm6OsZEuPGT5hXo3iF2dz5ArE7LWz3gsjGkmrSKgIqDCA==","tx_fee_meta":"AAAAAgAAAAMAQAUjAAAAAAAAAADeGosEgKrye9SDyyMIvrCLiAuCt8JJWjwdR/PRGykWqgAAAAu0U1KGAEAFIwAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAEASCn7AAAAAAAAAADeGosEgKrye9SDyyMIvrCLiAuCt8JJWjwdR/PRGykWqgAAAAu0U1IiAEAFIwAAAAEAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAA==","tx_meta":"AAAAAgAAAAAAAAAAAAAAAA==","tx_result":"AAAAAAAAAGT/////AAAAAQAAAAAAAAAB/////gAAAAA="}
{"account":"GDPBVCYEQCVPE66UQPFSGCF6WCFYQC4CW7BESWR4DVD7HUI3FELKUT4K","account_sequence":18020046391476226,"closed_at":"2016-06-08T21:16:52Z","created_at":"2016-06-08T21:16:52Z","extra_signers":null,"fee_charged":100,"id":20312622624673792,"inclusion_fee_bid":0,"inclusion_fee_charged":0,"ledger_bounds":"","ledger_sequence":4729401,"max_fee":100,"memo":"3598160","memo_type":"MemoTypeMemoText","min_account_sequence":null,"min_account_sequence_age":null,"min_account_sequence_ledger_gap":null,"non_refundable_resource_fee_charged":0,"operation_count":1,"refundable_resource_fee_charged":0,"rent_fee_charged":0,"resource_fee":0,"resource_fee_refund":0,"signatures":["r03h1GsEVf3WBEY5wrC0rIJ6bJQTcmhNnQA/Mlc/560iC0Ckvc/EPGSVkCPrRyeM9zQySp4nDRud1R6B3yooBA=="],"soroban_resources_instructions":0,"soroban_resources_read_bytes":0,"soroban_resources_write_bytes":0,"successful":false,"time_bounds":"","transaction_hash":"a9bb0b83dc8b1735a11ede37aced567faf37b3f3004f29b5e30963d68e6ffcfe","transaction_result_code":"TransactionResultCodeTxFailed","tx_envelope":"AAAAAN4aiwSAqvJ71IPLIwi+sIuIC4K3wklaPB1H89EbKRaqAAAAZABABSMAAAACAAAAAAAAAAEAAAAHMzU5ODE2MAAAAAABAAAAAAAAAAEAAAAAjNsoSdqPFb2bmzzfj3buFDSVfgawK5btZGeeQ95hGZ8AAAAAAAAAC6hnkCIAAAAAAAAAARspFqoAAABAr03h1GsEVf3WBEY5wrC0rIJ6bJQTcmhNnQA/Mlc/560iC0Ckvc/EPGSVkCPrRyeM9zQySp4nDRud1R6B3yooBA==","tx_fee_meta":"AAAAAgAAAAMASCn7AAAAAAAAAADeGosEgKrye9SDyyMIvrCLiAuCt8JJWjwdR/PRGykWqgAAAAu0U1IiAEAFIwAAAAEAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAEASCo5AAAAAAAAAADeGosEgKrye9SDyyMIvrCLiAuCt8JJWjwdR/PRGykWqgAAAAu0U1G+AEAFIwAAAAIAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAA==","tx_meta":"AAAAAgAAAAAAAAAAAAAAAA==","tx_result":"AAAAAAAAAGT/////AAAAAQAAAAAAAAAB/////gAAAAA="}
  1. BigQuery
    Screenshot 2024-07-30 at 10 09 36 AM

@amishas157 amishas157 merged commit ffe275c into master Jul 30, 2024
7 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