/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions | Properties
DybPython::svndiff::Cmd Class Reference
Inheritance diagram for DybPython::svndiff::Cmd:
Inheritance graph
[legend]

List of all members.

Public Member Functions

def __init__
def pipecall
def filecall
def __call__

Properties

 cmd = property(lambda self:self._cmd % self )
 diff = property(lambda self:self(cmd="diff") )

Detailed Description

Definition at line 37 of file svndiff.py.


Constructor & Destructor Documentation

def DybPython::svndiff::Cmd::__init__ (   self,
  args,
  kwargs 
)

Reimplemented in DybPython::svndiff::SVN, and DybPython::svndiff::SVNLook.

Definition at line 40 of file svndiff.py.

00041                                        :
00042         dict.__init__(self, *args, **kwargs )


Member Function Documentation

def DybPython::svndiff::Cmd::pipecall (   self)

Definition at line 43 of file svndiff.py.

00044                       :
00045         p = os.popen( self.cmd )
00046         s = p.read()
00047         rc = p.close()
00048         assert rc == 0 or rc == None, "pipecall rc %s failed %s " % ( rc, self.cmd )
00049         return s

def DybPython::svndiff::Cmd::filecall (   self)
Run command and return output as string, useful for debugging

This was helpful in determining svnlook segmenting (the resulting /tmp/cmd.txt is same as prior /tmp/diff.txt)::

    running cmd /data/env/system/svn/subversion-1.4.0/bin/svnlook log /var/scm/repos/newtest  --transaction 15-1  
    sh: line 1: 20450 Segmentation fault      /data/env/system/svn/subversion-1.4.0/bin/svnlook diff /var/scm/repos/newtest --transaction 15-1 >/tmp/cmd.txt

suspect that a former backout merge was implicated in the segmentation fault ::

      svn merge -c -14 

as after ``svn rm tmp_offline_db`` and recreating with a new rdumpcat the segmentation 
fault goes away  

Definition at line 50 of file svndiff.py.

00051                       :
00052         """
00053         Run command and return output as string, useful for debugging
00054 
00055         This was helpful in determining svnlook segmenting (the resulting /tmp/cmd.txt is same as prior /tmp/diff.txt)::
00056 
00057             running cmd /data/env/system/svn/subversion-1.4.0/bin/svnlook log /var/scm/repos/newtest  --transaction 15-1  
00058             sh: line 1: 20450 Segmentation fault      /data/env/system/svn/subversion-1.4.0/bin/svnlook diff /var/scm/repos/newtest --transaction 15-1 >/tmp/cmd.txt
00059 
00060         suspect that a former backout merge was implicated in the segmentation fault ::
00061 
00062               svn merge -c -14 
00063 
00064         as after ``svn rm tmp_offline_db`` and recreating with a new rdumpcat the segmentation 
00065         fault goes away  
00066         """
00067         out = tempfile.NamedTemporaryFile()
00068         tmp = "/tmp/dbsvn-%s.txt" % os.getpid()
00069         rc = os.system( "%s > %s " % (self.cmd, tmp) ) 
00070         assert rc == 0, "filecall rc %s failed %s while writing %s " % ( rc, self.cmd, tmp )
00071         s = open(tmp).read()
00072         if os.path.exists(tmp):
00073             os.remove(tmp)
00074         return s

def DybPython::svndiff::Cmd::__call__ (   self,
  args,
  kwargs 
)

Definition at line 75 of file svndiff.py.

00076                                        :
00077         self.update( kwargs )
00078         return self.pipecall()


Property Documentation

DybPython::svndiff::Cmd::cmd = property(lambda self:self._cmd % self ) [static]

Reimplemented in DybPython::svndiff::SVN, and DybPython::svndiff::SVNLook.

Definition at line 38 of file svndiff.py.

DybPython::svndiff::Cmd::diff = property(lambda self:self(cmd="diff") ) [static]

Definition at line 39 of file svndiff.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:55:41 for DybPython by doxygen 1.7.4