Skip to content

Commit

Permalink
utc fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
axelstudios committed Jan 17, 2025
1 parent 53983b6 commit 129c146
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions seed/data_importer/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
from bisect import bisect_left
from collections import defaultdict, namedtuple
from datetime import date, datetime
from datetime import timezone as tz
from itertools import chain
from math import ceil
from typing import Optional, Union
Expand All @@ -31,7 +32,7 @@
from django.db import DataError, IntegrityError, connection, transaction
from django.db.models import Q
from django.db.utils import ProgrammingError
from django.utils import timezone as tz
from django.utils import timezone as django_tz
from django.utils.timezone import make_naive

from seed.building_sync import validation_client
Expand Down Expand Up @@ -199,7 +200,7 @@ def finish_mapping(import_file_id, mark_as_done, progress_key):
value = True
setattr(import_record, f"{action}_{state}", value)

import_record.finish_time = tz.now()
import_record.finish_time = django_tz.now()
import_record.status = STATUS_READY_TO_MERGE
import_record.save()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
import logging
import os.path as osp
import pathlib
from datetime import timezone as tz

import pytz
from django.core.files.uploadedfile import SimpleUploadedFile
from django.utils import timezone as tz
from quantityfield.units import ureg

from seed.data_importer import match, tasks
Expand Down
2 changes: 1 addition & 1 deletion seed/tests/test_meter_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
import copy
import json
from datetime import datetime
from datetime import timezone as tz

from django.urls import reverse
from django.utils import timezone as tz

from seed.data_importer.utils import kbtu_thermal_conversion_factors, kgal_water_conversion_factors
from seed.landing.models import SEEDUser as User
Expand Down

0 comments on commit 129c146

Please sign in to comment.