simonarvin / eyeloop

EyeLoop is a Python 3-based eye-tracker tailored specifically to dynamic, closed-loop experiments on consumer-grade hardware.
GNU General Public License v3.0
485 stars 67 forks source link

Travis CI: Lint Python code for undefined names #1

Closed cclauss closed 4 years ago

cclauss commented 4 years ago

https://flake8.pycqa.org/en/latest/user/error-codes.html

On the flake8 test selection, this PR does not focus on "style violations" (the majority of flake8 error codes that psf/black can autocorrect). Instead these tests are focus on runtime safety and correctness:

simonarvin commented 4 years ago

Hi! The vimba Importer is designed to import camera frames from a Vimba-compatible camera. For offline tracking, use cv Importer instead.

Best, Simon

cclauss commented 4 years ago

Ahh... Now I see. Thanks. What about image and Frame?

flake8 testing of https://github.com/

$ flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics

./importers/vimba.py:24:33: F821 undefined name 'image'
        self.arm(width, height, image)
                                ^
./importers/vimba.py:27:36: F821 undefined name 'Frame'
    def acquire_frame(self, frame: Frame, delay: int = 1) -> None:
                                   ^
2     F821 undefined name 'image'
2
simonarvin commented 4 years ago

Right, thank you for noticing. Should be fixed now!

cclauss commented 4 years ago

Tests now pass.