We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug Adding a string property with multiple new lines generates invalid SD blocks.
To Reproduce
>>> m.SetProp("foo", "docked\n\ndocked") >>> out = Chem.SDWriter(sys.stdout) >>> out.write(m) >>> out.close() RDKit 2D 1 0 0 0 0 0 0 0 0 0999 V2000 0.0000 0.0000 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0 M END > <foo> (1) docked docked $$$$
Expected behavior RDKit should either reject writing these properties or strip the new lines. It shouldn't write an invalid file.
The text was updated successfully, but these errors were encountered:
It's easy enough to fix this. The question is what the right behavior is:
\n
I would not do either 1 or 4, but I think either 2 or 3 would be ok. I guess I have a slight preference for 2.
Sorry, something went wrong.
fixes rdkit#5827
1f8f5d1
Ok, I implemented solution 2 in the fix in #5873
9886db0
fixes #5827 (#5873)
e47fc9a
* fixes #5827 * changes in response to review
greglandrum
No branches or pull requests
Describe the bug
Adding a string property with multiple new lines generates invalid SD blocks.
To Reproduce
Expected behavior
RDKit should either reject writing these properties or strip the new lines. It shouldn't write an invalid file.
The text was updated successfully, but these errors were encountered: