Update arch.py

Reduces the need of the urllib2 module, as well as fixing some of the code. Also added new features.