<.header>

Bad APRS Packets (Showing {length(@bad_packets)} most recent)

Packets that failed to parse or process (limited to 100 most recent) <%= if @last_updated do %> Last updated: {Calendar.strftime(@last_updated, "%H:%M:%S UTC")} <% end %>

<.link navigate={~p"/packets"} class="text-sm text-blue-600 hover:text-blue-800"> View Good Packets → <.link navigate={~p"/"} class="text-sm text-blue-600 hover:text-blue-800"> ← Back to Map
Auto-refreshes every 5 seconds <%= if @loading do %> Updating... <% end %>
<.table id="bad_packets" rows={@bad_packets}> <:col :let={bad_packet} label="Attempted At"> {Calendar.strftime( bad_packet.attempted_at || bad_packet.inserted_at, "%Y-%m-%d %H:%M:%S UTC" )} <:col :let={bad_packet} label="Error Type"> {bad_packet.error_type || "Unknown"} <:col :let={bad_packet} label="Error Message"> {bad_packet.error_message || "No error message"} <:col :let={bad_packet} label="Raw Packet">
{String.slice(bad_packet.raw_packet || "", 0..50)}{if String.length( bad_packet.raw_packet || "" ) > 50, do: "..."}
{bad_packet.raw_packet}
<%= if length(@bad_packets) == 0 do %>

No bad packets

All packets are parsing successfully!

<% end %>