You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What steps will reproduce the problem?
1. Query a Case with a time field from BusinessHours (ie
BusinessHours.MondayStartTime)
2. Will fail during .query call
What is the expected output? What do you see instead?
The data marshalled into a datetime.time
Original issue reported on code.google.com by [email protected] on 11 Sep 2013 at 3:18
The text was updated successfully, but these errors were encountered:
It appears to be as easy as adding to following to marshall.py
timeregx = re.compile(r'(\d{2}):(\d{2}):(\d{2})(\.\d+)(.*)') # Line 12
# Line 115
def timeMarshaller(fieldname, xml, ns):
timestr = str(xml[getattr(ns,fieldname)])
match = timeregx.match(timestr)
if match:
grps = match.groups()
hour = int(grps[0])
minute = int(grps[1])
second = int(grps[2])
secfrac = float(grps[3])
microsecond = int(secfrac * (10**6))
tz = grps[4] # XXX not sure if I need to do anything with this. sofar
# times appear to be UTC
return datetime.time(hour, minute, second, microsecond)
return None
register('time', timeMarshaller)
Original issue reported on code.google.com by
[email protected]
on 11 Sep 2013 at 3:18The text was updated successfully, but these errors were encountered: