def _update_updatable_files(
    egr_record: ExecutableGroupResultFilesystemRecord,
    shared_rt_info: cg.SharedRuntimeInfo,
    data_dir: str,
):
    """Safely update ExecutableGroupResultFilesystemRecord.json.gz and SharedRuntimeInfo.json.gz
    during an execution run.
    """
    _safe_to_json(
        shared_rt_info,
        part_path=f'{data_dir}/SharedRuntimeInfo.json.gz.part',
        nominal_path=f'{data_dir}/SharedRuntimeInfo.json.gz',
        bak_path=f'{data_dir}/SharedRuntimeInfo.json.gz.bak',
    )
    _safe_to_json(
        egr_record,
        part_path=f'{data_dir}/ExecutableGroupResultFilesystemRecord.json.gz.part',
        nominal_path=f'{data_dir}/ExecutableGroupResultFilesystemRecord.json.gz',
        bak_path=f'{data_dir}/ExecutableGroupResultFilesystemRecord.json.gz.bak',
    )
Safely update ExecutableGroupResultFilesystemRecord.json.gz and SharedRuntimeInfo.json.gz
    during an execution run.
    
cirq-google/cirq_google/workflow/io.py