[Python-checkins] python/dist/src/Lib/bsddb dbrecio.py, 1.2, 1.3 dbtables.py, 1.9, 1.10

doerwalter at users.sourceforge.net doerwalter at users.sourceforge.net
Thu Feb 12 12:35:40 EST 2004


Update of /cvsroot/python/python/dist/src/Lib/bsddb
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21620/Lib/bsddb

Modified Files:
	dbrecio.py dbtables.py 
Log Message:
Replace backticks with repr() or "%r"

>From SF patch #852334.


Index: dbrecio.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/bsddb/dbrecio.py,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** dbrecio.py	30 Dec 2002 20:52:07 -0000	1.2
--- dbrecio.py	12 Feb 2004 17:35:08 -0000	1.3
***************
*** 165,172 ****
      f.write(lines[1])
      f.seek(0)
!     print 'First line =', `f.readline()`
      here = f.tell()
      line = f.readline()
!     print 'Second line =', `line`
      f.seek(-len(line), 1)
      line2 = f.read(len(line))
--- 165,172 ----
      f.write(lines[1])
      f.seek(0)
!     print 'First line =', repr(f.readline())
      here = f.tell()
      line = f.readline()
!     print 'Second line =', repr(line)
      f.seek(-len(line), 1)
      line2 = f.read(len(line))

Index: dbtables.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/bsddb/dbtables.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** dbtables.py	21 Sep 2003 00:08:14 -0000	1.9
--- dbtables.py	12 Feb 2004 17:35:08 -0000	1.10
***************
*** 207,211 ****
              key, data = cur.first()
              while 1:
!                 print `{key: data}`
                  next = cur.next()
                  if next:
--- 207,211 ----
              key, data = cur.first()
              while 1:
!                 print repr({key: data})
                  next = cur.next()
                  if next:
***************
*** 342,348 ****
              tcolpickles = self.db.get(_columns_key(table))
          except DBNotFoundError:
!             raise TableDBError, "unknown table: " + `table`
          if not tcolpickles:
!             raise TableDBError, "unknown table: " + `table`
          self.__tablecolumns[table] = pickle.loads(tcolpickles)
  
--- 342,348 ----
              tcolpickles = self.db.get(_columns_key(table))
          except DBNotFoundError:
!             raise TableDBError, "unknown table: %r" % (table,)
          if not tcolpickles:
!             raise TableDBError, "unknown table: %r" % (table,)
          self.__tablecolumns[table] = pickle.loads(tcolpickles)
  
***************
*** 385,389 ****
              for column in rowdict.keys() :
                  if not self.__tablecolumns[table].count(column):
!                     raise TableDBError, "unknown column: "+`column`
  
              # get a unique row identifier for this row
--- 385,389 ----
              for column in rowdict.keys() :
                  if not self.__tablecolumns[table].count(column):
!                     raise TableDBError, "unknown column: %r" % (column,)
  
              # get a unique row identifier for this row
***************
*** 536,540 ****
          for column in (columns + conditions.keys()):
              if not self.__tablecolumns[table].count(column):
!                 raise TableDBError, "unknown column: "+`column`
  
          # keyed on rows that match so far, containings dicts keyed on
--- 536,540 ----
          for column in (columns + conditions.keys()):
              if not self.__tablecolumns[table].count(column):
!                 raise TableDBError, "unknown column: %r" % (column,)
  
          # keyed on rows that match so far, containings dicts keyed on




More information about the Python-checkins mailing list