Lookup country and Russia region by IP address Python module with script to create database from up-to-date official data.
$ hg clone http://bitbucket.org/ods/ip2cc/
$ hg clone ssh://hg@bitbucket.org/ods/ip2cc/