diff options
Diffstat (limited to 'sleekxmpp/plugins/xep_0082.py')
-rw-r--r-- | sleekxmpp/plugins/xep_0082.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/sleekxmpp/plugins/xep_0082.py b/sleekxmpp/plugins/xep_0082.py index 785ba36b..e78a50ad 100644 --- a/sleekxmpp/plugins/xep_0082.py +++ b/sleekxmpp/plugins/xep_0082.py @@ -6,11 +6,18 @@ See the file LICENSE for copying permission. """ +import logging import datetime as dt -from dateutil import parser -from dateutil.tz import tzoffset, tzutc + from sleekxmpp.plugins.base import base_plugin +try: + from dateutil import parser + from dateutil.tz import tzoffset, tzutc +except e: + log = logging.getLogger(__name__) + log.warning("XEP-0082 plugin requires dateutil") + # ===================================================================== # To make it easier for stanzas without direct access to plugin objects |