예제 #1
0
 def adapt_string(adapted):
     """Python implementation of psycopg/psycopg2#459 from v2.7"""
     if '\x00' in adapted:
         raise ValueError(
             "A string literal cannot contain NUL (0x00) characters.")
     return QuotedString(adapted)
예제 #2
0
 def getquoted(self):
     s = self.dumps(self.adapted)
     qs = QuotedString(s)
     if self._conn is not None:
         qs.prepare(self._conn)
     return qs.getquoted()
예제 #3
0
 def getquoted(self):
     s = self.dumps(self.adapted)
     return QuotedString(s).getquoted()
예제 #4
0
파일: _json.py 프로젝트: Superman8218/envs
 def getquoted(self):
     pudb.set_trace()
     s = self.dumps(self.adapted)
     return QuotedString(s).getquoted()