Skip to content

[LiveComponent] Cannot find a template, cache may be corrupt #2635

Open
@aleho

Description

@aleho

Recently I've been getting more and more errors with live components that are being loaded with lazy or defer in production.

I cannot reproduce it reliably in dev, though I've seen it happen too, but it's reported in multiple projects in production and so far always a live component.

The errors all read something like Uncaught PHP Exception RuntimeException: "Cannot find a template matching "072068688c73461b3e628c8634ef3c51". Cache may be corrupt." at TemplateMap.php line 36".

I've tried to find out what's happening, but I really don't know where to start (given it's hard to reproduce).

Please let me know how I can help to debug this.


This would be the payload for the request that triggers the error above (it's basically an image tag with a signed Google Maps image src):

{
  "props": {
    "link": true,
    "zoom": 13,
    "width": 640,
    "height": 360,
    "scale": 2,
    "markers": [
      [
        "color:#5191AA",
        "label:F",
        "48.144859,16.297634"
      ]
    ],
    "address": null,
    "latitude": "48.144859",
    "longitude": "16.297634",
    "color": "color-primary-500",
    "@attributes": {
      "id": "live-236830884-0",
      "data-host-template": "072068688c73461b3e628c8634ef3c51",
      "data-embedded-template-index": 2368308841,
      "class": "block rounded-md mb-12",
      "img:class": "w-full rounded-md"
    },
    "@checksum": "NGqFvn37BrGIh4jaJErjcwjkpFEjQaMsy0tk0NcJSpk="
  },
  "updated": {}
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions