Fix typo across codebase (change "tupple" to "tuple")
This commit is contained in:
parent
8df8486def
commit
167cf02afd
|
@ -187,7 +187,7 @@ class Logger:
|
||||||
def get_jids_already_in_db(self):
|
def get_jids_already_in_db(self):
|
||||||
try:
|
try:
|
||||||
self.cur.execute('SELECT jid FROM jids')
|
self.cur.execute('SELECT jid FROM jids')
|
||||||
# list of tupples: [('aaa@bbb',), ('cc@dd',)]
|
# list of tuples: [('aaa@bbb',), ('cc@dd',)]
|
||||||
rows = self.cur.fetchall()
|
rows = self.cur.fetchall()
|
||||||
except sqlite.DatabaseError:
|
except sqlite.DatabaseError:
|
||||||
raise exceptions.DatabaseMalformed
|
raise exceptions.DatabaseMalformed
|
||||||
|
@ -588,8 +588,8 @@ class Logger:
|
||||||
"""
|
"""
|
||||||
Accept how many rows to restore and when to time them out (in minutes)
|
Accept how many rows to restore and when to time them out (in minutes)
|
||||||
(mark them as too old) and number of messages that are in queue and are
|
(mark them as too old) and number of messages that are in queue and are
|
||||||
already logged but pending to be viewed, returns a list of tupples
|
already logged but pending to be viewed, returns a list of tuples
|
||||||
containg time, kind, message, sibject list with empty tupple if nothing
|
containg time, kind, message, subject list with empty tuple if nothing
|
||||||
found to meet our demands
|
found to meet our demands
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
|
@ -630,7 +630,7 @@ class Logger:
|
||||||
# returns time in seconds for the second that starts that date since epoch
|
# returns time in seconds for the second that starts that date since epoch
|
||||||
# gimme unixtime from year month day:
|
# gimme unixtime from year month day:
|
||||||
d = datetime.date(year, month, day)
|
d = datetime.date(year, month, day)
|
||||||
local_time = d.timetuple() # time tupple (compat with time.localtime())
|
local_time = d.timetuple() # time tuple (compat with time.localtime())
|
||||||
# we have time since epoch baby :)
|
# we have time since epoch baby :)
|
||||||
start_of_day = int(time.mktime(local_time))
|
start_of_day = int(time.mktime(local_time))
|
||||||
return start_of_day
|
return start_of_day
|
||||||
|
@ -639,7 +639,7 @@ class Logger:
|
||||||
"""
|
"""
|
||||||
Return contact_name, time, kind, show, message, subject, additional_data, log_line_id
|
Return contact_name, time, kind, show, message, subject, additional_data, log_line_id
|
||||||
|
|
||||||
For each row in a list of tupples, returns list with empty tupple if we
|
For each row in a list of tuples, returns list with empty tuple if we
|
||||||
found nothing to meet our demands
|
found nothing to meet our demands
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
|
@ -676,7 +676,7 @@ class Logger:
|
||||||
"""
|
"""
|
||||||
Returns contact_name, time, kind, show, message, subject, log_line_id
|
Returns contact_name, time, kind, show, message, subject, log_line_id
|
||||||
|
|
||||||
For each row in a list of tupples, returns list with empty tupple if we
|
For each row in a list of tuples, returns list with empty tuple if we
|
||||||
found nothing to meet our demands
|
found nothing to meet our demands
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -253,7 +253,7 @@ class HistoryManager:
|
||||||
# get those jids that have at least one entry in logs
|
# get those jids that have at least one entry in logs
|
||||||
self.cur.execute('SELECT jid, jid_id FROM jids WHERE jid_id IN ('
|
self.cur.execute('SELECT jid, jid_id FROM jids WHERE jid_id IN ('
|
||||||
'SELECT distinct logs.jid_id FROM logs) ORDER BY jid')
|
'SELECT distinct logs.jid_id FROM logs) ORDER BY jid')
|
||||||
# list of tupples: [('aaa@bbb',), ('cc@dd',)]
|
# list of tuples: [('aaa@bbb',), ('cc@dd',)]
|
||||||
rows = self.cur.fetchall()
|
rows = self.cur.fetchall()
|
||||||
for row in rows:
|
for row in rows:
|
||||||
self.jids_already_in.append(row[0]) # jid
|
self.jids_already_in.append(row[0]) # jid
|
||||||
|
|
|
@ -578,7 +578,7 @@ class HistoryWindow:
|
||||||
cur_year, cur_month, cur_day = self.calendar.get_date()
|
cur_year, cur_month, cur_day = self.calendar.get_date()
|
||||||
cur_month = gtkgui_helpers.make_gtk_month_python_month(cur_month)
|
cur_month = gtkgui_helpers.make_gtk_month_python_month(cur_month)
|
||||||
model = widget.get_model()
|
model = widget.get_model()
|
||||||
# make it a tupple (Y, M, D, 0, 0, 0...)
|
# make it a tuple (Y, M, D, 0, 0, 0...)
|
||||||
tim = time.strptime(model[path][Column.UNIXTIME], '%Y-%m-%d')
|
tim = time.strptime(model[path][Column.UNIXTIME], '%Y-%m-%d')
|
||||||
year = tim[0]
|
year = tim[0]
|
||||||
gtk_month = tim[1]
|
gtk_month = tim[1]
|
||||||
|
|
|
@ -157,7 +157,7 @@ class MessageControl(object):
|
||||||
|
|
||||||
Derivded classes MUST implement this.
|
Derivded classes MUST implement this.
|
||||||
"""
|
"""
|
||||||
# Return a markup'd label and optional Gtk.Color in a tupple like:
|
# Return a markup'd label and optional Gtk.Color in a tuple like:
|
||||||
# return (label_str, None)
|
# return (label_str, None)
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
|
@ -5793,7 +5793,7 @@ class RosterWindow:
|
||||||
self._iters = {}
|
self._iters = {}
|
||||||
# for merged mode
|
# for merged mode
|
||||||
self._iters['MERGED'] = {'account': None, 'groups': {}}
|
self._iters['MERGED'] = {'account': None, 'groups': {}}
|
||||||
# holds a list of (jid, account) tupples
|
# holds a list of (jid, account) tuples
|
||||||
self._last_selected_contact = []
|
self._last_selected_contact = []
|
||||||
self.transports_state_images = {'16': {}, '32': {}, 'opened': {},
|
self.transports_state_images = {'16': {}, '32': {}, 'opened': {},
|
||||||
'closed': {}}
|
'closed': {}}
|
||||||
|
|
Loading…
Reference in New Issue