```
if not all(c.strip() for c in version):
    raise ValueError('unexpected whitespace characters in version string.')
```