[pkg-fso-commits] [SCM] FSO frameworkd Debian packaging branch, debian, updated. upstream/0.9.5.5-717-g0f98819

Sebastian Krzyszkowiak seba.dos1 at gmail.com
Sat Aug 6 08:18:12 UTC 2011


The following commit has been merged in the debian branch:
commit f17ff26d072a80821bd7eaae859659fd0fa982d4
Author: Sebastian Krzyszkowiak <seba.dos1 at gmail.com>
Date:   Thu Aug 27 21:42:19 2009 +0200

    opimd: cast Timestamp to float when loading from database

diff --git a/framework/subsystems/opimd/pimb_sqlite_messages.py b/framework/subsystems/opimd/pimb_sqlite_messages.py
index 453c0ba..95525ac 100644
--- a/framework/subsystems/opimd/pimb_sqlite_messages.py
+++ b/framework/subsystems/opimd/pimb_sqlite_messages.py
@@ -172,6 +172,8 @@ class SQLiteMessagesBackend(Backend):
                 logger.error("%s: Could not read from database (table message_values)! Possible reason is old, uncompatible table structure. If you don't have important data, please remove %s file.", self.name, _SQLITE_FILE_NAME)
                 raise OperationalError
 
+            if entry.get('Timestamp'):
+                entry['Timestamp']=float(entry['Timestamp'])
             entry_id = self._domain_handlers['Messages'].register_message(self, entry)
             self._entry_ids.append(entry_id)
         cur.close()
diff --git a/framework/subsystems/opimd/pimb_sqlite_notes.py b/framework/subsystems/opimd/pimb_sqlite_notes.py
index 973da31..303dbb9 100644
--- a/framework/subsystems/opimd/pimb_sqlite_notes.py
+++ b/framework/subsystems/opimd/pimb_sqlite_notes.py
@@ -137,6 +137,8 @@ class SQLiteNotesBackend(Backend):
                 logger.error("%s: Could not read from database (table note_values)! Possible reason is old, uncompatible table structure. If you don't have important data, please remove %s file.", self.name, _SQLITE_FILE_NAME)
                 raise OperationalError
 
+            if entry.get('Timestamp'):
+                entry['Timestamp']=float(entry['Timestamp'])
             entry_id = self._domain_handlers['Notes'].register_entry(self, entry)
             self._entry_ids.append(entry_id)
         cur.close()
diff --git a/framework/subsystems/opimd/pimb_sqlite_tasks.py b/framework/subsystems/opimd/pimb_sqlite_tasks.py
index 928e927..84d8629 100644
--- a/framework/subsystems/opimd/pimb_sqlite_tasks.py
+++ b/framework/subsystems/opimd/pimb_sqlite_tasks.py
@@ -139,6 +139,8 @@ class SQLiteTasksBackend(Backend):
                 logger.error("%s: Could not read from database (table task_values)! Possible reason is old, uncompatible table structure. If you don't have important data, please remove %s file.", self.name, _SQLITE_FILE_NAME)
                 raise OperationalError
 
+            if entry.get('Timestamp'):
+                entry['Timestamp']=float(entry['Timestamp'])
             entry_id = self._domain_handlers['Tasks'].register_entry(self, entry)
             self._entry_ids.append(entry_id)
         cur.close()

-- 
FSO frameworkd Debian packaging



More information about the pkg-fso-commits mailing list