5 #define SCORUM_DECLARE_OP_BASE_EXCEPTIONS(op_name) \
6 FC_DECLARE_DERIVED_EXCEPTION(op_name##_validate_exception, scorum::chain::operation_validate_exception, \
7 4040000 + 100 * protocol::operation::tag<protocol::op_name##_operation>::value, \
8 #op_name "_operation validation exception") \
9 FC_DECLARE_DERIVED_EXCEPTION(op_name##_evaluate_exception, scorum::chain::operation_evaluate_exception, \
10 4050000 + 100 * protocol::operation::tag<protocol::op_name##_operation>::value, \
11 #op_name "_operation evaluation exception")
13 #define SCORUM_DECLARE_OP_VALIDATE_EXCEPTION(exc_name, op_name, seqnum, msg) \
14 FC_DECLARE_DERIVED_EXCEPTION( \
15 op_name##_##exc_name, scorum::chain::op_name##_validate_exception, \
16 4040000 + 100 * protocol::operation::tag<protocol::op_name##_operation>::value + seqnum, msg)
18 #define SCORUM_DECLARE_OP_EVALUATE_EXCEPTION(exc_name, op_name, seqnum, msg) \
19 FC_DECLARE_DERIVED_EXCEPTION( \
20 op_name##_##exc_name, scorum::chain::op_name##_evaluate_exception, \
21 4050000 + 100 * protocol::operation::tag<protocol::op_name##_operation>::value + seqnum, msg)
23 #define SCORUM_DECLARE_INTERNAL_EXCEPTION(exc_name, seqnum, msg) \
24 FC_DECLARE_DERIVED_EXCEPTION(internal_##exc_name, scorum::chain::internal_exception, 4990000 + seqnum, msg)
26 #define SCORUM_TRY_NOTIFY(signal, ...) \
29 signal(__VA_ARGS__); \
31 catch (const scorum::chain::plugin_exception& e) \
35 catch (const fc::exception& e) \
37 elog("Caught exception in plugin: ${e}", ("e", e.to_detail_string())); \
41 wlog("Caught unexpected exception in plugin"); \
47 FC_DECLARE_EXCEPTION(chain_exception, 4000000,
"blockchain exception")
49 scorum::chain::chain_exception,
53 scorum::chain::chain_exception,
55 "block validation exception")
57 scorum::chain::chain_exception,
61 scorum::chain::chain_exception,
65 scorum::chain::chain_exception,
70 scorum::chain::chain_exception,
75 scorum::chain::chain_exception,
77 "chain attempted to apply unknown hardfork")
82 scorum::chain::transaction_exception,
86 scorum::chain::transaction_exception,
91 scorum::chain::undo_database_exception,
93 "there are no blocks to pop")
115 #include <fc/exception/exception.hpp>
tracks the blockchain state in an extensible manner
#define SCORUM_DECLARE_INTERNAL_EXCEPTION(exc_name, seqnum, msg)
#define SCORUM_DECLARE_OP_EVALUATE_EXCEPTION(exc_name, op_name, seqnum, msg)
FC_DECLARE_DERIVED_EXCEPTION(database_query_exception, scorum::chain::chain_exception, 4010000, "database query exception") FC_DECLARE_DERIVED_EXCEPTION(block_validate_exception
block validation exception operation validation exception undo database exception transaction expiration exception there are no blocks to pop SCORUM_DECLARE_OP_BASE_EXCEPTIONS(transfer)
fc::static_variant< vote_operation, comment_operation, transfer_operation, transfer_to_scorumpower_operation, withdraw_scorumpower_operation, account_create_by_committee_operation, account_create_operation, account_create_with_delegation_operation, account_update_operation, witness_update_operation, account_witness_vote_operation, account_witness_proxy_operation, delete_comment_operation, comment_options_operation, set_withdraw_scorumpower_route_to_account_operation, set_withdraw_scorumpower_route_to_dev_pool_operation, prove_authority_operation, request_account_recovery_operation, recover_account_operation, change_recovery_account_operation, escrow_approve_operation, escrow_dispute_operation, escrow_release_operation, escrow_transfer_operation, decline_voting_rights_operation, delegate_scorumpower_operation, create_budget_operation, close_budget_operation, proposal_vote_operation, proposal_create_operation, atomicswap_initiate_operation, atomicswap_redeem_operation, atomicswap_refund_operation, close_budget_by_advertising_moderator_operation, update_budget_operation, create_game_operation, cancel_game_operation, update_game_markets_operation, update_game_start_time_operation, post_game_results_operation, post_bet_operation, cancel_pending_bets_operation, delegate_sp_from_reg_pool_operation, create_nft_operation, update_nft_meta_operation, create_game_round_operation, update_game_round_result_operation, adjust_nft_experience_operation, update_nft_name_operation, author_reward_operation, comment_benefficiary_reward_operation, comment_payout_update_operation, comment_reward_operation, curation_reward_operation, hardfork_operation, producer_reward_operation, active_sp_holders_reward_operation, return_scorumpower_delegation_operation, shutdown_witness_operation, witness_miss_block_operation, expired_contract_refund_operation, acc_finished_vesting_withdraw_operation, devpool_finished_vesting_withdraw_operation, acc_to_acc_vesting_withdraw_operation, devpool_to_acc_vesting_withdraw_operation, acc_to_devpool_vesting_withdraw_operation, devpool_to_devpool_vesting_withdraw_operation, proposal_virtual_operation, budget_outgo_operation, budget_owner_income_operation, active_sp_holders_reward_legacy_operation, budget_closing_operation, bets_matched_operation, game_status_changed_operation, bet_resolved_operation, bet_cancelled_operation, bet_restored_operation, bet_updated_operation > operation