mirror of
https://github.com/certbot/certbot.git
synced 2026-08-01 00:35:03 +02:00
Change zope's implements to be a class decorator.
When attempting to import any module that uses zope.interface.implements
in Python 3, a TypeError is raised; it reads:
TypeError: Class advice impossible in Python3. Use the @implementer
class decorator instead.
Following the listed advice seems to function in Python 3.
This commit is contained in:
@@ -31,9 +31,9 @@ hostname_regex = re.compile(
|
||||
r"^(([a-z0-9]|[a-z0-9][a-z0-9\-]*[a-z0-9])\.)*[a-z]+$", re.IGNORECASE)
|
||||
|
||||
|
||||
@zope.interface.implementer(interfaces.IPlugin)
|
||||
class Plugin(object):
|
||||
"""Generic plugin."""
|
||||
zope.interface.implements(interfaces.IPlugin)
|
||||
# classProvides is not inherited, subclasses must define it on their own
|
||||
#zope.interface.classProvides(interfaces.IPluginFactory)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user