A Python library that provides an easy way to identify devices like mobile phones, tablets and their capabilities by parsing (browser) user agent strings.
Why do you think that https://github.com/dabeaz/ply is a good alternative to python-user-agents