fishpepper/pyUSBtin

The filtermask submodule isn't valid Python!

Opened this issue · 0 comments

The author of the filtermask module appears to have been writing in a language other than Python.
The class defines two __init__ methods in an attempt to create overloaded constructors like in C++ or Java. This does not work in Python - the second definition merely overwrites the first and the first is thrown away.
Once in the __init__ method, the first thing that happens is the 'registers' member is set to be an empty list of zero length. Then it tries to set the first four elements of this zero-length list, which don't exist because it's zero length!