@@ -59,20 +59,28 @@ def __init__(self, *,
5959 else :
6060 self .block_error_handler = block_error_handler
6161
62- # errors can happen during the submit call to the provider; this is used
63- # to keep track of such errors so that they can be handled in one place
64- # together with errors reported by status()
65- self ._simulated_status : Dict [str , JobStatus ] = {}
6662 self ._executor_bad_state = threading .Event ()
6763 self ._executor_exception : Optional [Exception ] = None
6864
6965 self ._block_id_counter = AtomicIDCounter ()
7066
7167 self ._tasks = {} # type: Dict[object, Future]
68+
69+ self ._last_poll_time = 0.0
70+
71+ # these four structures track, in loosely coordinated fashion, the
72+ # existence of blocks and jobs and how to map between their
73+ # identifiers.
7274 self .blocks_to_job_id = {} # type: Dict[str, str]
7375 self .job_ids_to_block = {} # type: Dict[str, str]
7476
75- self ._last_poll_time = 0.0
77+ # errors can happen during the submit call to the provider; this is used
78+ # to keep track of such errors so that they can be handled in one place
79+ # together with errors reported by status()
80+ self ._simulated_status : Dict [str , JobStatus ] = {}
81+
82+ # this stores an approximation (sometimes delayed) of the latest status
83+ # of pending, active and recently terminated blocks
7684 self ._status = {} # type: Dict[str, JobStatus]
7785
7886 def _make_status_dict (self , block_ids : List [str ], status_list : List [JobStatus ]) -> Dict [str , JobStatus ]:
0 commit comments