Skip to content

Disallow ToolkitWrapper objects passed to toolkit_registry #1066

Closed as not planned
@mattwthompson

Description

@mattwthompson

In #1050 @j-wags and I re-encountered strange behavior relating to the toolkit_registry argument in some Molecule API points. The behavior is different if a ToolkitWrapper and ToolkitRegistry argument is passed and the wrapper or all wrappers in the registry fail. I can expand on the failure cases later.

A solution would involve forbidding ToolkitWrapper objects passed to toolkit_registry; initially with a deprecation warning but later with an exception. The migration would involve simply passing a single-wrapper registry in place of a wrapper object, i.e.

Molecule.some_api_point(
    ...
    toolkit_registry=OpenEyeToolkitWrapper(),
    ...
)

will need to become

Molecule.some_api_point(
    ...
    toolkit_registry=ToolkitRegistry(OpenEyeToolkitWrapper()),
    ...
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions