Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#1182 Enhanced stereo labels on atropisomers are lost when opening molfiles #1218

Merged
merged 2 commits into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 3 additions & 15 deletions api/tests/integration/ref/formats/mol_to_ket.py.out
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,6 @@
1032-quadra.ket:SUCCEED
1046-imp_hydrogen.ket:SUCCEED
SgroupDifferent.ket:SUCCEED
suplabel.ket:FAILED
---

+++

@@ -36,7 +36,7 @@

0,
1
],
- "name": "\"sodium"
+ "name": "sodium chloride"
}
]
}
atropisomer.ket:SUCCEED
non_atrop.ket:SUCCEED
suplabel.ket:SUCCEED
10 changes: 9 additions & 1 deletion api/tests/integration/tests/formats/mol_to_ket.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,21 @@ def find_diff(a, b):

indigo = Indigo()
indigo.setOption("json-saving-pretty", True)
indigo.setOption("ignore-stereochemistry-errors", True)

print("*** MOL to KET ***")

root = joinPathPy("molecules/", __file__)
ref_path = joinPathPy("ref/", __file__)

files = ["1032-quadra", "1046-imp_hydrogen", "SgroupDifferent", "suplabel"]
files = [
"1032-quadra",
"1046-imp_hydrogen",
"SgroupDifferent",
"suplabel",
"atropisomer",
"non_atrop",
]

files.sort()
for filename in files:
Expand Down
48 changes: 48 additions & 0 deletions api/tests/integration/tests/formats/molecules/atropisomer.mol
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@

RDKit 2D

0 0 0 0 0 0 0 0 0 0999 V3000
M V30 BEGIN CTAB
M V30 COUNTS 16 17 0 0 0
M V30 BEGIN ATOM
M V30 1 C 25.514800 -10.612600 0.000000 0
M V30 2 C 28.110200 -10.611900 0.000000 0
M V30 3 C 26.815000 -9.862500 0.000000 0
M V30 4 C 28.110200 -12.113300 0.000000 0
M V30 5 C 25.514800 -12.120000 0.000000 0
M V30 6 C 26.818200 -12.862500 0.000000 0
M V30 7 C 26.818200 -14.362500 0.000000 0
M V30 8 C 28.118100 -16.609000 0.000000 0
M V30 9 C 28.118500 -15.112600 0.000000 0
M V30 10 C 26.818300 -17.360600 0.000000 0
M V30 11 C 25.513300 -15.117100 0.000000 0
M V30 12 C 25.523000 -16.617200 0.000000 0
M V30 13 N 29.179100 -14.051900 0.000000 0
M V30 14 C 29.410000 -12.862000 0.000000 0
M V30 15 O 24.217900 -12.873800 0.000000 0
M V30 16 C 26.820800 -18.860600 0.000000 0
M V30 END ATOM
M V30 BEGIN BOND
M V30 1 2 3 1
M V30 2 2 4 2
M V30 3 1 1 5
M V30 4 1 2 3
M V30 5 2 5 6
M V30 6 1 6 4 CFG=1
M V30 7 1 6 7
M V30 8 2 9 7
M V30 9 2 10 8
M V30 10 1 7 11
M V30 11 1 8 9
M V30 12 2 11 12
M V30 13 1 12 10
M V30 14 1 9 13
M V30 15 1 4 14
M V30 16 1 5 15
M V30 17 1 10 16
M V30 END BOND
M V30 BEGIN COLLECTION
M V30 MDLV30/STEREL1 ATOMS=(1 6)
M V30 END COLLECTION
M V30 END CTAB
M END
46 changes: 46 additions & 0 deletions api/tests/integration/tests/formats/molecules/non_atrop.mol
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@

-INDIGO-08082300302D

0 0 0 0 0 0 0 0 0 0 0 V3000
M V30 BEGIN CTAB
M V30 COUNTS 16 15 0 0 0
M V30 BEGIN ATOM
M V30 1 C 21.15 -11.859 0.0 0
M V30 2 C 21.15 -13.591 0.0 0
M V30 3 C 20.65 -12.725 0.0 0
M V30 4 C 22.15 -13.591 0.0 0
M V30 5 C 22.15 -11.859 0.0 0
M V30 6 C 22.65 -12.725 0.0 0 CFG=1
M V30 7 C 23.65 -12.725 0.0 0
M V30 8 C 25.15 -13.591 0.0 0
M V30 9 C 24.15 -13.591 0.0 0
M V30 10 C 25.65 -12.725 0.0 0
M V30 11 C 24.15 -11.859 0.0 0
M V30 12 C 25.15 -11.859 0.0 0
M V30 13 N 24.05 -15.0571 0.0 0
M V30 14 C 22.15 -14.9571 0.0 0
M V30 15 O 22.65 -10.9929 0.0 0
M V30 16 C 26.65 -12.725 0.0 0
M V30 END ATOM
M V30 BEGIN BOND
M V30 1 2 4 2
M V30 2 1 1 5
M V30 3 1 2 3
M V30 4 2 5 6
M V30 5 1 6 4
M V30 6 1 6 7 CFG=1
M V30 7 2 9 7
M V30 8 2 10 8
M V30 9 1 7 11
M V30 10 1 8 9
M V30 11 1 12 10
M V30 12 1 9 13
M V30 13 1 4 14
M V30 14 1 5 15
M V30 15 1 10 16
M V30 END BOND
M V30 BEGIN COLLECTION
M V30 MDLV30/STEREL1 ATOMS=(1 6)
M V30 END COLLECTION
M V30 END CTAB
M END
Loading
Loading