{"record":{"id":"f73de1e11c744815","repo":"cube-js/cube","slug":"cannot-access-property-string-prop-on-inst","errorCode":null,"errorMessage":"Cannot access property '${String(prop)}' on ${instanceName}. The '${name}' has been cleaned up and is no longer available.","messagePattern":"Cannot access property '(.+?)' on (.+?)\\. The '(.+?)' has been cleaned up and is no longer available\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/cubejs-backend-shared/src/disposedProxy.ts","lineNumber":8,"sourceCode":"/**\n * Creates a proxy object that throws an error on any property access.\n * Used as a safeguard after disposal to catch dangling references.\n */\nexport function disposedProxy(name: string, instanceName: string): any {\n  return new Proxy({}, {\n    get(_target: object, prop: string | symbol): never {\n      throw new Error(\n        `Cannot access property '${String(prop)}' on ${instanceName}. ` +\n        `The '${name}' has been cleaned up and is no longer available.`\n      );\n    },\n    set(_target: object, prop: string | symbol): never {\n      throw new Error(\n        `Cannot set property '${String(prop)}' on ${instanceName}. ` +\n        `The '${name}' has been cleaned up and is no longer available.`\n      );\n    },\n    apply(): never {\n      throw new Error(\n        `Cannot call method on ${instanceName}. ` +\n        `The '${name}' has been cleaned up and is no longer available.`\n      );\n    },\n    has(_target: object, _prop: string | symbol): never {\n      throw new Error(","sourceCodeStart":1,"sourceCodeEnd":26,"githubUrl":"https://github.com/cube-js/cube/blob/7d981676b36392fec34088b9afab6bdcad40207c/packages/cubejs-backend-shared/src/disposedProxy.ts#L1-L26","documentation":"Lifecycle safeguard in disposedProxy's get trap: code is accessing a property on a proxy that stands in for a service instance (named `name`) after that instance has been disposed/cleaned up. It is a deliberate dangling-reference detector, not a data error — it reveals a use-after-dispose bug in shutdown or restart code paths.","triggerScenarios":"Thrown at packages/cubejs-backend-shared/src/disposedProxy.ts:8 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Find the code holding a stale reference to the disposed instance and stop using it after disposal.","Ensure async operations complete (or are cancelled) before the instance is disposed.","Recreate or re-resolve the instance through the proper lifecycle manager instead of caching the old reference."],"exampleFix":null,"handlingStrategy":"type-guard","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"7d981676b36392fec34088b9afab6bdcad40207c","analyzedAt":"2026-09-02T03:45:10.400Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T15:18:49.778Z"}