Skip to content

JSON encoder bug on espaloma_charge co-installs #1962

@Lumber1432

Description

@Lumber1432

Description
Hello OpenFE team, recently I have been trying to run absolute hydration free energy simulations for a dataset of molecules, and have managed to do so for different force fields (GAFF, openff) and partial charge methods (am1bcc, NAGL). I wanted to perform calculations with espaloma (both force field and partial charge method) as well, however when I tried to install espaloma_charge as requested on my 1.10.0 openfe env, the Python versioning could not resolve stating that espaloma_charge may only run on 3.12, whereas the default 1.10.0 openfe install is on 3.13.

I then created a new environment where I simultaneously installed openfe and espaloma_charge (I let mamba handle the versioning) and now when I try to run simulations for molecules on the espaloma force field and partial charge method, openfe quickrun errors out due to a JSON encoding error as shown below.

To Reproduce
I create an environment with both openfe and espaloma_charge, then build all transformation JSONs starting from an SDF library. I'll leave an example molecule below that I have been testing on:

mobley_9979854
  -OEChem-01201715273D

 12 11  0     1  0  0  0  0  0999 V2000
    0.3310    1.3650   -0.0660 C   0  0  0  0  0  0  0  0  0  0  0  0
   -0.0250   -0.0560   -0.4690 C   0  0  2  0  0  0  0  0  0  0  0  0
   -0.7470   -0.0300   -1.2930 H   0  0  0  0  0  0  0  0  0  0  0  0
   -0.5920   -0.8500    0.6890 C   0  0  0  0  0  0  0  0  0  0  0  0
   -1.7160   -0.2690    1.1640 F   0  0  0  0  0  0  0  0  0  0  0  0
   -0.9020   -2.1120    0.3240 F   0  0  0  0  0  0  0  0  0  0  0  0
    0.2910   -0.9180    1.7090 F   0  0  0  0  0  0  0  0  0  0  0  0
    1.1560   -0.6950   -0.9410 O   0  0  0  0  0  0  0  0  0  0  0  0
    1.0530    1.3720    0.7590 H   0  0  0  0  0  0  0  0  0  0  0  0
   -0.5570    1.9280    0.2400 H   0  0  0  0  0  0  0  0  0  0  0  0
    0.8050    1.8910   -0.9010 H   0  0  0  0  0  0  0  0  0  0  0  0
    0.9030   -1.5970   -1.1920 H   0  0  0  0  0  0  0  0  0  0  0  0
  1  2  1  0  0  0  0
  2  3  1  0  0  0  0
  2  4  1  0  0  0  0
  4  5  1  0  0  0  0
  4  6  1  0  0  0  0
  4  7  1  0  0  0  0
  2  8  1  0  0  0  0
  1  9  1  0  0  0  0
  1 10  1  0  0  0  0
  1 11  1  0  0  0  0
  8 12  1  0  0  0  0
M  END
> <partial_charges>
-0.100500002503
0.124099999666
0.0688999965787
0.582400023937
-0.23749999702
-0.23749999702
-0.23749999702
-0.574100017548
0.0649000033736
0.0649000033736
0.0649000033736
0.416999995708


> <partial_bond_orders>
1.0
1.0
1.0
1.0
1.0
1.0
1.0
1.0
1.0
1.0
1.0


> <atom_types>
c3
c3
h1
c3
f
f
f
oh
hc
hc
hc
ho


$$$$

This is the script I run to generate the transformation JSON:

import pathlib

from rdkit import Chem
from openfe import (
    SmallMoleculeComponent,
    SolventComponent,
    ChemicalSystem,
    Transformation,
)
from openfe.protocols.openmm_afe import AbsoluteSolvationProtocol
from openff.units import unit

# read sdf files in for ligands
ligands_sdf = Chem.SDMolSupplier("freesolv.sdf", removeHs=False)
ligand_mols = [SmallMoleculeComponent(sdf) for sdf in ligands_sdf]

# solvation
solvent = SolventComponent(positive_ion="K", negative_ion="Cl", neutralize=True)

# protocol - set partial charge model and small molecule forcefield
ahfe_settings = AbsoluteSolvationProtocol.default_settings()

ahfe_settings.partial_charge_settings.partial_charge_method = "espaloma"
ahfe_settings.vacuum_forcefield_settings.small_molecule_forcefield = "espaloma-0.4.0"
ahfe_settings.solvent_forcefield_settings.small_molecule_forcefield = "espaloma-0.4.0"

# gpu device index for parallel computing
ahfe_settings.solvent_engine_settings.gpu_device_index = [0]
ahfe_settings.vacuum_engine_settings.gpu_device_index = [0]

ahfe_protocol = AbsoluteSolvationProtocol(settings=ahfe_settings)

transformation_dir = pathlib.Path("transformations")
transformation_dir.mkdir(exist_ok=True)

for ligand in ligand_mols:
    # chemical systems
    system_a = ChemicalSystem(
        {"ligand": ligand, "solvent": solvent}, name=ligand.name
    )

    system_b = ChemicalSystem({"solvent": solvent})

    transformation = Transformation(
        stateA=system_a,
        stateB=system_b,
        mapping=None,
        protocol=ahfe_protocol,
        name=f"{system_a.name}",
    )

    # use openfe CLI to run simulations and gather results
    transformation.dump(transformation_dir / f"{transformation.name}.json")

When trying to run the simulation, it crashes.

Software versions

  • Which operating system and version did you use? The HPC node I'm trying to run the calculations on is on Rocky Linux 9
  • Which method did you use to install this package? Env created with mamba
  • Copy/paste the output of conda list (or the equivalent for your package manager):
    mamba list output
  Name                           Version       Build                              Channel    
───────────────────────────────────────────────────────────────────────────────────────────────
  _openmp_mutex                  4.5           7_kmp_llvm                         conda-forge
  _python_abi3_support           1.0           hd8ed1ab_2                         conda-forge
  absl-py                        2.4.0         pyhd8ed1ab_0                       conda-forge
  adjusttext                     1.3.0         pyhd8ed1ab_0                       conda-forge
  adwaita-icon-theme             49.0          unix_0                             conda-forge
  ambertools                     24.8          cuda_None_nompi_py312hbe1986e_101  conda-forge
  annotated-types                0.7.0         pyhd8ed1ab_1                       conda-forge
  anyio                          4.13.0        pyhcf101f3_0                       conda-forge
  argon2-cffi                    25.1.0        pyhd8ed1ab_0                       conda-forge
  argon2-cffi-bindings           25.1.0        py312h4c3975b_2                    conda-forge
  arpack                         3.9.1         nompi_hf03ea27_102                 conda-forge
  arrow                          1.4.0         pyhcf101f3_0                       conda-forge
  asttokens                      3.0.1         pyhd8ed1ab_0                       conda-forge
  astunparse                     1.6.3         pyhd8ed1ab_3                       conda-forge
  async-lru                      2.3.0         pyhcf101f3_0                       conda-forge
  at-spi2-atk                    2.38.0        h0630a04_3                         conda-forge
  at-spi2-core                   2.40.3        h0630a04_0                         conda-forge
  atk-1.0                        2.38.0        h04ea711_2                         conda-forge
  attrs                          26.1.0        pyhcf101f3_0                       conda-forge
  aws-c-auth                     0.7.31        h57bd9a3_0                         conda-forge
  aws-c-cal                      0.7.4         hfd43aa1_1                         conda-forge
  aws-c-common                   0.9.28        hb9d3cd8_0                         conda-forge
  aws-c-compression              0.2.19        h756ea98_1                         conda-forge
  aws-c-event-stream             0.4.3         h29ce20c_2                         conda-forge
  aws-c-http                     0.8.10        h5e77a74_0                         conda-forge
  aws-c-io                       0.14.18       h2af50b2_12                        conda-forge
  aws-c-mqtt                     0.10.7        h02abb05_0                         conda-forge
  aws-c-s3                       0.6.6         h834ce55_0                         conda-forge
  aws-c-sdkutils                 0.1.19        h756ea98_3                         conda-forge
  aws-checksums                  0.1.20        h756ea98_0                         conda-forge
  aws-crt-cpp                    0.28.3        h3e6eb3e_6                         conda-forge
  aws-sdk-cpp                    1.11.379      h9f1560d_11                        conda-forge
  babel                          2.18.0        pyhcf101f3_1                       conda-forge
  backports.zstd                 1.3.0         py312h90b7ffd_0                    conda-forge
  beautifulsoup4                 4.14.3        pyha770c72_0                       conda-forge
  biopython                      1.87          py312h4c3975b_0                    conda-forge
  bleach                         6.3.0         pyhcf101f3_1                       conda-forge
  bleach-with-css                6.3.0         hbca2aae_1                         conda-forge
  blosc                          1.21.6        he440d0b_1                         conda-forge
  brotli                         1.2.0         hed03a55_1                         conda-forge
  brotli-bin                     1.2.0         hb03c661_1                         conda-forge
  brotli-python                  1.2.0         py312hdb49522_1                    conda-forge
  bson                           0.5.10        pyhd8ed1ab_0                       conda-forge
  bzip2                          1.0.8         hda65f42_9                         conda-forge
  c-ares                         1.34.6        hb03c661_0                         conda-forge
  c-blosc2                       2.23.1        hc31b594_0                         conda-forge
  ca-certificates                2026.4.22     hbd8a1cb_0                         conda-forge
  cached-property                1.5.2         hd8ed1ab_1                         conda-forge
  cached_property                1.5.2         pyha770c72_1                       conda-forge
  cachetools                     7.0.6         pyhd8ed1ab_0                       conda-forge
  cairo                          1.18.4        h3394656_0                         conda-forge
  certifi                        2026.4.22     pyhd8ed1ab_0                       conda-forge
  cffi                           2.0.0         py312h460c074_1                    conda-forge
  cftime                         1.6.5         py312h4f23490_1                    conda-forge
  charset-normalizer             3.4.7         pyhd8ed1ab_0                       conda-forge
  cinnabar                       0.5.0         pyhd8ed1ab_2                       conda-forge
  click                          8.3.2         pyhc90fa1f_0                       conda-forge
  click-option-group             0.5.6         pyhd8ed1ab_0                       conda-forge
  colorama                       0.4.6         pyhd8ed1ab_1                       conda-forge
  comm                           0.2.3         pyhe01879c_0                       conda-forge
  contourpy                      1.3.3         py312h0a2e395_4                    conda-forge
  cpython                        3.12.13       py312hd8ed1ab_0                    conda-forge
  cuda-nvrtc                     13.2.78       hecca717_0                         conda-forge
  cuda-version                   13.2          he2cc418_3                         conda-forge
  cycler                         0.12.1        pyhcf101f3_2                       conda-forge
  cyrus-sasl                     2.1.28        hd9c7081_0                         conda-forge
  dbus                           1.16.2        h24cb091_1                         conda-forge
  debugpy                        1.8.20        py312h8285ef7_0                    conda-forge
  decorator                      5.2.1         pyhd8ed1ab_0                       conda-forge
  defusedxml                     0.7.1         pyhd8ed1ab_0                       conda-forge
  dgl                            2.3.0         py312h0c974e3_0                    conda-forge
  dill                           0.4.1         pyhcf101f3_0                       conda-forge
  epoxy                          1.5.10        hb03c661_2                         conda-forge
  espaloma_charge                0.0.8         pyhd8ed1ab_3                       conda-forge
  exceptiongroup                 1.3.1         pyhd8ed1ab_0                       conda-forge
  executing                      2.2.1         pyhd8ed1ab_0                       conda-forge
  fftw                           3.3.11        nompi_h3b011a4_100                 conda-forge
  filelock                       3.29.0        pyhd8ed1ab_0                       conda-forge
  flatbuffers                    24.3.25       h59595ed_0                         conda-forge
  flexcache                      0.3           pyhd8ed1ab_1                       conda-forge
  flexparser                     0.4           pyhd8ed1ab_1                       conda-forge
  font-ttf-dejavu-sans-mono      2.37          hab24e00_0                         conda-forge
  font-ttf-inconsolata           3.000         h77eed37_0                         conda-forge
  font-ttf-source-code-pro       2.038         h77eed37_0                         conda-forge
  font-ttf-ubuntu                0.83          h77eed37_3                         conda-forge
  fontconfig                     2.17.1        h27c8c51_0                         conda-forge
  fonts-conda-ecosystem          1             0                                  conda-forge
  fonts-conda-forge              1             hc364b38_1                         conda-forge
  fonttools                      4.62.1        py312h8a5da7c_0                    conda-forge
  fqdn                           1.5.1         pyhd8ed1ab_1                       conda-forge
  freetype                       2.14.3        ha770c72_0                         conda-forge
  freetype-py                    2.3.0         pyhd8ed1ab_0                       conda-forge
  fribidi                        1.0.16        hb03c661_0                         conda-forge
  fsspec                         2026.3.0      pyhd8ed1ab_0                       conda-forge
  gast                           0.7.0         pyhd8ed1ab_0                       conda-forge
  gdk-pixbuf                     2.44.6        h2b0a6b4_0                         conda-forge
  giflib                         5.2.2         hd590300_0                         conda-forge
  glib-tools                     2.86.4        hf516916_1                         conda-forge
  gmp                            6.3.0         hac33072_2                         conda-forge
  gmpy2                          2.3.0         py312hcaba1f9_1                    conda-forge
  google-pasta                   0.2.0         pyhd8ed1ab_2                       conda-forge
  graphite2                      1.3.14        hecca717_2                         conda-forge
  graphviz                       13.1.2        h87b6fe6_0                         conda-forge
  greenlet                       3.4.0         py312h8285ef7_0                    conda-forge
  griddataformats                1.1.0         pyhd8ed1ab_1                       conda-forge
  grpcio                         1.62.2        py312hb06c811_0                    conda-forge
  gsd                            5.0.1         h7c397b8_0                         conda-forge
  gtk3                           3.24.43       h021d004_4                         conda-forge
  gts                            0.7.6         h977cf35_4                         conda-forge
  gufe                           1.9.0         pyhc364b38_0                       conda-forge
  h11                            0.16.0        pyhcf101f3_1                       conda-forge
  h2                             4.3.0         pyhcf101f3_0                       conda-forge
  h5py                           3.16.0        nompi_py312ha4f8f14_102            conda-forge
  harfbuzz                       12.2.0        h15599e2_0                         conda-forge
  hdf4                           4.2.15        h2a13503_7                         conda-forge
  hdf5                           1.14.6        nompi_h19486de_106                 conda-forge
  hicolor-icon-theme             0.17          ha770c72_3                         conda-forge
  hpack                          4.1.0         pyhd8ed1ab_0                       conda-forge
  httpcore                       1.0.9         pyh29332c3_0                       conda-forge
  httpx                          0.28.1        pyhd8ed1ab_0                       conda-forge
  hyperframe                     6.1.0         pyhd8ed1ab_0                       conda-forge
  icu                            75.1          he02047a_0                         conda-forge
  idna                           3.13          pyhcf101f3_0                       conda-forge
  importlib-metadata             8.8.0         pyhcf101f3_0                       conda-forge
  importlib_resources            7.1.0         pyhd8ed1ab_0                       conda-forge
  iniconfig                      2.3.0         pyhd8ed1ab_0                       conda-forge
  ipycytoscape                   1.3.3         pyhd8ed1ab_1                       conda-forge
  ipykernel                      7.2.0         pyha191276_1                       conda-forge
  ipython                        9.12.0        pyhecfbec7_0                       conda-forge
  ipython_pygments_lexers        1.1.1         pyhd8ed1ab_0                       conda-forge
  ipywidgets                     8.1.8         pyhd8ed1ab_0                       conda-forge
  isoduration                    20.11.0       pyhd8ed1ab_1                       conda-forge
  jax                            0.4.31        pyhd8ed1ab_2                       conda-forge
  jaxlib                         0.4.31        cpu_py312h6b2a80f_1                conda-forge
  jedi                           0.19.2        pyhd8ed1ab_1                       conda-forge
  jinja2                         3.1.6         pyhcf101f3_1                       conda-forge
  joblib                         1.5.3         pyhd8ed1ab_0                       conda-forge
  jq                             1.8.1         h73b1eb8_0                         conda-forge
  json5                          0.14.0        pyhd8ed1ab_0                       conda-forge
  jsonpointer                    3.1.1         pyhcf101f3_0                       conda-forge
  jsonschema                     4.26.0        pyhcf101f3_0                       conda-forge
  jsonschema-specifications      2025.9.1      pyhcf101f3_0                       conda-forge
  jsonschema-with-format-nongpl  4.26.0        hcf101f3_0                         conda-forge
  jupyter-lsp                    2.3.1         pyhcf101f3_0                       conda-forge
  jupyter_client                 8.8.0         pyhcf101f3_0                       conda-forge
  jupyter_core                   5.9.1         pyhc90fa1f_0                       conda-forge
  jupyter_events                 0.12.1        pyhcf101f3_0                       conda-forge
  jupyter_server                 2.17.0        pyhcf101f3_0                       conda-forge
  jupyter_server_terminals       0.5.4         pyhcf101f3_0                       conda-forge
  jupyterlab                     4.5.6         pyhd8ed1ab_0                       conda-forge
  jupyterlab_pygments            0.3.0         pyhd8ed1ab_2                       conda-forge
  jupyterlab_server              2.28.0        pyhcf101f3_0                       conda-forge
  jupyterlab_widgets             3.0.16        pyhcf101f3_1                       conda-forge
  kartograf                      1.2.0         pyhd8ed1ab_0                       conda-forge
  keras                          3.11.2        pyh753f3f9_0                       conda-forge
  keyutils                       1.6.3         hb9d3cd8_0                         conda-forge
  kiwisolver                     1.5.0         py312h0a2e395_0                    conda-forge
  konnektor                      0.3.0         pyhc364b38_0                       conda-forge
  krb5                           1.21.3        h659f571_0                         conda-forge
  lark                           1.3.1         pyhd8ed1ab_0                       conda-forge
  lcms2                          2.18          h0c24ade_0                         conda-forge
  ld_impl_linux-64               2.45.1        default_hbd61a6d_102               conda-forge
  legacy-cgi                     2.6.4         pyhcf101f3_0                       conda-forge
  lerc                           4.1.0         hdb68285_0                         conda-forge
  libabseil                      20240116.2    cxx17_he02047a_1                   conda-forge
  libaec                         1.1.5         h088129d_0                         conda-forge
  libblas                        3.9.0         20_linux64_mkl                     conda-forge
  libboost                       1.86.0        hed09d94_4                         conda-forge
  libboost-python                1.86.0        py312hf890105_5                    conda-forge
  libbrotlicommon                1.2.0         hb03c661_1                         conda-forge
  libbrotlidec                   1.2.0         hb03c661_1                         conda-forge
  libbrotlienc                   1.2.0         hb03c661_1                         conda-forge
  libcblas                       3.9.0         20_linux64_mkl                     conda-forge
  libcufft                       12.2.0.46     hecca717_0                         conda-forge
  libcups                        2.3.3         hb8b1518_5                         conda-forge
  libcurl                        8.18.0        h4e3cde8_0                         conda-forge
  libdeflate                     1.25          h17f619e_0                         conda-forge
  libdrm                         2.4.125       hb03c661_1                         conda-forge
  libedit                        3.1.20250104  pl5321h7949ede_0                   conda-forge
  libegl                         1.7.0         ha4b6fd6_2                         conda-forge
  libegl-devel                   1.7.0         ha4b6fd6_2                         conda-forge
  libev                          4.33          hd590300_2                         conda-forge
  libexpat                       2.7.5         hecca717_0                         conda-forge
  libffi                         3.5.2         h3435931_0                         conda-forge
  libfreetype                    2.14.3        ha770c72_0                         conda-forge
  libfreetype6                   2.14.3        h73754d4_0                         conda-forge
  libgcc                         15.2.0        he0feb66_18                        conda-forge
  libgcc-ng                      15.2.0        h69a702a_18                        conda-forge
  libgd                          2.3.3         h6f5c62b_11                        conda-forge
  libgfortran                    15.2.0        h69a702a_18                        conda-forge
  libgfortran5                   15.2.0        h68bc16d_18                        conda-forge
  libgl                          1.7.0         ha4b6fd6_2                         conda-forge
  libgl-devel                    1.7.0         ha4b6fd6_2                         conda-forge
  libglib                        2.86.4        h6548e54_1                         conda-forge
  libglvnd                       1.7.0         ha4b6fd6_2                         conda-forge
  libglx                         1.7.0         ha4b6fd6_2                         conda-forge
  libglx-devel                   1.7.0         ha4b6fd6_2                         conda-forge
  libgomp                        15.2.0        he0feb66_18                        conda-forge
  libgrpc                        1.62.2        h15f2491_0                         conda-forge
  libhwloc                       2.12.1        default_h3d81e11_1000              conda-forge
  libiconv                       1.18          h3b78370_2                         conda-forge
  libjpeg-turbo                  3.1.4.1       hb03c661_0                         conda-forge
  liblapack                      3.9.0         20_linux64_mkl                     conda-forge
  liblapacke                     3.9.0         20_linux64_mkl                     conda-forge
  liblzma                        5.8.3         hb03c661_0                         conda-forge
  libnetcdf                      4.9.2         nompi_h21f7587_118                 conda-forge
  libnghttp2                     1.68.1        h877daf1_0                         conda-forge
  libnsl                         2.0.1         hb9d3cd8_1                         conda-forge
  libntlm                        1.8           hb9d3cd8_0                         conda-forge
  libpciaccess                   0.18          hb9d3cd8_0                         conda-forge
  libpng                         1.6.58        h421ea60_0                         conda-forge
  libpq                          18.1          h5c52fec_2                         conda-forge
  libprotobuf                    4.25.3        hd5b35b9_1                         conda-forge
  librdkit                       2025.09.5     h3c5c181_0                         conda-forge
  libre2-11                      2023.09.01    h5a48ba9_2                         conda-forge
  librsvg                        2.58.4        h49af25d_2                         conda-forge
  libsodium                      1.0.20        h4ab18f5_0                         conda-forge
  libsqlite                      3.53.0        h0c1763c_0                         conda-forge
  libssh2                        1.11.1        hcf80075_0                         conda-forge
  libstdcxx                      15.2.0        h934c35e_18                        conda-forge
  libstdcxx-ng                   15.2.0        hdf11a46_18                        conda-forge
  libtiff                        4.7.1         h9d88235_1                         conda-forge
  libtorch                       2.3.1         cpu_mkl_h0bb0d08_100               conda-forge
  liburing                       2.7           h434a139_0                         conda-forge
  libuuid                        2.42          h5347b49_0                         conda-forge
  libuv                          1.51.0        hb03c661_1                         conda-forge
  libwebp-base                   1.6.0         hd42ef1d_0                         conda-forge
  libxcb                         1.17.0        h8a09558_0                         conda-forge
  libxcrypt                      4.4.36        hd590300_1                         conda-forge
  libxkbcommon                   1.11.0        he8b52b9_0                         conda-forge
  libxml2                        2.13.9        h04c0eec_0                         conda-forge
  libxslt                        1.1.43        h7a3aeb2_0                         conda-forge
  libzip                         1.11.2        h6991a6a_0                         conda-forge
  libzlib                        1.3.2         h25fd6f3_2                         conda-forge
  lightning-utilities            0.15.3        pyhd8ed1ab_0                       conda-forge
  llvm-openmp                    22.1.4        h4922eb0_0                         conda-forge
  llvmlite                       0.47.0        py312h7424e68_1                    conda-forge
  lomap2                         3.2.1         pyhd8ed1ab_3                       conda-forge
  lxml                           6.0.2         py312h70dad80_0                    conda-forge
  lz4-c                          1.10.0        h5888daf_1                         conda-forge
  markdown                       3.10.2        pyhcf101f3_0                       conda-forge
  markdown-it-py                 4.0.0         pyhd8ed1ab_0                       conda-forge
  markupsafe                     3.0.3         py312h8a5da7c_1                    conda-forge
  matplotlib-base                3.10.9        py312he3d6523_0                    conda-forge
  matplotlib-inline              0.2.1         pyhd8ed1ab_0                       conda-forge
  mda-xdrlib                     0.2.0         pyhd8ed1ab_1                       conda-forge
  mdanalysis                     2.10.0        py312hf79963d_1                    conda-forge
  mdtraj                         1.11.1        np2py312h8baca0b_1                 conda-forge
  mdurl                          0.1.2         pyhd8ed1ab_1                       conda-forge
  metis                          5.1.1         h59595ed_2                         conda-forge
  mistune                        3.2.0         pyhcf101f3_0                       conda-forge
  mkl                            2023.2.0      ha770c72_50498                     conda-forge
  ml_dtypes                      0.4.0         py312hf9745cd_2                    conda-forge
  mmtf-python                    1.1.3         pyhd8ed1ab_0                       conda-forge
  mpc                            1.4.0         he0a73b1_0                         conda-forge
  mpfr                           4.2.2         he0a73b1_0                         conda-forge
  mpiplus                        v0.0.2        pyhd8ed1ab_0                       conda-forge
  mpmath                         1.4.1         pyhd8ed1ab_0                       conda-forge
  mrcfile                        1.5.4         pyhd8ed1ab_0                       conda-forge
  msgpack-python                 1.1.2         py312hd9148b4_1                    conda-forge
  munkres                        1.1.4         pyhd8ed1ab_1                       conda-forge
  namex                          0.1.0         pyhd8ed1ab_0                       conda-forge
  narwhals                       2.20.0        pyhcf101f3_0                       conda-forge
  nbclient                       0.10.4        pyhd8ed1ab_0                       conda-forge
  nbconvert-core                 7.17.1        pyhcf101f3_0                       conda-forge
  nbformat                       5.10.4        pyhd8ed1ab_1                       conda-forge
  ncurses                        6.5           h2d0b736_3                         conda-forge
  nest-asyncio                   1.6.0         pyhd8ed1ab_1                       conda-forge
  netcdf-fortran                 4.6.2         nompi_h5aa5643_101                 conda-forge
  netcdf4                        1.7.2         nompi_py312hdd76c12_103            conda-forge
  networkx                       3.6.1         pyhcf101f3_0                       conda-forge
  notebook                       7.5.5         pyhcf101f3_0                       conda-forge
  notebook-shim                  0.2.4         pyhd8ed1ab_1                       conda-forge
  numba                          0.65.1        py312hd1dde6f_0                    conda-forge
  numexpr                        2.10.1        mkl_py312h791fadb_2                conda-forge
  numpy                          1.26.4        py312heda63a1_0                    conda-forge
  ocl-icd                        2.3.3         hb9d3cd8_0                         conda-forge
  ocl-icd-system                 1.0.0         1                                  conda-forge
  oniguruma                      6.9.10        hb9d3cd8_0                         conda-forge
  opencl-headers                 2025.06.13    hecca717_0                         conda-forge
  openfe                         1.10.0        pyhe1070e7_1                       conda-forge
  openfe-analysis                0.4.0         pyhd8ed1ab_0                       conda-forge
  openfe-base                    1.10.0        pyhc364b38_1                       conda-forge
  openff-amber-ff-ports          2025.09.0     pyhd8ed1ab_0                       conda-forge
  openff-forcefields             2026.01.0     pyhd8ed1ab_0                       conda-forge
  openff-interchange             0.5.2         pyhd8ed1ab_1                       conda-forge
  openff-interchange-base        0.5.2         pyhd8ed1ab_1                       conda-forge
  openff-nagl                    0.5.5         pyhd8ed1ab_0                       conda-forge
  openff-nagl-base               0.5.5         pyhd8ed1ab_0                       conda-forge
  openff-nagl-models             2025.9.0      pyhd8ed1ab_0                       conda-forge
  openff-toolkit                 0.18.0        pyhd8ed1ab_3                       conda-forge
  openff-toolkit-base            0.18.0        pyhd8ed1ab_3                       conda-forge
  openff-units                   0.3.1         pyhd8ed1ab_2                       conda-forge
  openff-utilities               0.1.16        pyhd8ed1ab_1                       conda-forge
  openjpeg                       2.5.4         h55fea9a_0                         conda-forge
  openldap                       2.6.10        he970967_0                         conda-forge
  openmm                         8.4.0         py312ha28768a_2                    conda-forge
  openmmforcefields              0.15.1        pyhcf101f3_1                       conda-forge
  openmmtools                    0.25.3        pyhd8ed1ab_0                       conda-forge
  openssl                        3.6.2         h35e630c_0                         conda-forge
  opt-einsum                     3.4.0         hd8ed1ab_1                         conda-forge
  opt_einsum                     3.4.0         pyhd8ed1ab_1                       conda-forge
  optree                         0.19.0        py312hd9148b4_0                    conda-forge
  overrides                      7.7.0         pyhd8ed1ab_1                       conda-forge
  packaging                      26.1          pyhc364b38_0                       conda-forge
  pandas                         2.3.3         py312hf79963d_1                    conda-forge
  pandocfilters                  1.5.0         pyhd8ed1ab_0                       conda-forge
  pango                          1.56.4        hadf4263_0                         conda-forge
  parmed                         4.3.1         py312h7ab193c_0                    conda-forge
  parso                          0.8.6         pyhcf101f3_0                       conda-forge
  patsy                          1.0.2         pyhcf101f3_0                       conda-forge
  pcre2                          10.47         haa7fec5_0                         conda-forge
  pdbfixer                       1.12          pyhd8ed1ab_1                       conda-forge
  perl                           5.32.1        7_hd590300_perl5                   conda-forge
  pexpect                        4.9.0         pyhd8ed1ab_1                       conda-forge
  pillow                         12.2.0        py312h50c33e8_0                    conda-forge
  pint                           0.24.4        pyhe01879c_2                       conda-forge
  pip                            26.0.1        pyh8b19718_0                       conda-forge
  pixman                         0.46.4        h54a6638_1                         conda-forge
  platformdirs                   4.9.6         pyhcf101f3_0                       conda-forge
  plotly                         6.6.0         pyhd8ed1ab_0                       conda-forge
  plugcli                        0.2.1         pyhd8ed1ab_0                       conda-forge
  pluggy                         1.6.0         pyhf9edf01_1                       conda-forge
  pooch                          1.9.0         pyhd8ed1ab_0                       conda-forge
  prometheus_client              0.25.0        pyhd8ed1ab_0                       conda-forge
  prompt-toolkit                 3.0.52        pyha770c72_0                       conda-forge
  protobuf                       4.25.3        py312h83439f5_1                    conda-forge
  psutil                         7.1.3         py312h5253ce2_0                    conda-forge
  pthread-stubs                  0.4           hb9d3cd8_1002                      conda-forge
  ptyprocess                     0.7.0         pyhd8ed1ab_1                       conda-forge
  pure_eval                      0.2.3         pyhd8ed1ab_1                       conda-forge
  py-cpuinfo                     9.0.0         pyhd8ed1ab_1                       conda-forge
  py3dmol                        2.5.4         pyhd8ed1ab_0                       conda-forge
  pycairo                        1.29.0        py312h2596900_1                    conda-forge
  pycparser                      2.22          pyh29332c3_1                       conda-forge
  pydantic                       2.11.10       pyh3cfb1c2_0                       conda-forge
  pydantic-core                  2.33.2        py312h680f630_0                    conda-forge
  pyedr                          0.8.0         pyhd8ed1ab_1                       conda-forge
  pygments                       2.20.0        pyhd8ed1ab_0                       conda-forge
  pygraphviz                     1.14          py312hdfa1987_2                    conda-forge
  pymbar                         4.2.0         pyha770c72_2                       conda-forge
  pymbar-core                    4.2.0         pyhd8ed1ab_2                       conda-forge
  pyparsing                      3.3.2         pyhcf101f3_0                       conda-forge
  pysocks                        1.7.1         pyha55dd90_7                       conda-forge
  pytables                       3.11.1        py312hefc0c3f_1                    conda-forge
  pytest                         9.0.3         pyhc364b38_1                       conda-forge
  pytest-datadir                 1.8.0         pyhd8ed1ab_0                       conda-forge
  pytest-regressions             2.10.0        pyhc455866_0                       conda-forge
  pytest-rerunfailures           16.1          pyhd8ed1ab_0                       conda-forge
  python                         3.12.13       hd63d673_0_cpython                 conda-forge
  python-constraint              1.4.0         pyhff2d567_1                       conda-forge
  python-dateutil                2.9.0.post0   pyhe01879c_2                       conda-forge
  python-fastjsonschema          2.21.2        pyhe01879c_0                       conda-forge
  python-flatbuffers             25.9.23       pyh1e1bc0e_0                       conda-forge
  python-gil                     3.12.13       hd8ed1ab_0                         conda-forge
  python-json-logger             2.0.7         pyhd8ed1ab_0                       conda-forge
  python-tzdata                  2026.1        pyhd8ed1ab_0                       conda-forge
  python_abi                     3.12          8_cp312                            conda-forge
  pytng                          0.3.4         py312heed6b8f_0                    conda-forge
  pytorch                        2.3.1         cpu_mkl_py312h3b258cc_100          conda-forge
  pytorch-lightning              2.6.1         pyhcf101f3_0                       conda-forge
  pytz                           2026.1.post1  pyhcf101f3_0                       conda-forge
  pyyaml                         6.0.3         py312h8a5da7c_1                    conda-forge
  pyzmq                          27.1.0        py312hda471dd_2                    conda-forge
  qhull                          2020.2        h434a139_5                         conda-forge
  rdkit                          2025.09.5     py312h3ecb6ed_0                    conda-forge
  re2                            2023.09.01    h7f4b329_2                         conda-forge
  readline                       8.3           h853b02a_0                         conda-forge
  referencing                    0.37.0        pyhcf101f3_0                       conda-forge
  reportlab                      4.4.10        pyhcf101f3_1                       conda-forge
  requests                       2.33.1        pyhcf101f3_1                       conda-forge
  rfc3339-validator              0.1.4         pyhd8ed1ab_1                       conda-forge
  rfc3986-validator              0.1.1         pyh9f0ad1d_0                       conda-forge
  rfc3987-syntax                 1.1.0         pyhe01879c_1                       conda-forge
  rich                           15.0.0        pyhcf101f3_0                       conda-forge
  rlpycairo                      0.4.0         pyh6c17108_0                       conda-forge
  rocm-core                      7.0.2         h54a6638_0                         conda-forge
  rpds-py                        0.30.0        py312h868fb18_0                    conda-forge
  s2n                            1.5.5         h3931f03_0                         conda-forge
  scikit-learn                   1.8.0         np2py312h3226591_1                 conda-forge
  scikit-mol                     0.6.1         pyhd8ed1ab_0                       conda-forge
  scipy                          1.17.1        py312h54fa4ab_0                    conda-forge
  seaborn                        0.13.2        hd8ed1ab_3                         conda-forge
  seaborn-base                   0.13.2        pyhd8ed1ab_3                       conda-forge
  send2trash                     2.1.0         pyha191276_1                       conda-forge
  setuptools                     82.0.1        pyh332efcf_0                       conda-forge
  six                            1.17.0        pyhe01879c_1                       conda-forge
  sleef                          3.9.0         ha0421bc_0                         conda-forge
  snappy                         1.2.2         h03e3b7b_1                         conda-forge
  sniffio                        1.3.1         pyhd8ed1ab_2                       conda-forge
  soupsieve                      2.8.3         pyhd8ed1ab_0                       conda-forge
  spectate                       1.0.1         pyhd8ed1ab_0                       conda-forge
  sqlalchemy                     2.0.49        py312h5253ce2_0                    conda-forge
  stack_data                     0.6.3         pyhd8ed1ab_1                       conda-forge
  statsmodels                    0.14.6        py312h4f23490_0                    conda-forge
  sympy                          1.14.0        pyh2585a3b_106                     conda-forge
  tbb                            2021.13.0     h8d10470_4                         conda-forge
  tensorboard                    2.17.1        pyhd8ed1ab_0                       conda-forge
  tensorboard-data-server        0.7.0         py312h4eba8b5_4                    conda-forge
  tensorflow                     2.17.0        cpu_py312h69ecde4_2                conda-forge
  tensorflow-base                2.17.0        cpu_py312h823dedb_2                conda-forge
  tensorflow-estimator           2.17.0        cpu_py312h4f468f2_2                conda-forge
  termcolor                      3.3.0         pyhd8ed1ab_0                       conda-forge
  terminado                      0.18.1        pyhc90fa1f_1                       conda-forge
  threadpoolctl                  3.6.0         pyhecae5ae_0                       conda-forge
  tidynamics                     1.1.2         pyhd8ed1ab_0                       conda-forge
  tinycss2                       1.4.0         pyhd8ed1ab_0                       conda-forge
  tinydb                         4.8.2         pyhd8ed1ab_1                       conda-forge
  tk                             8.6.13        noxft_h366c992_103                 conda-forge
  tomli                          2.4.1         pyhcf101f3_0                       conda-forge
  torchdata                      0.7.1         py312he3f8c6c_7                    conda-forge
  torchmetrics                   1.9.0         pyhd8ed1ab_0                       conda-forge
  tornado                        6.5.5         py312h4c3975b_0                    conda-forge
  tqdm                           4.67.3        pyh8f84b5b_0                       conda-forge
  traitlets                      5.14.3        pyhd8ed1ab_1                       conda-forge
  typing-extensions              4.15.0        h396c80c_0                         conda-forge
  typing-inspection              0.4.2         pyhd8ed1ab_1                       conda-forge
  typing_extensions              4.15.0        pyhcf101f3_0                       conda-forge
  typing_utils                   0.1.0         pyhd8ed1ab_1                       conda-forge
  tzdata                         2025c         hc9c84f9_1                         conda-forge
  unicodedata2                   17.0.1        py312h4c3975b_0                    conda-forge
  uri-template                   1.3.0         pyhd8ed1ab_1                       conda-forge
  urllib3                        2.6.3         pyhd8ed1ab_0                       conda-forge
  validators                     0.35.0        pyhd8ed1ab_0                       conda-forge
  wayland                        1.25.0        hd6090a7_0                         conda-forge
  wcwidth                        0.6.0         pyhd8ed1ab_0                       conda-forge
  webcolors                      25.10.0       pyhd8ed1ab_0                       conda-forge
  webencodings                   0.5.1         pyhd8ed1ab_3                       conda-forge
  websocket-client               1.9.0         pyhd8ed1ab_0                       conda-forge
  werkzeug                       3.1.8         pyhcf101f3_0                       conda-forge
  wheel                          0.47.0        pyhd8ed1ab_0                       conda-forge
  widgetsnbextension             4.0.15        pyhd8ed1ab_0                       conda-forge
  wrapt                          2.1.2         py312h4c3975b_0                    conda-forge
  xkeyboard-config               2.47          hb03c661_0                         conda-forge
  xmltodict                      1.0.2         pyhcf101f3_0                       conda-forge
  xorg-libice                    1.1.2         hb9d3cd8_0                         conda-forge
  xorg-libsm                     1.2.6         he73a12e_0                         conda-forge
  xorg-libx11                    1.8.13        he1eb515_0                         conda-forge
  xorg-libxau                    1.0.12        hb03c661_1                         conda-forge
  xorg-libxcomposite             0.4.7         hb03c661_0                         conda-forge
  xorg-libxcursor                1.2.3         hb9d3cd8_0                         conda-forge
  xorg-libxdamage                1.1.6         hb9d3cd8_0                         conda-forge
  xorg-libxdmcp                  1.1.5         hb03c661_1                         conda-forge
  xorg-libxext                   1.3.7         hb03c661_0                         conda-forge
  xorg-libxfixes                 6.0.2         hb03c661_0                         conda-forge
  xorg-libxi                     1.8.2         hb9d3cd8_0                         conda-forge
  xorg-libxinerama               1.1.6         hecca717_0                         conda-forge
  xorg-libxrandr                 1.5.5         hb03c661_0                         conda-forge
  xorg-libxrender                0.9.12        hb9d3cd8_0                         conda-forge
  xorg-libxt                     1.3.1         hb9d3cd8_0                         conda-forge
  xorg-libxtst                   1.2.5         hb9d3cd8_3                         conda-forge
  xorg-libxxf86vm                1.1.7         hb03c661_0                         conda-forge
  xorg-xorgproto                 2025.1        hb03c661_0                         conda-forge
  yaml                           0.2.5         h280c20c_3                         conda-forge
  zeromq                         4.3.5         h387f397_9                         conda-forge
  zipp                           3.23.1        pyhcf101f3_0                       conda-forge
  zlib                           1.3.2         h25fd6f3_2                         conda-forge
  zlib-ng                        2.3.3         hceb46e0_1                         conda-forge
  zstandard                      0.25.0        py312h5253ce2_1                    conda-forge
  zstd                           1.5.7         hb78ec9c_6                         conda-forge

Output
(paths redacted)

Traceback (most recent call last):
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/bin/openfe", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/click/core.py", line 1485, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/click/core.py", line 1406, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/click/core.py", line 1873, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/click/core.py", line 1269, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/click/core.py", line 824, in invoke
    return callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/openfecli/utils.py", line 116, in wrapper
    result = function(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/openfecli/commands/quickrun.py", line 188, in quickrun
    json.dump(out_dict, outf, cls=JSON_HANDLER.encoder)
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/__init__.py", line 179, in dump
    for chunk in iterable:
                 ^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 432, in _iterencode
    yield from _iterencode_dict(o, _current_indent_level)
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 406, in _iterencode_dict
    yield from chunks
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 406, in _iterencode_dict
    yield from chunks
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 406, in _iterencode_dict
    yield from chunks
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 326, in _iterencode_list
    yield from chunks
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 326, in _iterencode_list
    yield from chunks
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 439, in _iterencode
    o = _default(o)
        ^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/site-packages/gufe/serialization/json.py", line 138, in default
    return json.JSONEncoder.default(self, obj)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/p/project1/project_name/user/mamba/envs/openfe_esp/lib/python3.12/json/encoder.py", line 180, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type OSError is not JSON serializable

Expected behavior
Simulation should run and complete successfully.

Additional context
In past versions I had a similar problem when using espaloma where the formatting of db.json (which I see doesn't exist anymore now?) would break and cause a similar error. When I reformatted the file correctly myself, the simulation could then run successfully. I tried modifying the dag json in the quickrun_cache to see if anything would change but did not have much success. I'm not sure if a similar error is happening elsewhere or if it's something else entirely. I'm a bit short on time so I just decided to ask if you have a workaround.

Thank you and hope to hear from you soon.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions