gl: a few more tests and fixes.

And I did test flake8 this time!