> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pnbr.io/llms.txt
> Use this file to discover all available pages before exploring further.

# A plan gives a different digest than the one the person saw

> A plan depends on what it read. A Shape, a collection or a newer module can change its figures and its digest, so the person must see the new plan.

Troubleshooting · workflows

> **Use when**
>
> Two plans of one version give different digests, a plan's figures differ from the last one, or a plan is refused with `workflow_invalid` and `artifact_mismatch`.

> **Looking for something else?**
>
> A draft with problems (problems workflow-unhandled-outcome and workflow-step-unavailable). A key refused for a missing scope (card rule workflow\.10).

## Signs

* `penumbra workflows plan <workflow>` prints a different `plan digest` than it
  printed before, for the same version.
* The expected or highest credits of a step differ from the last plan.
* A plan is refused with `workflow_invalid`, and its list holds
  `artifact_mismatch`.

## Why it happens

A figure comes from the extraction plan of the step, and that plan reads the
Files of the collection and the published Shape. When either changes, the figure
changes, and so does the digest of the whole plan. A version that was published
against earlier modules no longer matches the modules this project declares, so
it cannot be planned.

## What Penumbra does

By itself:

* Keeps every plan by its digest on the version, and never replaces one.
* Gives the same digest for the same version and the same inputs.
* Refuses to plan a version that the project's modules no longer match, and
  names `artifact_mismatch`.

You must:

* Plan again after a Shape, a collection or the workflow changes.
* Show the person the new figures before they rely on a cost.
* Publish the workflow again when the version no longer matches.

Not handled:

* Penumbra does not tell the person that an earlier plan is out of date.

## Do

1. Run `penumbra workflows plan <workflow>` again. Note the new digest.
2. Compare each step's cost and basis with the plan the person saw.
3. Tell the person what changed and why, in their words: the Files, the Shape or
   the step.
4. For `artifact_mismatch`, run `penumbra workflows publish <workflow>` and plan
   the new version.

## Don't

* Don't give the person the figures of an old plan as the current cost.
* Don't publish again to change a figure. A publish changes the steps, not what
  they read.

## Check

* The digest in your report is the digest of the plan you ran last.
* The person has seen the figures that go with it.

## Related

Card [workflow](https://docs.pnbr.io/concepts/workflow.md), with rules [workflow.8](https://docs.pnbr.io/concepts/workflow.md#rule-workflow-8) and [workflow.9](https://docs.pnbr.io/concepts/workflow.md#rule-workflow-9). Card [extraction](https://docs.pnbr.io/concepts/extraction.md).
Recipe [automate-a-job](https://docs.pnbr.io/guides/automate-a-job.md).

## Keep going

[Workflow](https://docs.pnbr.io/concepts/workflow.md) · [Write a job as a workflow](https://docs.pnbr.io/guides/automate-a-job.md) · [Extraction](https://docs.pnbr.io/concepts/extraction.md) · [Shape](https://docs.pnbr.io/concepts/shape.md) · [Collection](https://docs.pnbr.io/concepts/collection.md)

Penumbra Grammar 0.6.26


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.