You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Round-trip read/write of SDF files is failing due to incorrect handling for positive formal charge values on write. According to this resouce we should have:
int charge = int(atom.property<SireUnits::Dimension::Charge>(map["formal_charge"]).value());
if (charge >= 4or charge < -3)
{
sdfmol.addProperty("CHG", i + 1, QString::number(charge));
charge = 0;
}
elseif (charge < 0)
{
switch (charge)
{
case -1:
charge = 5;
break;
case -2:
charge = 6;
break;
case -3:
charge = 7;
break;
}
}
This has no conditional for positive formal charge, so it just takes the formal charge value, i.e. 1 would be written as 1, not 3. I'm also not sure what one does about the additional "doublet radical" option, which should have a value of 4?
The text was updated successfully, but these errors were encountered:
Round-trip read/write of SDF files is failing due to incorrect handling for positive formal charge values on write. According to this resouce we should have:
The code is handled here
sire/corelib/src/libs/SireIO/sdf.cpp
Lines 953 to 976 in ecfef72
This has no conditional for positive formal charge, so it just takes the formal charge value, i.e. 1 would be written as 1, not 3. I'm also not sure what one does about the additional "doublet radical" option, which should have a value of 4?
The text was updated successfully, but these errors were encountered: