A bug that arises with the new version of Kaleido that I wanted to bring to your attention.
The error occurs because MetaCerberus installs Kaleido v1+ to export SVG charts, but this newer version of Kaleido no longer includes a built-in Chromium browser. The default conda environment built from your documentation lacks the required Google Chrome/Chromium installation.
HYDRA 12:27:35 [compute-0-1.local]: Starting HydraMPP (Massive Parallel Processing) v0.0.5
HYDRA 12:27:35 [compute-0-1.local]: Connecting to: local
HYDRA 12:27:38 [compute-0-1.local]: Status server listening on port: 24515
Traceback (most recent call last):
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/plotly/io/_kaleido.py", line 400, in to_image
img_bytes = kaleido.calc_fig_sync(
^^^^^^^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/kaleido/__init__.py", line 170, in calc_fig_sync
return _sync_server.oneshot_async_run(calc_fig, args=args, kwargs=kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/kaleido/_sync_server.py", line 161, in oneshot_async_run
raise res
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/kaleido/_sync_server.py", line 152, in run
q.put(asyncio.run(func(*args, **kwargs)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/asyncio/runners.py", line 195, in run
return runner.run(main)
^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/asyncio/runners.py", line 118, in run
return self._loop.run_until_complete(task)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/asyncio/base_events.py", line 691, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/kaleido/__init__.py", line 103, in calc_fig
async with Kaleido(**kopts) as k:
^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/kaleido/kaleido.py", line 190, in __init__
raise ChromeNotFoundError(
choreographer.browsers.chromium.ChromeNotFoundError: Kaleido v1 and later requires Chrome to be installed. To install Chrome, use the CLI command `kaleido_get_chrome`, or from Python, use either `await kaleido.get_chrome()` or `kaleido.get_chrome_sync()`.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/bin/metacerberus.py", line 1016, in <module>
sys.exit(main())
^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/bin/metacerberus.py", line 890, in main
metacerberus_report.write_Stats(report_path, readStats, protStats, NStats, config)
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/meta_cerberus/metacerberus_report.py", line 226, in write_Stats
figPlots[key].write_image(os.path.join(outpath, "combined", "img", key+'.svg'))
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/plotly/basedatatypes.py", line 3895, in write_image
return pio.write_image(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/plotly/io/_kaleido.py", line 530, in write_image
img_data = to_image(
^^^^^^^^^
File "/home/workdir/.snakemake/conda/c6352330df6c48f059d9b0f1f11282a4_/lib/python3.12/site-packages/plotly/io/_kaleido.py", line 412, in to_image
raise RuntimeError(PLOTLY_GET_CHROME_ERROR_MSG)
RuntimeError:
Kaleido requires Google Chrome to be installed.
Either download and install Chrome yourself following Google's instructions for your operating system,
or install it from your terminal by running:
$ plotly_get_chrome
HYDRA 12:39:21 [compute-0-1.local]: HydraMPP: Shutdown
Hi team,
A bug that arises with the new version of Kaleido that I wanted to bring to your attention.
The error occurs because MetaCerberus installs Kaleido v1+ to export SVG charts, but this newer version of Kaleido no longer includes a built-in Chromium browser. The default conda environment built from your documentation lacks the required Google Chrome/Chromium installation.
I recommend putting kaleido v0.2.1 as one of your dependencies for the conda recipe.
I explicitly put
python-kaleido=0.2.1in my conda installation line and it fixed the issue.Here is the full error: