commit-graph: return with errors during write