Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .bestpractices.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@
"vulnerability_report_response_status": "N/A",
"vulnerability_report_response_justification": "The maintainer confirmed on 2026-09-05 that no private vulnerability reports were received in the preceding six months; the project advisory list was also empty. The policy requires acknowledgment within 14 days for future reports. https://github.com/lennrt/tempestkeep/blob/main/SECURITY.md https://github.com/lennrt/tempestkeep/blob/main/docs/openssf.md",
"build_status": "Met",
"build_justification": "The source builds with Go 1.27.2 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"build_justification": "The source builds with Go 1.27.3 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"build_common_tools_status": "Met",
"build_common_tools_justification": "The source builds with Go 1.27.2 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"build_common_tools_justification": "The source builds with Go 1.27.3 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"build_floss_tools_status": "Met",
"build_floss_tools_justification": "The source builds with Go 1.27.2 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"build_floss_tools_justification": "The source builds with Go 1.27.3 and make using CGO_ENABLED=0. Go and make are FLOSS; no proprietary build tool is required. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/README.md",
"test_status": "Met",
"test_justification": "The MIT-licensed Go test suite runs with make test or go test ./... -count=1 -timeout=5m, and in GitHub CI. https://github.com/lennrt/tempestkeep/blob/main/Makefile https://github.com/lennrt/tempestkeep/blob/main/CONTRIBUTING.md",
"test_invocation_status": "Met",
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ body:
attributes:
label: Environment
description: Include the operating system, architecture, and `go version` when relevant.
placeholder: macOS arm64; go version go1.27.2 darwin/arm64
placeholder: macOS arm64; go version go1.27.3 darwin/arm64
validations:
required: true
- type: textarea
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand All @@ -88,15 +88,15 @@ jobs:
run: go build ./...

verify:
name: Go 1.27.2 verification
name: Go 1.27.3 verification
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand Down Expand Up @@ -130,7 +130,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand All @@ -147,7 +147,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand All @@ -171,7 +171,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/demo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: "1.27.2"
go-version: "1.27.3"
check-latest: false
cache: true

Expand Down
53 changes: 53 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,58 @@
# Changelog

## 0.5.0 (proposed, unreleased)

This development batch contains ten improvements:

1. Pair temperature with humidity or wind from the same observations for
comfort calculations, so unrelated samples cannot create apparent extremes.
2. Preserve missing historical rainfall as null, expose sample counts, and
average rain normals over rain-contributing months with `rain_years`.
Keep missing rain buckets as gaps in the terminal day chart.
3. Create distinct nanosecond backup names, retry bounded collisions, and
retain both legacy and new names in chronological order.
4. Select the newest accepted live observation by timestamp, independent of
response order, with the first row winning equal timestamps.
5. Reuse the existing archive device for unattended CLI collection when no
explicit selector exists. New or unbound empty archives still discover a device.
6. Add read-only offline `status` text and JSON reports for archive freshness,
saved backfill state, and bounded internal gaps.
7. Show daily forecast high, low, and maximum rain probability in app cards.
8. Add bounded long-cell inspection and SQL text search beyond cell previews.
9. Preserve keyboard focus after changing the selected app dataset.
10. Reject explicit zero CLI collection device selectors before archive or API
access, consistent with the positive-ID contract.

### Supporting security repair

- Require Go 1.27.3 for builds and checks to fix
[GO-2026-6809](https://pkg.go.dev/vuln/GO-2026-6809) in the standard library.
Rebuild older binaries with the patched toolchain. This repair supports the
ten improvements above and does not change language dependencies. See
[ADR 0020](docs/adr/0020-go-security-patch.md).

### Compatibility

Go callers must handle nullable `DayStat.RainIn`, `PeriodStat.RainIn`,
`YearDay.RainIn`, `MonthNormal.AvgRainIn`, and `MonthNormal.AvgRainyDays`.
Historical JSON rain fields now encode numbers or explicit null. Additional
`rain_readings` and `rain_years` fields describe samples, not continuous coverage.
Partial months still contribute their available rain totals to normals.

CLI collection without a selector now follows existing archive identity rather
than the first accessible live device. Nonempty zero environment selectors fail
for CLI collection. MCP retains its automatic zero environment selection rule.
Existing archives need no schema migration. Backup naming changes, while
retention continues to recognize legacy names. Dependencies remain unchanged.
Metadata reads now enforce the writer's existing 4,096-byte and NUL limits
in UTF-8 bytes, including when SQLite stores text as UTF-16.
Oversized, null, or NUL-containing stored values return `ErrInvalidArchive`.

Active development, plugin, and app metadata target 0.5.0. Untagged fallback
builds report `v0.5.0-dev`. Historical release records below remain unchanged.
No tag, release, plugin publication, or merge is part of this development change.
Qualification still follows [RELEASING.md](RELEASING.md).

## 0.4.0 (proposed, unreleased)

### Added
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ review; do not submit only a final source archive.

## Prerequisites

- Go 1.27.2.
- Go 1.27.3.
- A Unix-like shell and make for the Makefile and shell scripts.
- A C toolchain for race tests.
- Network access to the Go module proxy for the first tool download.
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ NPM ?= npm
VHS ?= vhs
BIN_DIR ?= bin

GO_VERSION := 1.27.2
GO_VERSION := 1.27.3
GOIMPORTS_VERSION := v0.44.0
GOLANGCI_LINT_VERSION := v2.14.0
ACTIONLINT_VERSION := v1.7.12
Expand Down
35 changes: 29 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,21 +36,30 @@ credentials described below.

| Explore | In the app |
|---|---|
| Daily forecast | Read daily high, low, and maximum rain probability, then switch to hourly details. |
| Weather over time | Switch metrics, inspect chart points with pointer, touch, or keyboard, and explore the wind rose. |
| Archive and SQL results | Search rows, sort columns, and move between table pages. |
| Archive and SQL results | Search rows, inspect long cells, sort columns, and move between table pages. |
| Several stations | Find device IDs beside their parent station names for use in configuration. |
| Updated results | Refresh the same read-only tool with its original arguments. |
| Your working environment | Use responsive views that follow the host's light or dark theme. |

![Searchable archive table in the TempestKeep MCP App](docs/screenshots/mcp-app-table.png)

*Synthetic table data in the local MCP Apps test host, captured with Playwright.*

![Daily forecast cards and table in the TempestKeep MCP App](docs/screenshots/mcp-app-forecast.png)

*Synthetic daily forecast. Cards summarize the returned days, including the
highest rain probability. Missing values remain unavailable.*

Search and pagination cover the returned rows. Views display up to 2,000 rows
and 64 columns, with a notice when a limit applies. If a server limit truncates
the result, narrow the tool request before drawing conclusions about the archive.
Missing readings remain distinct from zero. The app does not run archive writes.
Observation-series views show when rain or lightning readings are missing or
partial. Available totals do not imply complete sensor coverage.
Historical rainfall tables also distinguish missing rain, measured zero, and
partial totals. Their reading counts describe samples, not uninterrupted coverage.

MCP Apps support depends on the host and its version. Clients without the
extension retain the existing text and structured tool results. See the
Expand Down Expand Up @@ -94,7 +103,7 @@ See the [MCP guide](docs/mcp.md) for configuration, capabilities, and limits.

### Build

You need Go 1.27.2 and a local filesystem for SQLite. Live data and collection
You need Go 1.27.3 and a local filesystem for SQLite. Live data and collection
also need a WeatherFlow personal access token. The build commands below use
`make` and a Unix-like shell. The normal build uses pure Go. Race tests need
a C toolchain.
Expand Down Expand Up @@ -229,6 +238,7 @@ tempestkeep list-devices List stations and device identifiers.
tempestkeep collect Create or update the archive.
tempestkeep now Show current conditions and forecast.
tempestkeep explore Explore archived days, months, and records.
tempestkeep status Inspect archive freshness and internal gaps.
tempestkeep stats Print archive statistics.
tempestkeep export Write CSV or JSON Lines to stdout.
tempestkeep mcp Serve live and archived data over MCP stdio.
Expand All @@ -253,10 +263,14 @@ Left/Right (or h/l) moves between periods, `d/w/m/y/r` selects a view, and Tab
cycles the month/year metric. The `g` or Home key returns to the latest period.
The `q`, Esc, and Ctrl+C keys exit either dashboard.

In the day view, a gap in the rain sparkline means that no rain reading exists.
The lowest block represents zero or a small positive reading. Partial summary
rain totals carry a `≥` marker.

`tempestkeep version` reports the build's injected version, then Go's module
version when available. If neither exists, it falls back to `v0.4.0-dev`.
version when available. If neither exists, it falls back to `v0.5.0-dev`.
`make build` injects a version from Git tags or that development fallback.
Version 0.4.0 is the proposed next minor release. See [CHANGELOG.md](CHANGELOG.md)
Version 0.5.0 is the proposed next minor release. See [CHANGELOG.md](CHANGELOG.md)
for its scope. This change does not publish a release.

## Archive behavior
Expand All @@ -270,6 +284,15 @@ one transaction. Observation inserts use the `(device_id, epoch)` key, so replay
does not create duplicate rows. Open-ended collection stores a cursor after each
committed chunk and resumes from that cursor after interruption.

Without an explicit device selection, CLI collection reuses an existing
archive's device. New archives and empty archives without a saved device discover
the first accessible Tempest device. An empty archive with a saved device keeps
that device. Explicit zero device IDs fail before archive or API access.

Use `tempestkeep status --format json` to inspect an archive without a token.
It reports freshness, saved backfill state, and up to ten internal gaps over
one hour. Sample timestamps do not establish continuous sensor coverage.

The default `tempestkeep collect` run creates a timestamped backup after a
successful checkpoint. Backups live in the `backups` directory beside the
archive. A private temporary copy becomes a snapshot without replacing an
Expand Down Expand Up @@ -309,7 +332,7 @@ See [SECURITY.md](SECURITY.md) for private reporting and the

## Verification

Run the repository checks with Go 1.27.2:
Run the repository checks with Go 1.27.3:

```sh
make fmtcheck # gofmt and goimports
Expand Down Expand Up @@ -397,7 +420,7 @@ Tempest names and marks belong to their respective owners. See [NOTICE.md](NOTIC

TempestKeep uses the MIT License. See [LICENSE](LICENSE).

[version-badge]: https://img.shields.io/badge/development-v0.4.0--dev-blue
[version-badge]: https://img.shields.io/badge/development-v0.5.0--dev-blue
[ci-b]: https://img.shields.io/github/actions/workflow/status/lennrt/tempestkeep/ci.yml?branch=main
[ci]: https://github.com/lennrt/tempestkeep/actions/workflows/ci.yml
[license-badge]: https://img.shields.io/github/license/lennrt/tempestkeep
Expand Down
6 changes: 3 additions & 3 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ remains disabled until a separate reviewed change enables an approved release.
- Obtain explicit release approval.
- Select one reviewed commit with a clean working tree.
- Require all configured GitHub checks to pass for that commit.
- Use Go 1.27.2.
- Use Go 1.27.3.
- Confirm that no credential, station data, archive, export, personal path, or
raw API response is present in tracked, untracked, ignored, or generated
files.
Expand All @@ -29,7 +29,7 @@ Choose a semantic version. Do not reuse or move a published tag.

Use `vMAJOR.MINOR.PATCH` for release tags and the corresponding SemVer version
for artifacts. Development snapshots retain the exact source commit as their
unique identifier; `v0.4.0-dev` alone does not identify a source revision.
unique identifier; `v0.5.0-dev` alone does not identify a source revision.

Update [CHANGELOG.md](CHANGELOG.md) with a human-readable account of changes,
compatibility effects, and upgrade instructions. Include every publicly known
Expand All @@ -48,7 +48,7 @@ make integration e2e
make release-check
```

The Go version must be exactly 1.27.2. The first three commands must pass. The
The Go version must be exactly 1.27.3. The first three commands must pass. The
last command creates local snapshot archives in `dist/` without publishing them.

Inspect every archive. Confirm that it contains the `tempestkeep` binary,
Expand Down
2 changes: 1 addition & 1 deletion SUPPORT.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Do not put sensitive station data in either channel.
[docs/README.md](docs/README.md).
2. Read the [troubleshooting guide](docs/troubleshooting.md) for known recovery steps.
3. Run `tempestkeep help <command>` or inspect the MCP tool description.
4. Reproduce the problem with the default branch and Go 1.27.2 when practical.
4. Reproduce the problem with the default branch and Go 1.27.3 when practical.
5. Run the smallest relevant check from [CONTRIBUTING.md](CONTRIBUTING.md).

## Include
Expand Down
Loading
Loading