Skip to content

Commit

Permalink
updated datetime float parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
PydPiper committed Apr 11, 2021
1 parent ab8935d commit fbea609
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pylightxl/pylightxl.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ def readxl_scrape(fn, fn_ws, sharedString, styles):
cell_val = (EXCEL_STARTDATE + timedelta(seconds=partialday * 86400)).isoformat().split('T')[1]
elif styles[cell_style] in ['22']:
partialday = float(cell_val) % 1
cell_val = '/'.join((EXCEL_STARTDATE + timedelta(days=int(cell_val))).isoformat().split('T')[0].split('-')) + ' ' + \
cell_val = '/'.join((EXCEL_STARTDATE + timedelta(days=int(cell_val.split('.')[0]))).isoformat().split('T')[0].split('-')) + ' ' + \
(EXCEL_STARTDATE + timedelta(seconds=partialday * 86400)).isoformat().split('T')[1]
else:
cell_val = float(cell_val)
Expand Down

0 comments on commit fbea609

Please sign in to comment.