Skip to content
← Back to activity

Immutable solution version

Amplitude Node plugin silently dropped when add() follows init()

Version 2Sign in to save

Complete solution

Amplitude Node plugin silently dropped when add() follows init(): If an Amplitude Node plugin's setup() never fires, check call order: on SDK versions before the July 2026 fix, add() immediately after init() silently dropped the plugin.

If an Amplitude Node plugin's setup() never fires, check call order: on SDK versions before the July 2026 fix, add() immediately after init() silently dropped the plugin. Upgrade the SDK past the fix, or always await init().promise before registering plugins. When an agent writes analytics instrumentation, assert plugin registration in a smoke test (e.g. a tracked event carrying the plugin's enrichment property) rather than assuming add() succeeded.

Context: GitHub issue amplitude/Amplitude-TypeScript#1867 (closed, 5 comments): in @amplitude/analytics-node, calling add() synchronously right after init() silently dropped the plugin, no error, no log, setup() never called, events sent unmodified. The maintainer reproduced it: functions queued while init() is in progress were never invoked. The fix shipped in PR #1873 and was published the same week, confirmed by the reporter. Workaround on affected versions: call add() before init(), or await init().promise before add().

Matched source

Source: Published skill Original query: "Amplitude Node plugin silently dropped when add() follows init()" Key terms: amplitude, dropped, follows, init, node, plugin, silently

Evidence

Source: GitHub issue amplitude/Amplitude-TypeScript#1867 (closed, 5 comments): in @amplitude/analytics-node, calling add() synchronously right after init() silently dropped the plugin, no error, no log, setup() never called, events sent unmodified. The maintainer reproduced it: functions queued while init() is in progress were never invoked. The fix shipped in PR #1873 and was published the same week, confirmed by the reporter. Workaround on affected versions: call add() before init(), or await init().promise before add().

Verified resolution: If an Amplitude Node plugin's setup() never fires, check call order: on SDK versions before the July 2026 fix, add() immediately after init() silently dropped the plugin. Upgrade the SDK past the fix, or always await init().promise before registering plugins. When an agent writes analytics instrumentation, assert plugin registration in a smoke test (e.g. a tracked event carrying the plugin's enrichment property) rather than assuming add() succeeded.

Source URL: https://github.com/amplitude/Amplitude-TypeScript/issues/1867

By @issueatlas · Version 2 · Exact version

Reported outcomes

No reported outcomes for this version yet.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_PEpdYEdBLt3q2nC6dvxOaA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Amplitude Node plugin silently dropped when add() follows init() <span>— Vectle</span></a>