Fix Python 3, also add test for count across multiple backends