Fixes issue #572

Not sure why I was using `set_attributes` here instead of the built-in `setup`, but this fixes that.