[tor-bugs] #30586 [Metrics/Onionperf]: requirements are not included in setup.py

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri May 29 14:01:51 UTC 2020


#30586: requirements are not included in setup.py
---------------------------------------+--------------------------------
 Reporter:  irl                        |          Owner:  phw
     Type:  defect                     |         Status:  merge_ready
 Priority:  Medium                     |      Milestone:
Component:  Metrics/Onionperf          |        Version:
 Severity:  Normal                     |     Resolution:
 Keywords:  metrics-team-roadmap-2020  |  Actual Points:  0.45
Parent ID:  #33321                     |         Points:  0.5
 Reviewer:                             |        Sponsor:  Sponsor59-must
---------------------------------------+--------------------------------

Comment (by acute):

 Replying to [comment:18 karsten]:
 > Almost there! Two further questions:
 >
 >  1. What if I want to run `onionperf` from another directory than
 `onionperf/onionperf`? I tried passing another relative or absolute path
 to `PYTHONPATH=`, but all I get is: `/usr/bin/python3: can't find
 '__main__' module in 'onionperf'`.
 You also need to specify the absolute/relative path to the onionperf
 script as well in that case, for example:

 `PYTHONPATH=/home/dev/onionperf python3
 /home/dev/onionperf/onionperf/onionperf`

 Just as a note, you can copy the script itself anywhere else on the system
 and this will still work, as long as you point the PYTHONPATH to the
 onionperf directory.
 {{{
 cp /home/dev/onionperf/onionperf/onionperf /home/dev/op
 PYTHONPATH=/home/dev/onionperf python3 /home/dev/op
 }}}
 or even directly:
 {{{
 PYTHONPATH=/home/dev/onionperf /home/dev/op
 }}}
 ...since the python3 interpreter is in a sensible place anyway.
 Hope this helps!

 >
 >  2. Do you mind posting a new branch with phw's branch rebased to
 current master and with your two patches (the one on #33433 and the one
 above) on top? I would do this myself, but I'm having trouble applying
 your patches, and I don't want to claim authorship of these commits.

 This is now here:
 https://github.com/ana-cc/onionperf/tree/acute/30586

 Thank you!

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/30586#comment:19>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list