Hi,
I was surprised to see that a (dubious) structure that goes through
SanitizeMol OK can fail a subsequent sanitization call:
print("Start")
mol = Chem.MolFromSmiles('C1=n(C)-c=Cn1', sanitize=False)
print("Before first sanitization")
Chem.SanitizeMol(mol)
print("Before second sanitization")
Che
Hi Ivan,
Short answer: I would not normally expect a second sanitization to fail if
the first succeeds, but your input SMILES is very odd and triggers a bug.
This is an interesting edge case for the sanitization code because it
includes a weird mix of aromatic and aliphatic atoms and bonds, I do
Hi Greg,
Thanks for the detailed explanation. You are right that this is not a real
molecule; it came from applying a user-supplied reaction SMARTS. (The
reaction SMARTS was not the best-written perhaps, but that's
tangential...). I normally sanitize the products and skip those that fail
the sanit
Interesting timing! I have just come across this exact same issue when
experimenting with new SMARTS-based standardisations (so, yes, treating
unnatural molecules in unwholesome ways).
I 'fixed' it by calling SanitzeMol twice.
On 31/10/2018 14:48, Ivan Tubert-Brohman wrote:
Hi Greg,
Thanks f
4 matches
Mail list logo