pip install torrent_parser
$ pytp test.torrent
$ cat test.torrent | pytp
>>> import torrent_parser as tp
>>> data = tp.parse_torrent_file('test.torrent')
>>> print(data['announce'])
http://tracker.trackerfix.com:80/announce
python -m unittest test
See License.