Skip to content

Parts of Repo Should Have More Specific Exception Types #20

@gunnarmiller

Description

@gunnarmiller

Several parts of the repo should be modified to use more specific exception types to make exception handling and debugging easier. Possible categories include:

  1. Exceptions encountered by miners attempting to mine or validate blocks. These are likely to be used primarily in src/agents/miner.py, src/agents/trial_manager.py and src/protocols/proof_of_work_protocol.py
  2. Exceptions related by issues connecting to D-Wave solvers. These are likely to be used primarily in src/protocols/hash_calculator.py and src/utilities/quantum_cubic_utils.py
  3. Exceptions caused by errors in Block data structure. These should mostly be used in src/structures/block.py, though perhaps some may also be appropriate in src/agents/miner.py
  4. Exceptions caused by the structures managing the blockchain reaching an invalid state. These should be used in src/structures/block_score_tree.py and src/structures/score_tree_branch.py

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions