## nodes.StageRefresh


What one refresh did to one node: how its state started (on the first


Usage

``` python
nodes.StageRefresh(
    node,
    report,
    started=None,
    write=None,
    preconditions=list(),
    retention=list(),
    postconditions=list(),
    route=None,
    transform=None,
    quarantine=list(),
    quarantined=0,
    quarantine_table=None,
    held=None,
    held_error=None
)
```


refresh), what the batch was, and what its sink wrote. `str()` shows them in that order; [summary()](cli.summary.md#sverify.cli.summary) gives one line, unless the refresh did something [notable](nodes.Refresh.md#sverify.nodes.Refresh.notable).


## Parameter Attributes


`node: str`  
The node's name.

`report: RefreshReport | None`  
The batch: the source versions it went from and to, the changes, how they were applied and the preconditions checked on them. None on a first refresh that computed or resumed the state at the latest versions.

`started: str | None = None`  
"computed", or "resumed from

<span class="citation" data-cites="v<n">@v\<n</span>\>", on the first refresh.

`write: SinkWrite | None = None`  

`preconditions: list[Discharged] = list()`  
On the first refresh: how each precondition on the sources was established on the full tables (later batches: `report.preconditions`).

`retention: list[RetentionReport] = list()`  
For a node over a source with `arrives_within`: its open time buckets, those dropped from its state after the write, and the bound.

`postconditions: list[Discharged] = list()`  
On the first refresh: the postconditions the node's transform did not prove and checks on its output (`on_unproved="check"`), checked on the full result (later batches: `report.postconditions`).

`route: Route | None = None`  
With `refresh(route=...)`: how the node's proof reached the engine (D13), with its class; None without a route or a contract.

`transform: str | None = None`  
For a stored node, the transform that made it, where its name differs from the node's (the sink's): the entry is headed `daily_revenue → daily:` (#695).

`quarantine: list[QuarantineReport] = list()`  
For each source with rows set aside (`on_violation="quarantine"`, \#184): what this refresh set aside, released and deleted.

`quarantined: int = ``0`  
The rows of the node's sources quarantined after the refresh, in all.

`quarantine_table: str | None = None`  
Where they are stored, if the node writes them to a table.

`held: str | None = None`  
Why the node did not take the batch (`on_violation="hold"`, or a condition no row rule covers), or "waiting for " when a stored node it reads has no state yet; None if it took it.

`held_error: Exception | None = None`  
The [PreconditionError](errors.PreconditionError.md#sverify.errors.PreconditionError) that held it, with `.rows`.


## Methods

| Name | Description |
|----|----|
| [summary()](#summary) | One line, for the log of a job that refreshes often: |
| [to_dict()](#to_dict) | The entry as JSON values ([Refresh.to_json](nodes.Refresh.md#sverify.nodes.Refresh.to_json)). |

------------------------------------------------------------------------


#### summary()


One line, for the log of a job that refreshes often:


Usage

``` python
summary()
```


"paid: changes from orders v3→v4 (change feed), requires checked on 2 row(s), merge v5: +2 −0". With something [notable](nodes.Refresh.md#sverify.nodes.Refresh.notable), the full entry (`str()`) instead.


------------------------------------------------------------------------


#### to_dict()


The entry as JSON values ([Refresh.to_json](nodes.Refresh.md#sverify.nodes.Refresh.to_json)).


Usage

``` python
to_dict()
```
