MCPcopy Index your code
hub / github.com/github/spec-kit / record_step_result

Method record_step_result

src/specify_cli/workflows/engine.py:437–445  ·  view source on GitHub ↗

Record one step's result under the run lock. Routing the mutation through the lock keeps it from racing a concurrent ``save()`` that is iterating ``step_results`` (e.g. during a concurrent fan-out). For a sequential run this is an uncontended lock.

(self, step_id: str, data: dict[str, Any])

Source from the content-addressed store, hash-verified

435 return self.project_root / ".specify" / "workflows" / "runs" / self.run_id
436
437 def record_step_result(self, step_id: str, data: dict[str, Any]) -> None:
438 """Record one step's result under the run lock.
439
440 Routing the mutation through the lock keeps it from racing a concurrent
441 ``save()`` that is iterating ``step_results`` (e.g. during a concurrent
442 fan-out). For a sequential run this is an uncontended lock.
443 """
444 with self._lock:
445 self.step_results[step_id] = data
446
447 def set_step_output(self, step_id: str, output: Any) -> None:
448 """Replace an already-recorded step's ``output`` under the run lock.

Callers 1

_record_resultMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected