codecrepos.clone_progress
- class CloneProgress[source]
Bases:
RemoteProgress- update(op_code, cur_count, max_count=None, message='')[source]
Called whenever the progress changes.
- Parameters:
op_code (int) –
Integer allowing to be compared against Operation IDs and stage IDs.
Stage IDs are
BEGINandEND.BEGINwill only be set once for each Operation ID as well asEND. It may be thatBEGINandENDare set at once in case only one progress message was emitted due to the speed of the operation. BetweenBEGINandEND, none of these flags will be set.Operation IDs are all held within the
OP_MASK. Only one Operation ID will be active per call.cur_count (int) – Current absolute count of items.
max_count (int | None) – The maximum count of items we expect. It may be
Nonein case there is no maximum number of items or if it is (yet) unknown.message (str) – In case of the
WRITINGoperation, it contains the amount of bytes transferred. It may possibly be used for other purposes as well.
- Note:
You may read the contents of the current line in
self._cur_line.- Return type:
None
- error_lines: List[str]
- other_lines: List[str]