5.0.7 Cryosparc live: Stuck in Restoration Failed

Hi

A user decided to hard kill the Restoration job of a compacted cryosparc live session. Now the complete session is stuck. It can’t be started, it can’t be marked as completed.

How can we get out of this?

Thanks

You can try this low-level database query (with actual IDs instead of PX, SY):

cryosparcm cli 'db.workspaces.update_one({"project_uid": "PX", "session_uid": "SX"}, {"$set": {"status": "restoration_failed"}})'

This command is intended for recovery from this particular situation, not meant for routine management of CryoSPARC.

Thanks. Unfortuantly it seams not to work:

cryosparcm cli ‘db.workspaces.update_one({“project_uid”: “P285”, “session_uid”: “S13”}, {“$set”: {“status”: “restoration_failed”}})’

Traceback (most recent call last):
File “”, line 198, in _run_module_as_main
File “”, line 88, in _run_code
File “/opt/cryosparc/cryosparc_master/cli/setup_client.py”, line 29, in
print(result if isinstance(result, str) else json.dumps(result, default=api_default))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/cryosparc/cryosparc_master/.pixi/envs/master/lib/python3.12/json/init.py”, line 238, in dumps
**kw).encode(obj)
^^^^^^^^^^^
File “/opt/cryosparc/cryosparc_master/.pixi/envs/master/lib/python3.12/json/encoder.py”, line 200, in encode
chunks = self.iterencode(o, _one_shot=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/cryosparc/cryosparc_master/.pixi/envs/master/lib/python3.12/json/encoder.py”, line 258, in iterencode
return _iterencode(o, 0)
^^^^^^^^^^^^^^^^^
ValueError: Circular reference detected

@biocit Please can you try these commands instead:

cryosparcm mongo # open a mongo shell
db.workspaces.updateOne({project_uid: "P285", session_uid: "S13"}, {$set: {status: "restoration_failed"}})
exit # back to Linux

Didn’t change something with the job. Here is the output:

MongoDB shell version v4.0.28
connecting to: mongodb://cryosparcmaster.bioc.unizh.ch:39001/meteor?authSource=admin&gssapiServiceName=mongodb
Implicit session: session { “id” : UUID(“99b6f660-e465-478d-b902-427b8c3fa61a”) }
MongoDB server version: 4.0.28
meteor:PRIMARY> db.workspaces.updateOne({project_uid: “P285”, session_uid: “S13”}, {$set: {status: “restoration_failed”}})
{ “acknowledged” : true, “matchedCount” : 1, “modifiedCount” : 0 }
meteor:PRIMARY> exit
bye

As far as i understand the command it sets the job to the restoration_failed status. But the job is already in that status and Cryosparc is then stuck to do something with the job at all

Thanks @biocit for reporting back. Please can you post a screenshot of the workspace associated with session S13?
The workspace should (hopefully) be accessible via the drop-down menu inside the session


or via the browse/P285-W* path at the end of yor CryoSPARC web app url.

Maybe due to this? But there is no job running

that’s the workspace:


If you navigate to the
<your-prefix>/browse/P285-S* URL and select session S13, can you restore the session from the Actions menu near the lower right corner of the UI?

When i do that nothing happen after confirming that i want to restore it.

Please can

  1. Try again pushing Restore Session in the Actions menu.
  2. Confirm.
  3. Immediately afterward, on the CryoSPARC master server, run the command
    cryosparcm snaplogs and email us the resulting tgz file.

I will send you a personal message with the email address.

As I checked today I saw that the job launched. Just with a huge delay.

Now it hangs forever here:

Nothing really happens. The jobs itself complains that no new exposure where found.

@biocit Are there any indications that the nearly 17 k exposures have not already been processed and 6.5 M particles have not been extracted? How many exposures are expected in total?

I quite sure that they are processed as we are in the restoration process. That’s is also in the middle of something.

Please can you post a screenshot of the UI’s view at the URL (replace W99 with the actual UID of the workspace associated with session S13):

browse/P285-W99-J*?job_type[]=rtp_worker&sort_order=desc&view=table

It looks like this:

Thanks @biocit. Please can you post the outputs of these commands that may help us understand why processing seems to be stuck:

project_uid="P285"
session_uid="S13"
cryosparcm cli "api.sessions.find_one('$project_uid', '$session_uid').model_dump(include=['exposure_groups', 'status', 'phase_one_workers'])"
for job_uid in J2056 J2057;do
    cryosparcm job log $project_uid $job_uid | tail -n 20
    cryosparcm job events $project_uid $job_uid | tail -n 20
    cryosparcm cli "api.jobs.find_one('$project_uid', '$job_uid').model_dump(include={'uid': True, 'job_type': True, 'cluster_job_id': True, 'heartbeat_at': True, 'queued_at': True, 'resources_allocated': {'lane_type': True, 'target': {'config': {'script_tpl'}}}})"
done
2026-11-19 07:08:37,236 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:08:47,240 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:08:57,244 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:07,248 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:17,253 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:27,257 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:37,261 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:47,265 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:57,270 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:07,274 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:17,278 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:27,282 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:37,287 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:47,291 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:57,294 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:07,298 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:17,302 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:27,307 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:37,311 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:47,315 core                 heartbeat        INFO   | ========= Updating heartbeat
[2026-11-12 12:52:50] [1808 MB] License is valid.
[2026-11-12 12:52:50] [1808 MB] Launching job on lane RTXA5000 target gpu03. ...
[2026-11-12 12:52:50] [1808 MB] Running job on remote worker node hostname gpu03.
[2026-11-12 12:52:53] [149 MB] Job P285-J2056 started
[2026-11-12 12:52:53] [149 MB] Master running v5.0.7, worker running v5.0.7
[2026-11-12 12:52:53] [151 MB] Working in directory: /mnt/data01/cryosparc/data/J2056
[2026-11-12 12:52:53] [151 MB] Running on lane RTXA5000
[2026-11-12 12:52:53] [151 MB] Resources    Allocated
                               -----------  -----------------------
                               Worker       gpu03.
                               CPU          [0, 1, 2, 3, 4, 5]
                               GPU          [0]
                               RAM          [0, 1]
                               SSD          False
[2026-11-12 12:52:53] [151 MB] ──────────────────────────────────────────────────────────────
[2026-11-12 12:52:53] [151 MB] Importing job module for job type rtp_worker...
[2026-11-12 12:53:00] [453 MB] Job ready to run
[2026-11-12 12:53:00] [453 MB] ──────────────────────────────────────────────────────────────
[2026-11-12 12:53:00] [457 MB] No new exposure received since 580728 seconds ago. Searching again in 10 seconds...
/opt/cryosparc/cryosparc_master/.pixi/envs/master/lib/python3.12/site-packages/pydantic/main.py:463: UserWarning: Pydantic serializer warnings:
  PydanticSerializationUnexpectedValue(Expected 6 fields but got 0: Expected `Node` - serialized value may not be as expected [input_value=Node(type='node', ssh_str...000', mem=25282805760)]), input_type=Node])
  PydanticSerializationUnexpectedValue(Expected `Cluster` - serialized value may not be as expected [input_value=Node(type='node', ssh_str...000', mem=25282805760)]), input_type=Node])
  return self.__pydantic_serializer__.to_python(
{"uid": "J2056", "queued_at": "2026-11-12T12:52:44.919000+00:00", "heartbeat_at": "2026-11-19T06:11:47.317000+00:00", "resources_allocated": {"lane_type": "node", "target": {"config": {}}}, "cluster_job_id": null}
2026-11-19 07:08:37,013 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:08:47,017 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:08:57,021 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:07,024 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:17,028 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:27,032 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:37,036 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:47,040 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:09:57,044 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:07,049 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:17,053 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:27,058 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:37,061 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:47,065 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:10:57,069 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:07,073 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:17,077 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:27,082 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:37,086 core                 heartbeat        INFO   | ========= Updating heartbeat
2026-11-19 07:11:47,090 core                 heartbeat        INFO   | ========= Updating heartbeat
[2026-11-12 12:52:52] [1808 MB] License is valid.
[2026-11-12 12:52:52] [1808 MB] Launching job on lane RTXA5000 target gpu03. ...
[2026-11-12 12:52:52] [1808 MB] Running job on remote worker node hostname gpu03.
[2026-11-12 12:52:55] [149 MB] Job P285-J2057 started
[2026-11-12 12:52:55] [149 MB] Master running v5.0.7, worker running v5.0.7
[2026-11-12 12:52:55] [151 MB] Working in directory: /mnt/data01/cryosparc/data/J2057
[2026-11-12 12:52:55] [151 MB] Running on lane RTXA5000
[2026-11-12 12:52:55] [151 MB] Resources    Allocated
                               -----------  -----------------------
                               Worker       gpu03.
                               CPU          [0, 1, 2, 3, 4, 5]
                               GPU          [1]
                               RAM          [2, 3]
                               SSD          False
[2026-11-12 12:52:55] [151 MB] ──────────────────────────────────────────────────────────────
[2026-11-12 12:52:55] [151 MB] Importing job module for job type rtp_worker...
[2026-11-12 12:53:02] [453 MB] Job ready to run
[2026-11-12 12:53:02] [453 MB] ──────────────────────────────────────────────────────────────
[2026-11-12 12:53:02] [456 MB] No new exposure received since 580725 seconds ago. Searching again in 10 seconds...
/opt/cryosparc/cryosparc_master/.pixi/envs/master/lib/python3.12/site-packages/pydantic/main.py:463: UserWarning: Pydantic serializer warnings:
  PydanticSerializationUnexpectedValue(Expected 6 fields but got 0: Expected `Node` - serialized value may not be as expected [input_value=Node(type='node', ssh_str...000', mem=25282805760)]), input_type=Node])
  PydanticSerializationUnexpectedValue(Expected `Cluster` - serialized value may not be as expected [input_value=Node(type='node', ssh_str...000', mem=25282805760)]), input_type=Node])
  return self.__pydantic_serializer__.to_python(
{"uid": "J2057", "queued_at": "2026-11-12T12:52:45.220000+00:00", "heartbeat_at": "2026-11-19T06:11:47.092000+00:00", "resources_allocated": {"lane_type": "node", "target": {"config": {}}}, "cluster_job_id": null}

Thanks @biocit Please can you also post the output of the commands

Here the output:

{"status": "restoration_failed", "phase_one_workers": {}, "exposure_groups": [{"ignore_exposures": false, "gainref_path": "/mnt/emrawdata/2026/Gainref_2026/20260914_bin2x_gain.mrc", "defect_path": null, "file_engine_recursive": false, "file_engine_watch_path_abs": "/mnt/emrawdata/2026/20260915", "file_engine_enable": true, "file_engine_filter": "*tiff", "file_engine_interval": 10, "file_engine_min_file_size": 0, "file_engine_min_modified_time_delta": 0, "exp_group_id": 1, "display_num": 1, "num_exposures_found": 7001, "file_engine_strategy": "entity", "final": true, "is_any_eer": false}, {"ignore_exposures": false, "gainref_path": "/mnt/emrawdata/2026/Gainref_2026/20260914_bin2x_gain.mrc", "defect_path": null, "file_engine_recursive": false, "file_engine_watch_path_abs": "/mnt/emrawdata/2026/20260916", "file_engine_enable": true, "file_engine_filter": "*.tiff", "file_engine_interval": 10, "file_engine_min_file_size": 0, "file_engine_min_modified_time_delta": 0, "exp_group_id": 2, "display_num": 2, "num_exposures_found": 10001, "file_engine_strategy": "entity", "final": true, "is_any_eer": false}]}

Thanks @biocit.
Does the workspace associated with session P285.S13 still contain Live Processing Worker jobs in the Running state, similar to jobs J2056 and J2057 in the screenshot above?
Please can you

  1. Kill the Live Processing Worker jobs that are still running (if any).
  2. Again initiate restoration of the session, using only a single worker.
  3. If restoration fails again, please
    • post a new table-mode screenshot of the session workspace at (replacing W99 with the actual workspace ID):
      browse/P285-W99-J*?job_type[]=rtp_worker&sort_order=desc&view=table
      
    • send us an email with
      • the file created with the command
        cryosparcm snaplogs

      • session and exposure documents

        project_uid="P285"
        session_uid="S13"
        cd $(mktemp -d)
        ( # begin command block
        cryosparcm cli "api.sessions.find_one('$project_uid', '$session_uid')"
        cryosparcm cli "db.exposures.find({'project_uid': '$project_uid', 'session_uid': '$session_uid'})"
        ) | tee ${project_uid}_${session_uid}_info.txt
        realpath *.txt # please send us this file