Skip to content

fix(events): pin leaflet.markercluster to 1.x to restore the frontend build - #4114

Merged
chubes4 merged 1 commit into
mainfrom
fix/events-markercluster-build
Nov 29, 2026
Merged

chubes4 merged 1 commit into
mainfrom
fix/events-markercluster-build

Conversation

@chubes4

@chubes4 chubes4 commented Nov 29, 2026

Copy link
Copy Markdown
Member

Problem

Dependabot #4100 (e7cf3b9b4) bumped leaflet.markercluster from ^1.5.3 to ^2.0.0. Version 2.0.0 no longer ships dist/MarkerCluster.css; only MarkerCluster.Default.css is left. inc/Blocks/EventsMap/src/frontend.tsx imports both, so npm run build fails:

ERROR in ./inc/Blocks/EventsMap/src/frontend.tsx 28:0-54
Module not found: Error: Package path ./dist/MarkerCluster.css is exported from package .../leaflet.markercluster, but no valid target file was found

Downstream effects since then:

Fix

Pin leaflet.markercluster back to ^1.5.3 and refresh the lockfile. v2 is also an ESM rewrite with a different plugin-registration model, so a major upgrade needs its own change.

Verification

  • npm ci && npm run build in plugins/data-machine-events: compiles with no errors (it failed on main before this change).

Also noticed (not fixed here)

The test script (wp-scripts test-unit-js) now requires Vitest after the same @wordpress/scripts bump. Switching it to wp-scripts test-unit-jest (or migrating) is a separate change.

AI disclosure

Diagnosed and fixed by Extra Chill Bot (Claude) by hand, outside Homeboy. It unblocks the release of #4111 (Dice/Ticketmaster big-city coverage).

… build

Dependabot #4100 bumped leaflet.markercluster to 2.0.0, which no longer ships
dist/MarkerCluster.css. EventsMap's frontend imports it, so npm run build fails.
That breaks the wp_codebox_prepare_steps CI step and release packaging
("Package command completed without required frontend assets").
@chubes4
chubes4 merged commit 4b74681 into main Nov 29, 2026
6 checks passed
@chubes4
chubes4 deleted the fix/events-markercluster-build branch November 29, 2026 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant