Repository navigation
fix(arcgis): import MapView from the public @deck.gl/core entry - #10788
Conversation
|
chrisgervang
left a comment
There was a problem hiding this comment.
Thanks - yes, this is a problematic pitfall. I'll accept the regression test if it doesn't add a lot of CI time, and if the risk of a false positive is low.
|
Moving the Verification and Tradeoffs sections out of the PR description so the description follows our PR description guidelines, which ask for a short description without separate verification or test-plan sections. The original text is kept below for reference. Original Verification and Tradeoffs sectionsVerificationNew regression test RED on pristine upstream/master: GREEN after the fix, and the full node project slice passes: Build ( Clean-install resolution check: placed each artifact under
One pre-existing environment failure, not caused by this change: the production IIFE bundle step ( TradeoffsThe ESM dist now imports MapView from the Generated by Claude Code |
|
On the local node run: On Greptile's undeclared |
|
@chrisgervang the CHANGES_REQUESTED from 03-10 is showing an empty body, so I read the open ask as the one from 22:34, the regression test suggestion, which |
|
Please run lint on the test |
|
Formatted in 2894c7b (prettier --write on the spec, one line) and re-run: the cross-package test passes on the branch head. |
* fix(arcgis): import MapView from the public @deck.gl/core entry * test: parse import specifiers instead of matching raw text in cross-package check * Scan module imports with the TypeScript preprocessor * Format the cross-package import test --------- Co-authored-by: Chris Gervang <[email protected]> (cherry picked from commit ed041e5)
|
Released in deck.gl 9.4.1. Thanks @rubenmarcus! |
* fix(arcgis): import MapView from the public @deck.gl/core entry * test: parse import specifiers instead of matching raw text in cross-package check * Scan module imports with the TypeScript preprocessor * Format the cross-package import test --------- Co-authored-by: Chris Gervang <[email protected]> (cherry picked from commit ed041e5)
|
Released in deck.gl 9.3.12. Thanks! |
Closes #10769
Introduced by #10257, which was also backported to 9.3 (first shipped in 9.3.5).
Background
modules/arcgis/src/deck-renderer.tsimportsMapViewfrom'../../core/src/views/map-view'. The build keeps the relative path, so the publisheddist/deck-renderer.jsimports../../core/src/views/map-view.js, which does not exist in the published@deck.gl/core.Change List
DeckRenderer: importMapViewfrom@deck.gl/coredist/index.cjs: 112 kb down to 19 kb, no inlined core sourcesPrepared with AI assistance (GLM 5.3 via Oh My Pi) and reviewed before submission.
Note
Low Risk
Single import-path fix plus a guardrail test; behavior should match the same
MapViewfrom@deck.gl/corewith no auth or data-handling impact.Overview
Fixes broken published
@deck.gl/arcgisbuilds wheredeck-rendererstill referenced core via a relative path (../../core/src/views/map-view) that does not exist in the installed package.DeckRenderernow importsMapViewfrom@deck.gl/core, so the arcgis bundle depends on the public entry instead of inlining or retaining invalid cross-package paths (notably shrinking the CJS build).A new Vitest check walks each package’s
srctree, uses the TypeScript preprocessor to collect import specifiers, and fails if any relative import resolves outside that package—enforcing cross-package imports through entry points like@deck.gl/core.Reviewed by Cursor Bugbot for commit 644be69. Bugbot is set up for automated code reviews on this repo. Configure here.