Maybe you can instead do something like:
```
assert astropy.version.major >0 or astropy.version.minor > 2, 'Astropy version is older than 0.3!'
```
then someone who runs this on an old version will get a real error message instead of having to actually read the output.

Or, if you think that's an extra unnecessary complication, it's ok as is too.