079346a1b9
fix: resolve all 281 credo issues across source and test files
...
Build and Push / Build and Push Docker Image (push) Failing after 4m38s
- F-level (228): replace length/1 with Enum.count_until/2 or pattern
matching; convert Enum.flat_map+if to Enum.filter+Enum.map; fix
identity case in narr_client
- W-level (46): normalize dual atom/string key access in weather_layers,
beacon_measurements, surface, skewt_live, contact_live/show; add
:data_provider and weather-map assigns to ignored_assigns in credo
config (consumed by child components credo can't trace); remove
weak is_list assertion; remove explicit assert_receive timeout
- R-level (6): replace 'This module provides...' moduledocs with
meaningful descriptions
- Also fix 4 compile-connected xref issues by deferring
BandConfig.band_options() from module attribute to runtime
Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-29 09:04:21 -05:00
cb8445f329
fix: resolve 158/183 credo --strict warnings
...
- Add 17 missing @spec annotations (layouts, error_json, error_html, skewt_svg)
- Move 12+ nested alias/import/require to module top level
- Add phx-change/id attributes to 11 raw HTML <form> tags
- Remove 4 unused LiveView assigns (:bounds, :data_provider)
- Add 3 missing doctest references (HrrrNativeClient, BulkFetch, Accounts)
- Break 2 long lines (path_compute.ex:382)
- Strengthen weak test assertions (is_binary→byte_size, is_list→!=[])
- Replace Module.concat with Module.safe_concat (2 occurrences)
- Replace length/1 > 0 with list != [] (9 occurrences)
- Remove no-op assert true, fix no-assertion tests
Remaining: 24 socket.assigns introspection warnings (deliberate test
pattern for observable behavior testing), 1 formatter-resistant long
line, 3 app-code usage warnings.
2026-06-12 15:47:15 -05:00
bbf51544e1
test: coverage round 2 (82.05% → 83.96%) + 23 new property tests
...
77 unit tests + 23 property tests across four parallel agents.
- ContactLive.Show (72.01% → ~75%): every factor-note branch
(humidity/time/td/refractivity/pressure/season/pwat), all
propagation_mechanism classifications, apply_admin_edit/owner_edit/
submit_user_edit error paths, internal_network? IP shapes, expanded
sounding skew-T, composite-score [0,100] property.
- PathLive + BeaconLive.Show + Weather: coordinate-pair resolver,
invalid grid, empty-DB edge cases for iemre_for_*, narr_for_*,
nearest_native_duct_*, find_nearest_rtma, recent_surface_obs;
properties for round_to_hrrr_grid/round_to_iemre_grid/band
round-trip/beacon-id URL round-trip.
- Viewshed + Duct + SoundingParams: find_reach_km edge cases,
destination_point, effective_reach_km fractions, detect_ducts
trailing-duct + guard branches; 13 properties including flat-
terrain-fully-visible, thicker-duct-lower-freq, M-profile
monotonicity, feature-vector deterministic length.
- Workers + Mix tasks: GefsFetchWorker 500/429/403 + malformed
ISO8601, HrrrNativeGridWorker snap-to-3-decimals + empty DB,
IonosphereFetchWorker 404 + non-tabular body, RadarBackfill
--dry-run + --year + --limit, NexradBackfill --limit 0, Backtest
--feature + --all; year-filter property covering 2015..2026.
170 → 205 properties, 2666 → 2743 tests, 0 failures.
2026-04-24 10:15:37 -05:00
82bf248ab7
Phase 4: Ray-traced duct geometry
...
Duct module (Propagation.Duct):
- refractivity_profile/1: ITU-R P.453 N at each native level
- m_profile/1: modified refractivity M = N + 157*h(km)
- detect_ducts/1: find contiguous regions where dM/dh < 0, returning
base/top height, thickness, and M-deficit per duct
- min_trapped_frequency_ghz/1: waveguide approximation (Bean & Dutton)
for the minimum frequency a duct of given geometry can trap
- analyze/1: full pipeline from native profile to duct list + best
trapped frequency across all ducts
Derive task updated to also compute ducts JSONB and best_duct_band_ghz
alongside the Phase 2 turbulence fields.
Backtest features: duct_thickness, best_duct_freq, duct_usable_10ghz,
duct_usable_24ghz, duct_usable_47ghz.
Real-data validation: 2022-08-20 12Z TX profile shows 0 ducts (M
increases monotonically) — correct for a well-mixed boundary layer
on a turbulent August afternoon (Ri=0.16).
2026-04-10 08:31:16 -05:00