weewx-xtide 3.0
The sample tide report now speaks nine languages, and two significant bugs
are fixed: WeeWX failed to start with weewx-xtide installed on systems
running a non-English locale, and tide stations in a different timezone than
the WeeWX server got shifted or missing events. No weewx.conf changes are
needed; this is a drop-in upgrade for English reports, and one lang line
turns on a translation.
What's new
-
The sample report is internationalized. Nine languages ship: English,
Danish, Dutch, French, German, Italian, Norwegian, Spanish and Swedish.
Pick one by settinglangon the report's stanza in weewx.conf (e.g.
lang = deunder[StdReport] [[XTideReport]]); the default remains
English. A missing translation falls back to English one string at a
time. Date formats follow the report language; month and weekday names
come from the server's locale, as in WeeWX itself (use a full locale name
such aslang = de_DE.UTF-8to localize them too). The non-English
translations are Beta, pending native-speaker review — corrections are
welcome as GitHub issues. Details in the manual:
Translating the tide page. -
A user manual. Installation, configuration, the
$xtide.events()
and$xtide.graph()tags, and translating, at
chaunceygardiner.github.io/weewx-xtide. -
weewx-xtide no longer crashes WeeWX startup under non-English locales.
The tide program's event times are always English ("9:16 AM UTC"), but they
were parsed with a locale-dependent AM/PM directive, and most non-English
locales (German, French, Danish, Spanish, ...) define empty AM/PM
designators — so parsing failed and WeeWX could not start. The AM/PM token
is now handled explicitly; no locale affects it. -
Stations in a different timezone than the server now get correct
events. Event times were parsed in the server's local timezone, so a
station elsewhere got events shifted by the timezone difference, or none at
all when the timezone abbreviation wasn't recognized. The tide program is
now run in UTC mode (-z) and all times are handled in UTC, so any
station/server combination works. Stations in the server's own timezone
were always correct and are unaffected. This also fixes a possible
one-hour error during the repeated hour of the autumn DST fall-back. -
24-hour time labels where the locale calls for them. The sample skin's
graph and tide-list labels use 24-hour form when the system locale has no
AM/PM designators (as in most of continental Europe), where "9:16 AM" would
have rendered as an ambiguous "9:16". Translated reports use each
language's own date and time forms regardless of the server locale. -
xtide.py --test-serviceworks again. It now honors--locationand
--prog; it previously ignored them in favor of a hard-coded location and
a tide path that no longer exists.
Requirements
- Python 3.10
- WeeWX 4 or 5
- The xtide package (see the README)
Installing/upgrading
Download weewx-xtide.zip from this release, then:
weectl extension install weewx-xtide.zip
Restart WeeWX. No weewx.conf changes are needed when upgrading from 2.x —
add lang = <code> to the report's stanza only if you want a translated
page. Note that upgrading replaces the bundled skin (skins/xtide/) — if
you customized it, save a copy first.







