{"record":{"id":"ea20f26d21d155f9","repo":"Meituan-Dianping/mpvue","slug":"31m-msg-39m","errorCode":null,"errorMessage":"\n\u001b[31m${msg}\u001b[39m\n","messagePattern":"\n\u001b\\[31m(.+?)\u001b\\[39m\n","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/server/render.js","lineNumber":24,"sourceCode":"  isTrue\n} from 'shared/util'\n\nimport { escape } from 'web/server/util'\nimport { SSR_ATTR } from 'shared/constants'\nimport { RenderContext } from './render-context'\nimport { ssrCompileToFunctions } from 'web/server/compiler'\nimport { installSSRHelpers } from './optimizing-compiler/runtime-helpers'\n\nimport {\n  createComponent,\n  createComponentInstanceForVnode\n} from 'core/vdom/create-component'\n\nlet warned = Object.create(null)\nconst warnOnce = msg => {\n  if (!warned[msg]) {\n    warned[msg] = true\n    console.warn(`\\n\\u001b[31m${msg}\\u001b[39m\\n`)\n  }\n}\n\nconst normalizeRender = vm => {\n  const { render, template, _scopeId } = vm.$options\n  if (isUndef(render)) {\n    if (template) {\n      Object.assign(vm.$options, ssrCompileToFunctions(template, {\n        scopeId: _scopeId\n      }))\n    } else {\n      throw new Error(\n        `render function or template not defined in component: ${\n          vm.$options.name || vm.$options._componentTag || 'anonymous'\n        }`\n      )\n    }\n  }","sourceCodeStart":6,"sourceCodeEnd":42,"githubUrl":"https://github.com/Meituan-Dianping/mpvue/blob/6c5d78ee04f58c6d782c456dfcf0fe63c0b7f89b/src/server/render.js#L6-L42","documentation":"This is warnOnce, the SSR bundle renderer's de-duplicating warning wrapper: a red-colored console.warn used for one-time diagnostics during server-side rendering (called from renderComponent and similar paths). The template is a generic sentinel — it wraps any msg string with ANSI red color codes and a leading/trailing newline — so the actual fault is only identifiable from the interpolated message content; the 'warned' map ensures each distinct message is only printed once per render pass.","triggerScenarios":"Thrown at src/server/render.js:24 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the inner msg text of the printed warning to identify the real SSR problem (often unhandled render errors or missing assets during server rendering)","Reproduce with verbose SSR logging (renderer.renderToString callbacks, bundleRenderer options like runInNewContext tweaks) to get the component trace","Fix the underlying component issue surfaced by the wrapped message — the wrapper itself needs no code change"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6c5d78ee04f58c6d782c456dfcf0fe63c0b7f89b","analyzedAt":"2026-09-02T05:17:40.946Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-09T11:17:12.671Z"}