srobo / sr-robot3-j5

Python 3 API for Student Robotics Kit - Built with j5
MIT License
4 stars 1 forks source link

Add ruggeduino support #12

Closed trickeydan closed 4 years ago

trickeydan commented 4 years ago

Theoretically closes #3

trickeydan commented 4 years ago

@RealOrangeOne Requesting review from you specifically on the Python usage here.

Is it acceptable, especially around line 99. Not sure if it's too introspecty.

trickeydan commented 4 years ago

I'm not seeing any introspection going on

ruggeduino_backend = self._environment.get_backend(Ruggeduino)

class IgnoredRuggeduinoBackend(ruggeduino_backend):

This dynamic inheritance is the bit I'm concerned about. Requires type ignores for mypy, but also feels a bit dodgy. I can't think of a better way to do it though unfortunately.