smn / txgsm

Utilities for talking to a GSM modem over USB via AT commands. Will NOT work with all modems, YMMV.
BSD 3-Clause "New" or "Revised" License
11 stars 5 forks source link

use zope.interface.implementer decorator for py3 compatibility #4

Closed thijstriemstra closed 8 years ago

thijstriemstra commented 8 years ago

Fixes failing tests on python 3.

______________________________________________ ERROR collecting txgsm/tests/test_service.py ______________________________________________
txgsm/tests/test_service.py:4: in <module>
    from txgsm.service import TxGSMServiceMaker, TxGSMService, Options
txgsm/service.py:87: in <module>
    class TxGSMServiceMaker(object):
txgsm/service.py:88: in TxGSMServiceMaker
    implements(IServiceMaker, IPlugin)
../../.virtualenvs/txgsm-py3/lib/python3.4/site-packages/zope/interface/declarations.py:412: in implements
    raise TypeError(_ADVICE_ERROR % 'implementer')
E   TypeError: Class advice impossible in Python3.  Use the @implementer class decorator instead.
smn commented 8 years ago

Thanks for this, I've merged these changes into #5 so I can get travis setup to at least run tests against py3.

thijstriemstra commented 8 years ago

Unfortunately python-messaging isn't Python 3 compatible yet: https://github.com/pmarti/python-messaging/issues/11

smn commented 8 years ago

Neither is it pip installable, I'd like to get rid of the dependency.

thijstriemstra commented 8 years ago

It does install though (saw it's failing https://travis-ci.org/smn/txgsm/jobs/89983080) if you fix it. See/use my fork: https://github.com/thijstriemstra/python-messaging