From 1f3126737a5903f7c84b2a7805f312988f090ecd Mon Sep 17 00:00:00 2001
From: Dario Barghini <dario.barghini@inaf.it>
Date: Thu, 29 May 2025 22:48:53 +0200
Subject: [PATCH] Reverted last commit. Probably it makes more sense to use
 local datetime

---
 pysqm/read.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/pysqm/read.py b/pysqm/read.py
index 3e3afec..fbcdc0e 100644
--- a/pysqm/read.py
+++ b/pysqm/read.py
@@ -181,7 +181,8 @@ class device(observatory):
 
     def define_filenames(self):
         # Filenames should follow a standard based on observatory name and date.
-        date_time_file = self.read_datetime()-datetime.timedelta(hours=12)
+        date_time_file = self.local_datetime(\
+         self.read_datetime())-datetime.timedelta(hours=12)
         date_file = date_time_file.date()
         yearmonth = str(date_file)[0:7].replace('-','')
         yearmonthday = str(date_file)[0:10].replace('-','')
-- 
GitLab