Datetime objects have a field named microsecond. So one way to achieve what you need is:
time.mktime(then.timetuple())*1e3 + then.microsecond/1e3
This returns milliseconds since UNIX epoch with the required precision.
Datetime objects have a field named microsecond. So one way to achieve what you need is:
time.mktime(then.timetuple())*1e3 + then.microsecond/1e3
This returns milliseconds since UNIX epoch with the required precision.