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

txn emitter - add more info on failed txn #15756

Merged
merged 1 commit into from
Jan 16, 2025
Merged

Conversation

igor-aptos
Copy link
Contributor

@igor-aptos igor-aptos commented Jan 16, 2025

and remove test that uses new code - which fails framework upgrade.

Description

How Has This Been Tested?

Key Areas to Review

Type of Change

  • New feature
  • Bug fix
  • Breaking change
  • Performance improvement
  • Refactoring
  • Dependency update
  • Documentation update
  • Tests

Which Components or Systems Does This Change Impact?

  • Validator Node
  • Full Node (API, Indexer, etc.)
  • Move/Aptos Virtual Machine
  • Aptos Framework
  • Aptos CLI/SDK
  • Developer Infrastructure
  • Move Compiler
  • Other (specify)

Checklist

  • I have read and followed the CONTRIBUTING doc
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I identified and added all stakeholders and component owners affected by this change as reviewers
  • I tested both happy and unhappy path of the functionality
  • I have made corresponding changes to the documentation

Copy link

trunk-io bot commented Jan 16, 2025

⏱️ 2h 16m total CI duration on this PR
Slowest 15 Jobs Cumulative Duration Recent Runs
test-target-determinator 33m 🟩🟩🟩🟩🟩 (+2 more)
execution-performance / single-node-performance 32m 🟥🟩
check-dynamic-deps 18m 🟩🟩🟩🟩🟩 (+3 more)
rust-cargo-deny 12m 🟩🟩🟩🟩🟩 (+2 more)
fetch-last-released-docker-image-tag 11m 🟩🟩🟩🟩🟩 (+2 more)
execution-performance / test-target-determinator 9m 🟩🟩
rust-doc-tests 5m 🟩
rust-doc-tests 5m 🟩
general-lints 3m 🟩🟩🟩🟩🟩 (+2 more)
semgrep/ci 3m 🟩🟩🟩🟩🟩 (+3 more)
file_change_determinator 1m 🟩🟩🟩🟩🟩 (+2 more)
file_change_determinator 1m 🟩🟩🟩🟩🟩 (+2 more)
permission-check 22s 🟩🟩🟩🟩🟩 (+3 more)
permission-check 19s 🟩🟩🟩🟩🟩 (+3 more)
permission-check 18s 🟩🟩🟩🟩🟩 (+3 more)

🚨 1 job on the last run was significantly faster/slower than expected

Job Duration vs 7d avg Delta
execution-performance / single-node-performance 25m 16m +60%

settingsfeedbackdocs ⋅ learn more about trunk.io

Comment on lines 504 to 514
let failured_txn_info = format!(
"due to {:?}, for account {}, max gas {}, payload {}",
failure,
first_failed_txn.sender(),
first_failed_txn.max_gas_amount(),
payload,
);
Copy link

Choose a reason for hiding this comment

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

The variable failured_txn_info contains a typo - "failured" is not a valid English word. Consider renaming to failed_txn_info for better readability. This change would need to be made in both the declaration and where it's used on line 536.

Spotted by Graphite Reviewer

Is this helpful? React 👍 or 👎 to let us know.

@igor-aptos igor-aptos force-pushed the igor/emitter_txn_info branch from 2e28394 to 556c7c5 Compare January 16, 2025 17:31

This comment has been minimized.

This comment has been minimized.

@igor-aptos igor-aptos force-pushed the igor/emitter_txn_info branch from 556c7c5 to 5f0b217 Compare January 16, 2025 18:13
Comment on lines 168 to 178
let payload = match first_failed_txn.payload() {
Script(_) => "script".to_string(),
ModuleBundle(_) => "module_bundle".to_string(),
EntryFunction(entry_function) => format!(
"entry {}::{}",
entry_function.module(),
entry_function.function()
),
Multisig(_) => "multisig".to_string(),
};
Copy link

Choose a reason for hiding this comment

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

The variable first_failed_txn is undefined in this scope - this function receives a parameter named txn. The match statement should use txn.payload() instead of first_failed_txn.payload().

Spotted by Graphite Reviewer

Is this helpful? React 👍 or 👎 to let us know.

@igor-aptos igor-aptos force-pushed the igor/emitter_txn_info branch 2 times, most recently from 9cb2c90 to b71ac0e Compare January 16, 2025 19:04

This comment has been minimized.

Copy link
Contributor

❌ Forge suite framework_upgrade failure on f69dc31b0f674662b6bfa941dc7eee9ce9035e29 ==> b71ac0edf0408caf4e03d6882bc0fdad7ca2e0d7

Forge test runner terminated:
Trailing Log Lines:
             at ./testsuite/forge/src/runner.rs:332:50
  31: forge::run_forge_with_changelog
             at ./testsuite/forge-cli/src/main.rs:428:24
  32: forge::main
             at ./testsuite/forge-cli/src/main.rs:331:21
  33: core::ops::function::FnOnce::call_once
             at /rustc/9b00956e56009bab2aa15d7bff10916599e3d6d6/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
{"level":"INFO","source":{"package":"aptos_forge","file":"testsuite/forge/src/backend/k8s/cluster_helper.rs:381"},"thread_name":"main","hostname":"forge-framework-upgrade-pr-15756-1737055114-f69dc31b0f674662b6b","timestamp":"2025-01-16T19:24:19.408062Z","message":"Deleting namespace forge-framework-upgrade-pr-15756: Some(NamespaceStatus { conditions: None, phase: Some(\"Terminating\") })"}
{"level":"INFO","source":{"package":"aptos_forge","file":"testsuite/forge/src/backend/k8s/cluster_helper.rs:398"},"thread_name":"main","hostname":"forge-framework-upgrade-pr-15756-1737055114-f69dc31b0f674662b6b","timestamp":"2025-01-16T19:24:19.408096Z","message":"aptos-node resources for Forge removed in namespace: forge-framework-upgrade-pr-15756"}
Debugging output:
NAME                                    READY   STATUS      RESTARTS      AGE
aptos-node-0-validator-0                1/1     Running     0             3m14s
aptos-node-1-validator-0                1/1     Running     0             2m33s
aptos-node-2-validator-0                1/1     Running     0             5m21s
aptos-node-3-validator-0                1/1     Running     2 (76s ago)   5m21s
forge-testnet-deployer-m7kkg            0/1     Completed   0             5m28s
genesis-aptos-genesis-eforge245-k5fdl   0/1     Completed   0             5m22s

) {
let handle = permissioned_signer::create_permissioned_handle(source);
let permissioned_signer = permissioned_signer::signer_from_permissioned_handle(&handle);
// public entry fun transfer_permissioned(
Copy link
Contributor

Choose a reason for hiding this comment

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

Are we deleting this because the forge upgrade didn't have the framework code locally just yet?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no - because framework upgrade test issues transactions from framework_usecases module to test framework upgrade - but framework from previous release doesn't have it - so test fails

@igor-aptos igor-aptos enabled auto-merge (squash) January 16, 2025 20:31

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

@igor-aptos igor-aptos force-pushed the igor/emitter_txn_info branch from b71ac0e to 58b0c94 Compare January 16, 2025 21:12

This comment has been minimized.

This comment has been minimized.

Copy link
Contributor

✅ Forge suite compat success on f69dc31b0f674662b6bfa941dc7eee9ce9035e29 ==> 58b0c94abe89ca4bcfe33b46b359d8c567d02e65

Compatibility test results for f69dc31b0f674662b6bfa941dc7eee9ce9035e29 ==> 58b0c94abe89ca4bcfe33b46b359d8c567d02e65 (PR)
1. Check liveness of validators at old version: f69dc31b0f674662b6bfa941dc7eee9ce9035e29
compatibility::simple-validator-upgrade::liveness-check : committed: 15896.40 txn/s, latency: 2013.28 ms, (p50: 2000 ms, p70: 2100, p90: 2500 ms, p99: 3800 ms), latency samples: 509320
2. Upgrading first Validator to new version: 58b0c94abe89ca4bcfe33b46b359d8c567d02e65
compatibility::simple-validator-upgrade::single-validator-upgrading : committed: 4619.76 txn/s, latency: 6678.76 ms, (p50: 7300 ms, p70: 8100, p90: 8400 ms, p99: 8500 ms), latency samples: 95100
compatibility::simple-validator-upgrade::single-validator-upgrade : committed: 4611.74 txn/s, latency: 7387.83 ms, (p50: 8200 ms, p70: 8400, p90: 8600 ms, p99: 8700 ms), latency samples: 164020
3. Upgrading rest of first batch to new version: 58b0c94abe89ca4bcfe33b46b359d8c567d02e65
compatibility::simple-validator-upgrade::half-validator-upgrading : committed: 4498.54 txn/s, latency: 6878.70 ms, (p50: 7600 ms, p70: 8200, p90: 8700 ms, p99: 8700 ms), latency samples: 93560
compatibility::simple-validator-upgrade::half-validator-upgrade : committed: 4236.13 txn/s, latency: 7976.91 ms, (p50: 9000 ms, p70: 9200, p90: 9300 ms, p99: 9400 ms), latency samples: 151220
4. upgrading second batch to new version: 58b0c94abe89ca4bcfe33b46b359d8c567d02e65
compatibility::simple-validator-upgrade::rest-validator-upgrading : committed: 8718.86 txn/s, latency: 3471.10 ms, (p50: 4000 ms, p70: 4200, p90: 4500 ms, p99: 4700 ms), latency samples: 159280
compatibility::simple-validator-upgrade::rest-validator-upgrade : committed: 8988.24 txn/s, latency: 3808.14 ms, (p50: 4100 ms, p70: 4300, p90: 4500 ms, p99: 4600 ms), latency samples: 296320
5. check swarm health
Compatibility test for f69dc31b0f674662b6bfa941dc7eee9ce9035e29 ==> 58b0c94abe89ca4bcfe33b46b359d8c567d02e65 passed
Test Ok

Copy link
Contributor

✅ Forge suite realistic_env_max_load success on 58b0c94abe89ca4bcfe33b46b359d8c567d02e65

two traffics test: inner traffic : committed: 14296.41 txn/s, submitted: 14301.67 txn/s, expired: 5.26 txn/s, latency: 2768.07 ms, (p50: 2700 ms, p70: 2700, p90: 3000 ms, p99: 4200 ms), latency samples: 5435820
two traffics test : committed: 99.99 txn/s, latency: 1384.69 ms, (p50: 1300 ms, p70: 1400, p90: 1600 ms, p99: 3400 ms), latency samples: 1940
Latency breakdown for phase 0: ["MempoolToBlockCreation: max: 1.599, avg: 1.538", "ConsensusProposalToOrdered: max: 0.295, avg: 0.290", "ConsensusOrderedToCommit: max: 0.340, avg: 0.326", "ConsensusProposalToCommit: max: 0.632, avg: 0.616"]
Max non-epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 0.74s no progress at version 4448377 (avg 0.20s) [limit 15].
Max epoch-change gap was: 1 rounds at version 5913577 (avg 0.50) [limit 4], 2.19s no progress at version 5913577 (avg 1.38s) [limit 16].
Test Ok

@igor-aptos igor-aptos merged commit fbf0256 into main Jan 16, 2025
46 checks passed
@igor-aptos igor-aptos deleted the igor/emitter_txn_info branch January 16, 2025 21:45
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.

3 participants