Skip to content

feat: use im-rdkit-utilities instead of local rdkit_utils.py - #21

Merged
tdudgeon merged 1 commit into
mainfrom
feat/use-im-rdkit-utilities
Aug 5, 2026
Merged

feat: use im-rdkit-utilities instead of local rdkit_utils.py#21
tdudgeon merged 1 commit into
mainfrom
feat/use-im-rdkit-utilities

Conversation

@tdudgeon

@tdudgeon tdudgeon commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Deletes root rdkit_utils.py and adds im-rdkit-utilities==1.0.0 to the Dockerfiles that ship the affected scripts instead.
  • The local copy was functionally identical to the new package (formatting/docstrings only) — all 13 consuming scripts (open3dalign.py, sucos.py, assemble_conformers.py, cluster_butina.py, enumerate.py, le_conformers.py, rdkit_dedup.py, rdkit_props.py, sa_score.py, screen.py, reactor.py, im_mordred/descriptor_generator.py, moldb/enumerate.py, moldb/filter.py) already call generate_headers/create_reader/create_writer with the canonical signature, so no call sites needed changing.
  • Fixes two real latent bugs the local copy carried: DmLog and Descriptors were referenced but never imported, crashing the rdk_read_molecule_files warning path and fragment(mode='mw') respectively whenever hit. Verified both fixed against the real installed package.
  • Dockerfiles updated: Dockerfile-prep, Dockerfile-mordred, Dockerfile-moldb, Dockerfile-oddt, Dockerfile-jaqpot — traced via the .nf process container directives and data-manager/*.yaml job command/image entries, not guessed. (Dockerfile-jaqpot already had a stale COPY of jaqpot*.py files that don't exist in this repo — pre-existing and unrelated, left as found aside from the rdkit_utils.py reference.)

Part of InformaticsMatters/squonk2-jobs#18.

Test plan

  • All 13 consuming scripts compile
  • Ran rdkit_props.py's full read/calc/write loop against real installed im-rdkit-utilities with synthetic SMILES data — correct output
  • Verified fragment(mol, 'mw') and the rdk_read_molecule_files warning path no longer NameError
  • CI / jote run per affected job

🤖 Generated with Claude Code

The local copy was functionally identical to the newly published
im-rdkit-utilities package (formatting/docstrings only), so this is a
straight swap - all 13 consuming scripts already called it with the
canonical signatures (generate_headers, create_reader/create_writer,
etc), no call sites needed changing.

This also fixes two latent bugs the local copy carried: DmLog and
Descriptors were used but never imported, crashing the
rdk_read_molecule_files warning path and fragment(mode='mw')
respectively. Both verified fixed against the real installed package.

Adds im-rdkit-utilities==1.0.0 to the Dockerfiles that actually ship
the affected scripts (traced via the .nf process definitions and
data-manager/*.yaml job commands): prep, mordred, moldb, oddt, and
jaqpot (the last of these already had a stale/dead COPY of
non-existent jaqpot*.py files, unrelated pre-existing issue, left as
found otherwise).

Part of InformaticsMatters/squonk2-jobs#18.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@tdudgeon
tdudgeon merged commit 96840c5 into main Aug 5, 2026
7 of 12 checks passed
@tdudgeon
tdudgeon deleted the feat/use-im-rdkit-utilities branch August 5, 2026 12:06
tdudgeon added a commit that referenced this pull request Aug 5, 2026
im-rdkit-utilities==1.0.0 hard-pins im-data-manager-job-utilities==1.3.0,
which conflicted with these Dockerfiles' older pins (1.1.1/1.0.1) and
broke the build entirely (ResolutionImpossible) - not caught in #21
because the images weren't rebuilt locally at review time.

Verified: mordred, moldb and oddt images now build and pass their jote
suites end-to-end (mordred: 2/2, moldb's non-nextflow jobs, plus a
direct check of updateChargeFlagInAtomBlock). prep's image build is
separately blocked by an unrelated, pre-existing issue: its apt-get
step pulls packages from bullseye-security that have since been pruned
from the Debian mirror - confirmed this also fails identically on the
pre-migration Dockerfile-prep, so it's not something this change
introduced. Verified prep's pip resolution (the part this change
actually touches) succeeds cleanly in isolation.

Part of #18.

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
tdudgeon added a commit that referenced this pull request Aug 5, 2026
Dockerfile-prep never ran apt-get update itself, relying on the
package index baked into informaticsmatters/vs-rdkit-base:latest at
base-image build time. Since bullseye-security periodically prunes
superseded point-release .debs, that stale index eventually points at
files that no longer exist, and the build starts failing with 404s -
this is what was blocking jote for open3dalign, sucos,
assemble_conformers, cluster_butina, enumerate, le_conformers,
rdkit_dedup, rdkit_props, sa_score, screen and reactor after #21/#22.

No version is pinned for openbabel here, so a fresh apt-get update
resolves to whatever build is currently on the mirror instead (still
3.1.1, just a different point release).

Verified: image builds; full im-virtual-screening/rdkit/xchem jote
suite passes 32/32 (with NXF_VER=22.10.0 per docs/testing-jobs.md, for
the nextflow-based jobs in the same suite).

Part of #18.

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant