diff options
author | Will Woods <wwoods@redhat.com> | 2009-09-14 16:40:56 -0400 |
---|---|---|
committer | Will Woods <wwoods@redhat.com> | 2009-09-14 16:40:56 -0400 |
commit | eaea9a91254ea3b950bdee53c938eeaa8a47c695 (patch) | |
tree | cdbbdf5c20bcf60cce2bd2cba8917b7be5b88426 | |
parent | 56912ffb491c05402ac78f7fe665ad427c668a29 (diff) | |
download | israwhidebroken-eaea9a91254ea3b950bdee53c938eeaa8a47c695.tar.gz israwhidebroken-eaea9a91254ea3b950bdee53c938eeaa8a47c695.tar.xz israwhidebroken-eaea9a91254ea3b950bdee53c938eeaa8a47c695.zip |
Avoid some ambiguity - Tree.{tree,repodata}_time are IntCol
-rw-r--r-- | israwhidebroken/model.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/israwhidebroken/model.py b/israwhidebroken/model.py index 6e8bcbd..ed75005 100644 --- a/israwhidebroken/model.py +++ b/israwhidebroken/model.py @@ -17,9 +17,12 @@ __connection__ = hub = PackageHub('israwhidebroken') class Tree(SQLObject): arch = StringCol(length=10, notNone=True) - # These could be null if repodata/images are missing - tree_time = DateTimeCol() - repodata_time = DateTimeCol() + # These could be null if repodata/images are missing. + # They're IntCol because I don't want to deal with converting + # between the representation in the file(s) and weirdo datetime + # or timestamp columns. + tree_time = IntCol() + repodata_time = IntCol() # A tree can have many results you might want to look at results = MultipleJoin('TestResult') @@ -43,4 +46,4 @@ class TestResult(SQLObject): # XXX list of bug IDs? bug_id = IntCol() # timestamp this result was entered - timestamp = DateTimeCol(notNone=True) + timestamp = DateTimeCol(notNone=True, default=datetime.now) |