hashgraph / hashgraph/solo-weaver

fix(ui): `block node reconfigure` prints two summary footers, the first claiming success on a failed run

Open
#1,059 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
3
Forks
0
Avg merge
3d 5h
Merged PRs (30d)
47

Description

## Problem

`block node reconfigure` prints the summary footer twice, and the first one says the
run succeeded even when the command goes on to fail. Trimmed from a real run:

```
─────────────────────────────────────────────────
Completed successfully
Duration: 1m18.08s
Report: /opt/solo/weaver/logs/setup_report_20260821_164129.yaml
─────────────────────────────────────────────────
...
─────────────────────────────────────────────────
Completed with errors
Duration: 3.429s
Report: /opt/solo/weaver/logs/setup_report_20260821_164132.yaml
─────────────────────────────────────────────────
Error: common.internal_error: failed to download daemon binary version 0.28.2 ...
```

Anyone skimming the output sees `Completed successfully` on a command that failed. Two
report files are written for one invocation, and neither describes the whole thing.

## Mechanism

`RenderSummaryTable` (`internal/ui/view.go:293`) is rendered once per `RunWorkflow`
call (`cmd/cli/commands/common/run.go:81`), and `reconfigure` runs two workflows in
sequence:

1. the block-node reconfigure workflow, then
2. `ensureBlockNodeDaemon` -> `provisionBlockNodeDaemon` -> `RunWorkflowBuilder`
(`cmd/cli/commands/block/node/daemon_offer.go:220`, invoked from
`cmd/cli/commands/block/node/reconfigure.go:167`)

So it is not a duplicated print; it is one footer per workflow, with no notion of the
command as a whole. `install` shares the same resolver and is likely affected too.

## Proposed fix

Either of:

* Make daemon provisioning a phase of the main workflow, so there is one workflow, one
footer and one report per invocation. Cleanest, and the phase list then reflects what
actually ran.
* Keep the two workflows but suppress the intermediate footer, rendering a single
summary at the end whose status is the aggregate. Smaller change; needs a way to mark
a `RunWorkflow` call as non-terminal.

Whichever is chosen, no footer should claim success while the invocation still has work
that can fail.

## Acceptance

- [ ] `block node reconfigure` (and `install`) print exactly one summary footer.
- [ ] That footer's status reflects the whole invocation: a failed daemon install cannot
leave a `Completed successfully` banner on screen.
- [ ] One report path per invocation, covering every step that ran.
- [ ] Verified in both TUI and `--non-interactive` output modes.

Contributor guide

Open the contributing guide

Research direction

Trace RunWorkflow in cmd/cli/commands/common/run.go and RenderSummaryTable in internal/ui/view.go, then follow the reconfigure and daemon provisioning paths in cmd/cli/commands/block/node/reconfigure.go and daemon_offer.go. Exercise block node reconfigure and install in both TUI and --non-interactive modes. Done means one aggregate footer and report per invocation, with status covering every workflow step.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.