Using the blob module

Also other minor changes