-
Notifications
You must be signed in to change notification settings - Fork 68
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
Executable Refactor changes #849
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech>
* Created base structures and interfaces (executable & transaction) and implemented root functions inside Transaction struct. Refactored '_Execute' func to accept only client and Executable reference Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored transaction struct and interfaces names, because we should keep ITransaction with only one method Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Renamed Terminal -> terminal in more files Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Moved common getters inside executable.go. Edited account_create_transaction.go to use the new approach Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Implemented default executable methods inside Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored transaction struct name in some functions to match the new style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored query root struct and file_contents_query.go to match the new style. Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_balance_query.go to use the new style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Removed 'build' from executable, because query and transaction build return types are different. Also refactored account_balance_query.go to use the new approach Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Recatored tests to use new function method, added public function for query method to match old name Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_info.go to use the new design Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_records_query.go to use the new design Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_stakers_query.go Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_bytecode_query.go to use the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contracy_bytecode_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Changed method names inside address_book_query.go to match the method names inside other queries Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored file_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored live_hash_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored network_version_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored schedule_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored token_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored token_nft_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored topic_info_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored private function names inside topic_message_query.go to match the new names Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored transaction_receipt_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored transaction_record_query.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_allowance_approve_transaction.go to use the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_allowance_approve_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_allowance_delete_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_delete_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored account_update_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_create_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_delete_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_execute_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored contract_update_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored ethereum_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored file_append_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored file_create_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored file_delete_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored file_update_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored freeze_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored live_has_add_transaction.go to match the new design style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored transaction.go with Schedule function inside. Refactored file_update.go with only specific implementations Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Remove getLogId, because I have getName() Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Updated token, topic, transfer, system and schedule transactions (#837) Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Renamed this -> tx Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fixed unit test running Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored all transaction instances to have buildProtoBody & _ConstructScheduleProtobuf Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Renamed query receivers -> 'q' Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Edited executable functions Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fix freeze functionality Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored 'execute' in Executable and added get Request type, so we can reuse old functions Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored executable Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fixed query execution Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Implemented validateOnNetworkId for file_create_transaction.go Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Changed Transaction struct and interface names Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fix token create account renew Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fix query test problems and executable commented code Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Changed return type on 'fromBytes'. No we pass reference, isntead of copy Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fixed some tests Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Added contract_append_transaction custom execute logic Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fixed all unit tests, which are using 'Transaction.fromBytes' Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fixed query execute to check whether query = AccountBalanceQuery Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Eddited account_balance_query custom execute Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Refactored code to pass lint checks Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fix TransactionFromBytes, removing e in executable Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Fix license Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Clean up Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Fix linting issues Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Fix failing tests cause of TransactionFromBytes Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Removed unnecessary logic Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> * Added getLogID function back to query/transaction to match the new style Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Raised gas on test to test it in pipeline Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Commented some assets regarding balance query and added more gas for contract calls Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Commented test, which is failing because of testnet Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> * Fix failing tests from testnet Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> --------- Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech> Signed-off-by: Antonio Mindov <antonio.mindov@limechain.tech> Co-authored-by: Antonio Mindov <antonio.mindov@limechain.tech>
* Fix: Wrong nodes for transactions Signed-off-by: Emanuel Pargov <bamzedev@gmail.com>
Signed-off-by: NikolaMirchev <nikola.mirchev@limechain.tech>
Quality Gate passedKudos, no new issues were introduced! 0 New issues |
ochikov
approved these changes
Jan 2, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description:
Checklist