[tor-bugs] #11956 [Tor Weather]: Implement relay search functionality of rewritten weather
Tor Bug Tracker & Wiki
blackhole at torproject.org
Mon May 19 06:20:12 UTC 2014
#11956: Implement relay search functionality of rewritten weather
-----------------------------+-----------------------------
Reporter: sreenatha | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone:
Component: Tor Weather | Version:
Resolution: | Keywords: weather-rewrite
Actual Points: | Parent ID:
Points: |
-----------------------------+-----------------------------
Comment (by meejah):
I think we should use the "requests" library (http://docs.python-
requests.org/en/latest/) for these Onionoo transactions; it does HTTPS
certificate hostname checking by default, whereas urllib2 does not.
+1 for having it on a branch already :)
It's probably worth thinking about pulling some common methods out of
these scripts and abstracting some of the calls already, even if it's not
in a database yet.
For example, building URLs to Onionoo, or getting the last-modified-time
of a query (that is, instead of directly accessing the global, call a
method like "query_last_modified(query)". Then when it comes time to add
persistence to a database, you just have to re-write the guts of those
methods.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/11956#comment:2>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list