Changed week to microsecond
This commit is contained in:
parent
400eef5371
commit
f2a4fab1cb
2 changed files with 4 additions and 4 deletions
6
memos.py
6
memos.py
|
@ -69,7 +69,7 @@ def txt2delta(txt):
|
||||||
return sign*timed
|
return sign*timed
|
||||||
|
|
||||||
def pcfGrammar(td):
|
def pcfGrammar(td):
|
||||||
if td == timedelta(weeks=1): # Replacement for mysteryTime </3
|
if td == timedelta(microseconds=1): # Replacement for mysteryTime </3
|
||||||
when = "???"
|
when = "???"
|
||||||
temporal = "???"
|
temporal = "???"
|
||||||
pcf = "?"
|
pcf = "?"
|
||||||
|
@ -102,7 +102,7 @@ class TimeTracker(list):
|
||||||
# mysteryTime breaks stuff now, so, uh
|
# mysteryTime breaks stuff now, so, uh
|
||||||
# I'm replacing it with 1 day...
|
# I'm replacing it with 1 day...
|
||||||
if type(time)==mysteryTime:
|
if type(time)==mysteryTime:
|
||||||
time = timedelta(weeks=1)
|
time = timedelta(microseconds=1)
|
||||||
self.timerecord = {"P": [], "F": []}
|
self.timerecord = {"P": [], "F": []}
|
||||||
self.open = {}
|
self.open = {}
|
||||||
if time is not None:
|
if time is not None:
|
||||||
|
@ -115,7 +115,7 @@ class TimeTracker(list):
|
||||||
def addTime(self, timed):
|
def addTime(self, timed):
|
||||||
# mysteryTime </3
|
# mysteryTime </3
|
||||||
if type(timed)==mysteryTime:
|
if type(timed)==mysteryTime:
|
||||||
timed = timedelta(weeks=1)
|
timed = timedelta(microseconds=1)
|
||||||
try:
|
try:
|
||||||
i = self.index(timed)
|
i = self.index(timed)
|
||||||
self.current = i
|
self.current = i
|
||||||
|
|
|
@ -917,7 +917,7 @@ def timeProtocol(cmd):
|
||||||
return timed
|
return timed
|
||||||
|
|
||||||
def timeDifference(td):
|
def timeDifference(td):
|
||||||
if td == timedelta(weeks=1): # mysteryTime replacement :(
|
if td == timedelta(microseconds=1): # mysteryTime replacement :(
|
||||||
return "??:?? FROM ????"
|
return "??:?? FROM ????"
|
||||||
if td < timedelta(0):
|
if td < timedelta(0):
|
||||||
when = "AGO"
|
when = "AGO"
|
||||||
|
|
Loading…
Reference in a new issue