Adds tests for the PromEx supervision module and custom plugin (both
were 0–25% covered), expands the HealthCheck plug to exercise the
readiness success path through the live ShutdownHandler, adds public-API
roundtrip tests for PacketReplay's via_tuple wrappers, and covers
several private-helper fallback branches in Aprsme.Packet
(ParseError data_extended, MicE map symbol defaults, struct
data_extended, weather binary, has_position via legacy lat/lon, PHG /
altitude error parsing).
Wire up prom_ex with built-in Application, Beam, Phoenix, PhoenixLiveView,
and Ecto plugins, plus a custom plugin that exposes the existing
app-specific telemetry (packet pipeline, spatial PubSub, repo pool,
postgres stats, insert optimizer) as Prometheus metrics.
Mount PromEx.Plug at /metrics — internal-only, intended to be scraped
by the cluster's external Prometheus through the kube-apiserver pod
proxy. K8s pod template now carries prometheus.io/{scrape,port,path}
annotations so the existing kubernetes-pods scrape job picks it up
automatically.
PromEx is disabled in the test environment.
Also harden the packet cleanup and partition manager tests with
Repo.delete_all setup hooks so they aren't poisoned by residual rows
committed outside a sandbox transaction in earlier runs (which were
inflating delete counts and triggering ATTACH PARTITION check_violation
errors against packets_default).
Coverage:
- Adds focused tests across 13 files covering previously-uncovered
branches: Packet changeset normalisation (course, wind_direction,
struct data_extended); Packets store_packet edge cases (nested
position shapes, ssid handling, string-keyed raw_packet);
DeviceIdentification HTTP success/404 via Req plug stub; ResendAdapter
catch-all body, deliver_many, nil/binary formatters; ApiDocsLive
packets with missing fields; AprsSymbol normalize helpers;
BadPacketsLive refresh and postgres_notify; MobileChannel handle_info
catch-all and postgres_packet path; PacketProcessor existing-marker
movement detection; PacketReplay sanitize_value type clauses;
InsertOptimizer GenServer lifecycle and negative-duration metric;
PageController shutdown-handler integration; UrlParams delegated
helpers.
- mix.exs: configure test_coverage with summary threshold of 87 and
ignore_modules for test fixtures and macro-only template modules.
Bug fix:
- MapLive.Index handle_info: add a clause for the raw {:new_deployment,
_} tuple. Phoenix.PubSub.broadcast delivers the raw payload to plain
subscribers, but the existing handler only matched the %Broadcast{}
fast-lane wrapper. DeploymentNotifier broadcasts via the raw path,
which crashed the LiveView under test concurrency.
Submodule:
- Update .gitmodules vendor/aprs URL from
https://github.com/aprsme/aprs.git to
ssh://git@codeberg.org/gmcintire/aprs.git.
- Delete config/appsignal.exs (was never wired into mix.exs or any
other config file)
- Migration: fix decrement_packet_sequence trigger to handle the case
where currval() hasn't been called in the current DB session, matching
the same exception handling already present in get_packet_count()
- Fix get_historical_packet_count test: invalid non-list bounds are
silently ignored (no error), so assert is_integer not count == 0
- Add Repo.delete_all(Packet) setup blocks in PacketsOldestTest and
PacketConsumerTest to clear any committed DB state before tests that
depend on an empty packets table
- maxSurge: 1 (explicit integer, avoid percentage rounding)
- minReadySeconds: 30 (was 10) — new pod must be stable longer before old is killed
- progressDeadlineSeconds: 600 — detect stuck rollouts
- readinessProbe failureThreshold: 3 (was 2) — more tolerance after old pod is gone
- Add PodDisruptionBudget minAvailable: 1 — prevents voluntary disruptions from dropping below 1 pod
Forgejo runner with default Docker emits OCI image-index manifests for
multi-arch + attestation builds. argocd-image-updater cannot follow the
index → manifest chain to read the Created timestamp, so it never sees
new tags. Pinning to a single linux/amd64 build with no provenance/sbom
produces a plain Docker v2 manifest that image-updater can read.
Forgejo Actions executes both .github/workflows/ and .forgejo/workflows/.
deploy.yml was a duplicate of .forgejo/workflows/build.yaml that used
docker/build-push-action@v5, which produces OCI image-index manifests
that argocd-image-updater cannot read. Removing it leaves only the
classic-docker-build workflow.
elixir.yaml, claude.yml, claude-code-review.yml, dependency-updates.yml
are kept (no forgejo equivalents).
The previous commit referenced an image tag that was never pushed to the registry,
breaking deploys. Pin to the last working tag until CI produces a new build.
Switch deployment to floating :main tag with imagePullPolicy: Always
and have CI trigger a rollout restart directly via kubectl. Removes
the [skip ci] image-bump commits from main's history.
Requires a KUBECONFIG_DATA secret (base64-encoded kubeconfig with
permission to restart deployment/aprs in the aprs namespace) in
Forgejo Actions.
- consolidate Haversine: CoordinateUtils delegates to GeoUtils;
InfoLive.haversine/4 reuses it (m -> km)
- AprsSymbol: collapse 3 sprite-info builders onto build_sprite_info/2
and add a sprite_info @type
- DataBuilder: 3 weather unit converters share convert_unit/4 with
explicit clauses for "N/A", numeric, and binary inputs
- mobile_channel: do_callsign_match/2 uses pattern-match clauses for
wildcard handling instead of nested if
- info_live: replace nested case in position_changed? with multi-clause
coords_changed?/1; format_timestamp_for_display pipelines into a
guarded build_timestamp_display/1
- api_docs_live: collapse chained single-key assigns into keyword-list
assign/2 calls
- add strict @spec coverage on all touched helpers; tighten new specs to
match dialyzer success typing (no contract_supertype warnings)
Add a client-side userOpenedPopupMarkerId lock that's set instantly when
a user manually opens a popup (via click, OMS spiderfy click, or long-press)
and cleared when the popup closes. All programmatic openPopup paths
(highlight_packet, addMarker openPopup flag) now respect the lock.
Closes the network round-trip race where new packets arriving between
the user's click and the server's marker_clicked ack could steal the popup.
Remove faker, floki, igniter, ecto_psql_extras (zero usages), exvcr
(zero usages), and resend. Replace resend with Aprsme.Swoosh.ResendAdapter
using the already-present req dependency. Frees 23 packages total from
the lockfile including hackney, certifi, and the tesla dependency chain.
Fix two pre-existing test isolation bugs:
- signal_handler_test called the real ShutdownHandler.shutdown() via SIGTERM
simulation without restoring state, causing page_controller_test to see
shutting_down: true and return 503
- page_controller_test setup now resets ShutdownHandler state defensively