SShortSingh.
Back to feed

Memory Leak Traced to Uncleared MutationObserver in Dispatch Dashboard Widget

0
·1 views

A routine pull request added an auto-resizing MutationObserver to a telemetry table widget, and QA smoke tests showed flat memory graphs. Six hours into a Monday shift, wallboard monitors running the dispatch app began crashing with Chrome's Out of Memory error. Investigation found that stale closures and an un-disconnected observer kept detached DOM nodes and component trees reachable, so they could not be garbage collected across route changes. An early attempt to fix it by nulling variables in the cleanup function failed because the native observer still held references, and the crashes continued. The proper fix involves disconnecting observers and cancelling fetch streams through a unified AbortController teardown path.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Voice agent evaluators can be less reliable than the agents they grade

Rokas Remeika argues that regex-based scoring in voice agent evaluation pipelines introduces significant noise. Spontaneous speech often omits expected words, causing false negatives, while negated phrasing like "I would not say no" can trigger false refusal flags. These scoring errors can shift aggregate pass rates between evaluation runs even when the agent and model are unchanged. The author proposes a two-tier system that uses strict deterministic matching first, marking uncertain cases as unresolved, and escalates only those to an independent model for adjudication. He suggests practical checks, such as auditing unclassifiable transcripts and rerunning static batches under different scorer versions, to detect this instrument error.

0
ProgrammingDEV Community ·

Filter Toggle Causes 180 ms Interaction Delay and Layout Shift in Catalog Pages

A design-system pull request added a compact-density toggle to a catalog filter bar, but it caused problems on production pages despite working well in local testing. Telemetry showed the 75th-percentile Interaction to Next Paint on mid-tier Android devices rising from 38 ms to 180 ms, while Cumulative Layout Shift spiked to 0.14 as the sticky toolbar moved on each click. Investigation traced the cause to a root CSS variable update, an unstable context value object, and a layout effect that interleaved reads and writes, forcing repeated synchronous layouts. A React.memo hotfix did not help in production. The fix involved wrapping the grid filter update in a transition so the pressed chip could paint before the heavier reconciliation completed.

0
ProgrammingDEV Community ·

Researcher finds Windows 11 build flags coding agent use in optional telemetry

Security researcher Xusheng Li, who works on Binary Ninja, reports that one Windows 11 build keeps a daily yes-or-no flag indicating whether coding agents such as Codex, Claude Code and Copilot were seen running. His findings come from analysis of a single ARM64 virtual machine and Microsoft's documentation, and Microsoft had not commented at the time of reporting. According to Li, the component listens to events Windows already produces and records only which tracked program names appeared, not prompt text or source code. He found the resulting report in a diagnostics upload queue marked as optional, though he observed it being queued rather than leaving the machine. Li also noted that matching relies on executable names, meaning a renamed file could set a flag and a real agent under another name might go uncounted, and that the number of affected PCs is unknown.

0
ProgrammingDEV Community ·

PostgreSQL JSONB Columns Can Cause Heavy Write Amplification Under Frequent Updates

A developer's local benchmark found that incrementing one integer inside a 3.4 KB JSONB column generated about 142 MB of Write-Ahead Log traffic over 20,000 updates, roughly eight times more than updating dedicated scalar columns for the same change. The article attributes this to PostgreSQL's storage mechanics: JSONB values are stored as a single binary object, so any change rewrites the entire value and locks the whole row. Once a JSONB column exceeds the TOAST threshold, even a one-byte change allocates new TOAST chunks, which are written again and logged to WAL, leaving dead tuples behind. Indexing the column with GIN also rules out Heap-Only Tuple updates, forcing new index entries and occasional latency spikes. The author concludes that JSONB suits read-heavy workloads but can strain disk I/O, replication, and VACUUM when frequently mutated.

Memory Leak Traced to Uncleared MutationObserver in Dispatch Dashboard Widget · ShortSingh