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] Can't compile Google Maps Overlay with deck.gl 9.1 #9416

Closed
1 of 7 tasks
ruizmarc opened this issue Feb 8, 2025 · 8 comments
Closed
1 of 7 tasks

[Bug] Can't compile Google Maps Overlay with deck.gl 9.1 #9416

ruizmarc opened this issue Feb 8, 2025 · 8 comments
Labels

Comments

@ruizmarc
Copy link

ruizmarc commented Feb 8, 2025

Description

Hi,

I'm currently using GoogleMapsOverlay in an Angular application with deck.gl 9.0 but after updating to deck.gl 9.1 I cannot compile the project any more as it seems to have problems with @luma dependency.

Flavors

  • Script tag
  • React
  • Python/Jupyter notebook
  • MapboxOverlay
  • GoogleMapsOverlay
  • CARTO
  • ArcGIS

Expected Behavior

I would expect to be able to compile the application

Steps to Reproduce

I'm just trying to build an angular application using GoogleMapsOverlay.

Environment

Logs

Here you have the stack trace I'm obtaining everytime I try to compile the app.

✘ [ERROR] Could not resolve "@luma.gl/webgl"

    node_modules/@deck.gl/google-maps/dist/google-maps-overlay.js:6:28:
      6 │ import { WebGLDevice } from '@luma.gl/webgl';
        ╵                             ~~~~~~~~~~~~~~~~

  You can mark the path "@luma.gl/webgl" as external to exclude it from the bundle, which will remove this error and leave the unresolved path in the bundle.


✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/color-picking.d.ts:16:43:
      16 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...
         ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/index-picking.d.ts:20:43:
      20 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...
         ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/picking-uniforms.d.ts:66:43:
      66 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...
         ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

@ruizmarc ruizmarc added the bug label Feb 8, 2025
@ibgreen
Copy link
Collaborator

ibgreen commented Feb 8, 2025

First, make sure you are including luma.gl v9.1 with deck.gl v9.1. You might have lock file issues keeping luma.gl at 9.0.

@ruizmarc
Copy link
Author

ruizmarc commented Feb 8, 2025

Luma is not among my dependencies in package.json and I guess it should not be there as I’m not directly using it as it is as deck.gl dependency.

In package-lock all luma occurrences are in 9.1. However looking at deck.gl/google-maps in package-lock I can see this:

    "node_modules/@deck.gl/google-maps": {
      "version": "9.1.0",
      "resolved": "https://registry.npmjs.org/@deck.gl/google-maps/-/google-maps-9.1.0.tgz",
      "integrity": "sha512-mF9lfTCq9o2SiYcNTWQUzLa8LZl4so8P4HdLKRMt/Wqrkm7K005vStd9BARXyQa8jz0Y83qOzwPkvRIjSY8qrQ==",
      "license": "MIT",
      "dependencies": {
        "@luma.gl/constants": "^9.1.0",
        "@math.gl/core": "^4.1.0",
        "@types/google.maps": "^3.48.6"
      },
      "peerDependencies": {
        "@deck.gl/core": "^9.1.0",
        "@luma.gl/core": "^9.1.0"
      }
    },

It has no luma.gl/webgl dependency, so maybe it is the reason why it is not being found.

@minghuahuang
Copy link

thanks, you gave me the idea to solve the problem, and I solved the problem.

@Pessimistress
Copy link
Collaborator

Give 9.1.1 a try.

@ruizmarc
Copy link
Author

Hi,

It has been partially solved, but it still show errors...

The error that has dissappeared is this:

✘ [ERROR] Could not resolve "@luma.gl/webgl"

    node_modules/@deck.gl/google-maps/dist/google-maps-overlay.js:6:28:
      6 │ import { WebGLDevice } from '@luma.gl/webgl';
        ╵                             ~~~~~~~~~~~~~~~~

  You can mark the path "@luma.gl/webgl" as external to exclude it from the bundle, which will remove this error and leave the unresolved path in the bundle.

However, we are still seeing the following errors with shadertools from luma.gl

✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/color-picking.d.ts:16:43:
      16 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...
         ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/index-picking.d.ts:20:43:
      20 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...
         ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


✘ [ERROR] TS2307: Cannot find module 'modules/shadertools/dist/lib/utils/uniform-types' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/@luma.gl/engine/dist/modules/picking/picking-uniforms.d.ts:66:43:
      66 │ ...ed<import("modules/shadertools/dist/lib/utils/uniform-types").U...

@ruizmarc
Copy link
Author

FYI: Seems like it is still an issue after updating to 9.1.2

@Pessimistress
Copy link
Collaborator

Try luma.gl v9.1.4

@ruizmarc
Copy link
Author

With luma.gl 9.1.4 works fine! :)

Thanks for the fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants