py3k version seems to work