Skip to content

"Maximum recursive updates exceeded" message with Vue > 3.4.14 #10510

@lmc3s3f0r

Description

@lmc3s3f0r

Vue version

3.4.21

Link to minimal reproduction

https://github.com/lmc3s3f0r/openlayers_max_recursive_updates_bug

Steps to reproduce

1- Clone the repo linked in the "Reproduction link" field (or here: https://github.com/lmc3s3f0r/openlayers_max_recursive_updates_bug)

2- Run npm install

3- Run it (npm run dev)

4- In Chrome, go to the console and you'll see the message "Uncaught (in promise) Maximum recursive updates exceeded. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function."

Extra: the error message doesn't appear on Vue 3.4.14. To reproduce it:

1- In package.json, change
"vue": "^3.4.21",
to
"vue": "3.4.14",

2- Delete node_modules and package-lock.json

3- Run npm install again

4- Run the project. You won't see the "maximum recursive updates exceeded" message.

What is expected?

I'd expect not to have this error message, same as with Vue 3.4.14.

What is actually happening?

I wish I knew.

System Info

System:
    OS: Linux 6.1 Ubuntu 22.04.4 LTS 22.04.4 LTS (Jammy Jellyfish)
    CPU: (12) x64 13th Gen Intel(R) Core(TM) i7-1355U
    Memory: 17.00 GB / 30.98 GB
    Container: Yes
    Shell: 5.1.16 - /bin/bash
  Binaries:
    Node: 20.10.0 - ~/.nvm/versions/node/v20.10.0/bin/node
    npm: 10.2.3 - ~/.nvm/versions/node/v20.10.0/bin/npm
  Browsers:
    Chrome: 122.0.6261.111
  npmPackages:
    vue: ^3.4.21 => 3.4.21

Any additional comments?

I'm working on a big project with heavy use of OpenLayers maps, and when we recently updated Nuxt and Vue versions, we found this error and we can't figure out where it's coming from (Vue or vue3-openlayers).

The project is quite big so I provided this small version. The error is caused in the file /components/MapOL.vue, line 82. If you comment that line, the error message doesn't appear, but in that case we can't show polygons in the map.

A recent Vue update seemed to fix this error message for many users, but not for our project.

We're currently stuck on Vue 3.4.14 because updating to a higher version causes this error everywhere (and we'd like to update Vue so we can update other packages that need Vue 3.4.19 or higher).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions