Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Error during ModifyMode over non-EditableGeoJsonLayer #152

Open
1 of 8 tasks
lawrencenika opened this issue Nov 5, 2024 · 0 comments
Open
1 of 8 tasks

[Bug] Error during ModifyMode over non-EditableGeoJsonLayer #152

lawrencenika opened this issue Nov 5, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@lawrencenika
Copy link

Module

  • deck.gl-community/arrow-layers
  • deck.gl-community/bing-maps
  • deck.gl-community/editable-layers
  • deck.gl-community/experimental
  • deck.gl-community/graph-layers
  • deck.gl-community/layers
  • deck.gl-community/react
  • deck.gl-community/react-graph-layer

Description

When I have both EditableGeoJsonLayer and H3ClusterLayer map shown and my draw mode is Modify mode, hover over on H3ClusterLayer will cause slowness, and console error:

hook.js:608 deck: update of EditableGeoJsonLayer({id: 'train_stations_europe.csv'}): Cannot read properties of undefined (reading 'type') TypeError: Cannot read properties of undefined (reading 'type')
at ModifyMode.getGuides (modify-mode.js:40:48)
at CompositeMode.getGuides (composite-mode.js:48:36)
at EditableGeoJsonLayer.createGuidesLayers (editable-geojson-layer.js:376:29)
at EditableGeoJsonLayer.renderLayers (editable-geojson-layer.js:260:37)
at EditableGeoJsonLayer._postUpdate (composite-layer.js:198:40)
at EditableGeoJsonLayer._update (layer.js:810:18)
at LayerManager._updateLayer (layer-manager.js:319:19)
at LayerManager._updateSublayersRecursively (layer-manager.js:271:26)
at LayerManager._updateLayers (layer-manager.js:234:14)
at LayerManager.setLayers (layer-manager.js:174:14)
at LayerManager.updateLayers (layer-manager.js:185:18)
at Deck._onRenderFrame (deck.js:736:27)
at AnimationLoop._renderFrame (animation-loop.js:263:20)
at AnimationLoop.redraw (animation-loop.js:161:14)
at AnimationLoop._anima

This is gone when I removed the EditableGeoJsonLayer from DeckGL. How to prevent this from happening?

Expected Behavior

When in ModifyMode it should not interfact with non-EditableGeoJsonLayer like above.

Steps to Reproduce

const [drawMode, setDrawMode] = useState(
() =>
new CompositeMode([
new TranslateMode(),
new ModifyMode(),
new ViewMode(),
]),
);

Environment

  • Framework version:
    "@deck.gl-community/editable-layers": "^9.0.3",
    "@deck.gl/layers": "^9.0.28",
    "@deck.gl/react": "^9.0.28",
  • Browser: Chrome based Arc
  • OS: MacOS

Logs

No response

@lawrencenika lawrencenika added the bug Something isn't working label Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant