cmd.get_unused_name checks for non-safe chars after checking if the name is already in use.
PyMOL>fab AAA, foo_bar
PyMOL>print cmd.get_unused_name('foo bar', 0)
The returned name is already in use, which must not happen.
Patch attached. This patch also uses a set instead of a dict.
Log in to post a comment.