blipson89 / Synthesis

Synthesis is a universal object mapper for Sitecore
MIT License
75 stars 25 forks source link

Synthesis issue with sitecore jss 15.1 #108

Open faeezmaqta opened 2 years ago

faeezmaqta commented 2 years ago

Website develop in Sitecore JSS 15.1 throw below error if rendering cache is enabled

Rendering data contained rendering reference ID a59e99ad-93d1-4d4e-ac14-12aeb038cec4 but that rendering ID was not present in the rendered renderings context. This ought not to occur.

if I disabled. Cache website start working fine

faeezmaqta commented 2 years ago

image

faeezmaqta commented 2 years ago

From my understanding issue is with RenderingDiagnosticsInjector.cs file. when i disabled debug compilation in web.config. I am not facing above issue

blipson89 commented 2 years ago

Hi @faeezmaqta,

the RenderingDiagnosticsInjector is optional. It's there to provide some extra information for developers. However, it wasn't really built with JSS in mind and may not be compatible.

It is safe to remove it from the pipelines without it impacting anything, if it's causing problems.

<pipelines>
  <mvc.getRenderer>
      <processor type="Synthesis.Mvc.Pipelines.GetRenderer.RenderingDiagnosticsInjector, Synthesis.Mvc">
          <patch:delete />
      </processor>
  </mvc.getRenderer>
</pipelines>

Please let me know if removing it helps.

Thanks! Ben