{"record":{"id":"60d1739b0b498ae8","repo":"pathwaycom/pathway","slug":"path-storage-out-of-scope","errorCode":null,"errorMessage":"path storage out of scope","messagePattern":"path storage out of scope","errorType":"exception","errorClass":"OutOfScopeError","httpStatus":null,"severity":"error","filePath":"python/pathway/internals/graph_runner/state.py","lineNumber":154,"sourceCode":"\n    def get_computer_logic(self, id: int) -> Callable:\n        return self.computers[id]\n\n    def get_table(self, key: universe.Universe) -> api.Table:\n        if key not in self.tables:\n            raise OutOfScopeError(\"table out of scope\")\n        return self.tables[key]\n\n    def get_tables(self, keys: Iterable[universe.Universe]) -> list[api.Table]:\n        return [self.get_table(key) for key in keys]\n\n    def set_table(self, storage: Storage, table: api.Table) -> None:\n        self.tables[storage._universe] = table\n        self.storages[storage._universe] = storage\n\n    def get_storage(self, key: universe.Universe) -> Storage:\n        if key not in self.storages:\n            raise OutOfScopeError(\"path storage out of scope\")\n        return self.storages[key]\n\n    def get_storages(self, keys: Iterable[universe.Universe]) -> list[Storage]:\n        return [self.get_storage(key) for key in keys]\n\n    def set_error_log(self, table: table.Table, error_log: api.ErrorLog) -> None:\n        self.error_logs[table] = error_log\n\n    def get_error_log(self, table: table.Table) -> api.ErrorLog | None:\n        # None is returned if the error_log is not used.\n        # It was removed by tree shaking and there's no need to put entries in it.\n        return self.error_logs.get(table)\n","sourceCodeStart":136,"sourceCodeEnd":167,"githubUrl":"https://github.com/pathwaycom/pathway/blob/fa2f74a4649b7c5908690cf60137263d8d80de5f/python/pathway/internals/graph_runner/state.py#L136-L167","documentation":"GraphRunnerScope.get_storage raises OutOfScopeError('path storage out of scope') when the universe key is not in self.storages, i.e. no Storage (column path bookkeeping) was registered for that universe. Sister check to 'table out of scope'; both are set together by set_table, so seeing this one means set_table was never called or a different universe object identity was used.","triggerScenarios":"get_storage called with a universe for which set_table(storage, table) was never invoked; using an equal-but-distinct Universe object as key (identity/hash mismatch) instead of the one registered.","commonSituations":"Custom operator development; internal refactors between pathway versions where universe identity semantics changed; not encountered in normal pipeline code.","solutions":["If user code: report upstream; this is an internal invariant violation","If custom operator: ensure set_table is called with the exact universe object obtained from the storage (storage._universe), not a reconstructed one","Re-check the order in which your handler extracts universes/tables/storages"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"from pathway.internals.graph_runner.state import OutOfScopeError\n\ntry:\n    ...  # custom operator handler body\nexcept OutOfScopeError:\n    # re-register the storage/table for the universe, or fail loudly\n    raise","preventionTips":["In custom operators, always register via set_table(storage, table) using storage._universe as the key","Treat these errors as internal invariants; write regression tests around operator handlers"],"tags":["pathway","internals","graph-runner","scope","internal-error"],"backgroundTag":null,"analyzedSha":"fa2f74a4649b7c5908690cf60137263d8d80de5f","analyzedAt":"2026-08-15T01:48:17.006Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}