Skip to content

Instantly share code, notes, and snippets.

@ak1211
Created March 2, 2016 12:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ak1211/fd954c370b4765e675f2 to your computer and use it in GitHub Desktop.
Save ak1211/fd954c370b4765e675f2 to your computer and use it in GitHub Desktop.
日時フィールドが変だから,後ろの有効な値をとる
def toDateTime (log_datetime):
date = (log_datetime.split(' '))[3:]
return datetime.datetime.strptime (' '.join (date), "%b %d %H:%M:%S %Z")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment