[tor-bugs] #9199 [BridgeDB]: Rethink the logging of BridgeDB

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Jul 30 04:47:59 UTC 2013


#9199: Rethink the logging of BridgeDB
----------------------+-----------------------------------------------------
 Reporter:  asn       |          Owner:  isis          
     Type:  task      |         Status:  needs_revision
 Priority:  normal    |      Milestone:                
Component:  BridgeDB  |        Version:                
 Keywords:            |         Parent:                
   Points:            |   Actualpoints:                
----------------------+-----------------------------------------------------

Comment(by sysrqb):

 also also, I think you also need
 {{{
 diff --git a/lib/bridgedb/Main.py b/lib/bridgedb/Main.py
 index 1f84091..729e4b0 100644
 --- a/lib/bridgedb/Main.py
 +++ b/lib/bridgedb/Main.py
 @@ -293,6 +293,8 @@ def startup(cfg):
      :ivar logdir: The directory to store logfiles in. Defaults to
 rundir/log/.
      """
      rundir = getattr(cfg, 'RUN_IN_DIR', '~/run')
 +    if rundir.startswith('~'):
 +        rundir = os.path.expanduser(rundir)
      os.chdir(rundir)
      beginLogging(cfg, rundir)
 }}}
 or similar, else python cries when you use os.chdir('~/run').

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


More information about the tor-bugs mailing list