mirror of
https://github.com/agentscope-ai/ReMe.git
synced 2026-11-07 07:57:13 +00:00
* refactor: share backend search, file responses, and vector digests * refactor(studio): remove unused scaffolding and share workspace updates * test: simplify async tests and share deterministic store fixtures
13 lines
451 B
Python
13 lines
451 B
Python
"""Common response handling for file operations."""
|
|
|
|
from ..base_step import BaseStep
|
|
|
|
|
|
class _FileIOStep(BaseStep):
|
|
"""Preserve the file-operation failure envelope without changing its payload."""
|
|
|
|
def _fail(self, message: str, **meta) -> None:
|
|
assert self.context is not None
|
|
self.context.response.success = False
|
|
self.context.response.answer = f"Error: {message}"
|
|
self.context.response.metadata.update(meta)
|