brentp/pyfasta — pull request #14 by mruffalo (2013-08-28 03:31:35+00:00)
Title: ez_setup.py: fix str/bytes mismatch

I noticed this while investigating @smilefreak's first pull request; may as well fix it.

Commit message:
```
This file reads itself in the update_md5 function in order to to update
the md5_data dict. The file contents are then matched against a text
regex, so the file has to be opened in text mode to match. Otherwise
this mismatch will manifest as

TypeError: can't use a string pattern on a bytes-like object

Since this file is entirely ASCII, it's safe to read it in text mode
without specifying an encoding.

While I was looking at it, also do some other cleanups/style tweaks:
drop unused imports and use open() calls as context managers.
```