Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

A Live Hub shows and counts only real Nodes

Closed
#95 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@Fazorath is already working on this.

Since Oct 28, 2026.

  • #103 by @Fazorath — merged

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript

Research direction

Start with docs/specs/live-or-replay.md, then trace the /api/state handler, Reading Store snapshot, Node Registry, and MeshedNodes harness named in the issue. Check how the existing Stale window and Hazard trigger work, and run the tests through the API. Done means the acceptance criteria pass, including matching Hub and Sensor state and scripts/check.sh passing.

Written by the indexing model from the issue text.

Description

area: node feature ready-for-agent

Parent

#89

What to build

Live readings win. A Hub is a Live Hub while it hears a Community Reading that is not a Simulated Reading from a Registered Node that is not Stale. Every Node judges "live" the same way, in one place, from its Reading Store snapshot and the Node Registry it has heard, so a Sensor's dashboard filters the same Nodes as the Hub's.

/api/state gains live: bool, the dashboard's only signal. While it is true, nodes lists only the Nodes whose latest reading is not simulated, flood_risk reads only their readings, and the Hazard trigger reads only real readings, so no Community Warning or flood email comes from a Simulated Reading on a live map. A Community Warning already issued stays in the Hub's log.

An Unverified Node's real reading does not make a Hub live. A real Node going Stale (the existing Stale window) stops making it live.

Since no Sensor produces a real reading yet, the test harness gains a way to hand-feed a reading that is not simulated, standing in for a Sensor with hardware.

Spec

docs/specs/live-or-replay.md

Acceptance criteria

  • A registered, non-Stale, non-simulated reading makes /api/state report live: true
  • While live, nodes holds only Nodes whose latest reading is not simulated, and flood_risk comes from their readings alone
  • While live, a surging simulated Node raises no Flood Risk, no Community Warning and no flood email
  • An Unverified Node's real reading does not make the Hub live
  • The Hub stops being live once the last real Node goes Stale, and simulated Nodes show again
  • A Sensor's /api/state agrees with the Hub's on live and the Nodes listed
  • The MeshedNodes harness can send a non-simulated reading; tests drive Nodes through the API only
  • Rehearsed locally with hand-fed readings only; no Pi or sensor check claimed
  • scripts/check.sh passes

Blocked by

  • None (can start immediately)
Dominant language
TypeScript
Stars
1
Forks
0
Avg merge
48m
Merged PRs (30d)
52

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from StormShields/Stormshield

All issues in StormShields/Stormshield

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.