I don't think TSV files are in UTC after all
This commit is contained in:
@ -65,11 +65,9 @@ def process_audioscrobbler_tsv_file(file_path, user_id, user_tz=None):
|
|||||||
)
|
)
|
||||||
continue
|
continue
|
||||||
|
|
||||||
timestamp = (
|
timestamp = datetime.utcfromtimestamp(
|
||||||
datetime.utcfromtimestamp(int(row[AsTsvColumn["TIMESTAMP"].value]))
|
int(row[AsTsvColumn["TIMESTAMP"].value])
|
||||||
.replace(tzinfo=user_tz)
|
).replace(tzinfo=user_tz)
|
||||||
.astimezone(pytz.utc)
|
|
||||||
)
|
|
||||||
|
|
||||||
new_scrobble = Scrobble(
|
new_scrobble = Scrobble(
|
||||||
user_id=user_id,
|
user_id=user_id,
|
||||||
|
|||||||
Reference in New Issue
Block a user