Repository navigation
refactor(tck): centralize transaction receipt validation in execute_validated helper - #2649
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (10)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. WalkthroughThe TCK adds a shared ChangesTransaction receipt validation
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to Transaction handlers now share validated receipt execution while preserving failed-receipt error behavior and successful response construction. No concrete current-head merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
Full details: Linked Issues checkExplanation The PR implements the shared helper, refactors the listed handlers, and adds helper tests. However, the summary indicates that create_account and schedule handlers populate identifiers without preserving all presence checks, and it provides no evidence of the required driver transaction suite or validateStatus:false receipt-query tests. Removal of the obsolete contract invariant comment is also not confirmed. Resolution Preserve all required identifier presence checks while removing only redundant SUCCESS checks. Confirm removal of the obsolete contract invariant comment. Run and report at least one driver transaction suite, including validateStatus:false receipt-query tests, and verify status-name responses and JSON-RPC error mapping remain unchanged.
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
aceppaluni
left a comment
There was a problem hiding this comment.
Hi @Abhijeet2409 Thank you for this!
When you have a moment, could you take a look at your commits. Commit 1bd415e seems to be missing verification. Attaching a Signing Guide in case you need assistance. Please feel free to reach out if you need further assistance or have any questions.
Thank you!
…alidated helper Signed-off-by: Abhijeet Saharan <abhijeetsaharan2236@gmail.com>
… after hiero-ledger#2611 merge Signed-off-by: Abhijeet Saharan <abhijeetsaharan2236@gmail.com>
3565fb1 to
edfe80e
Compare
|
👋 Hi @Abhijeet2409! Great work completing a Intermediate issue! 🎉 Thanks for your contribution! 🚀 Here are some issues you might want to explore next:
🌟 Stay connected: Happy coding! 🚀 |
Summary
This PR adds the
execute_validatedhelper, along with unit tests, to clarify and centralize the use of validated transaction receipts. This is a pure structural refactor with no intended changes.Changes
SUCCESSguards have been removed.tck/handlers/account.py,create_accountnow readsreceipt.transaction_idinstead ofresponse.transaction_id, sinceexecute_validatedonly returns the receipt. Verified these are equivalent — the receipt's query is seeded withresponse.transaction_id, so the value is the same.Testing
1.

transaction_utils_test.py— tests forexecute_validated, including successful and failed receipt handling.TCK test suiteAlso , Re-checked the codebase before opening the PR to ensure no transaction handlers using the validated receipt pattern were missed.
Fixes #2626