date_to_unix

date_to_unix

sorts.dates.date_to_unix(year, month, day, hour, minute, second)[source]

Convert date to unix time in seconds

Parameters
  • year (int) – Year as integer. Years preceding 1 A.D. should be 0 or negative. The year before 1 A.D. is 0, 10 B.C. is year -9.

  • month (int) – Month as integer, Jan = 1, Feb. = 2, etc.

  • day (int) – Day

  • hour (int) – Hour in 24h format

  • minute (int) – Minute

  • second (float) – Second, may contain fractional part.

Returns

Unix time in seconds

Return type

float