Chem: add #meta.role: transform to stand-alone scripts for datasync support - #3945
Draft
Aleksashka11 wants to merge 3 commits into
Draft
Chem: add #meta.role: transform to stand-alone scripts for datasync support#3945Aleksashka11 wants to merge 3 commits into
Aleksashka11 wants to merge 3 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Drafted by Grokky from a Slack thread.
Root cause: File:
packages/Chem/scripts/stand-alone/butina_cluster.py(and sibling scriptsmurcko_scaffold.py,filter_catalogs.py)What breaks: When a project is saved with datasync enabled and then reopened, the Butina-cluster step is not replayed — the platform sees only a stale, frozen result column instead of re-running the function.
Where: The datasync subsystem decides whether a function result can be replayed by checking for the
#meta.role: transformscript header. Every biochemical-calculator script that correctly supports datasync carries this tag (calc_logP.py,calc_logS.py,calc_pI.py,calc_pKas.py). All three stand-alone scripts (butina_cluster.py,murcko_scaffold.py,filter_catalogs.py) are missing it, even though they also use{action:join(data)}in their#outputdirective (i.e. they produce joined result columns exactly like the calculators do).Why:
butina_cluster.pywas added to the top-menu (Chem | Analyze | Butina Cluster...) without the matching datasync annotation. Without#meta.role: transform, the platform cannot identify the function as re-runnable during project restore, so it displays the state frozen at save-time rather than recalculating — producing "incorrect results for Butina cluster" as reported.Note:
calc_logD.pyhas the same annotation gap, but that is outside the scope of GROK-20508.Reproduced on dev: Reproduction requires save/restore of a project with datasync through the full UI, which is not automatable through the JS API alone. Root cause is established purely by static code comparison.
Thread: https://datagrok.slack.com/archives/C04BF3YM6CF/p1785227533092579?thread_ts=1785227533.092579&cid=C04BF3YM6CF