MCPcopy Index your code
hub / github.com/python/cpython / tick

Function tick

Lib/turtledemo/clock.py:104–119  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

102 return "%s %d %d" % (m, t, j)
103
104def tick():
105 t = datetime.today()
106 sekunde = t.second + t.microsecond*0.000001
107 minute = t.minute + sekunde/60.0
108 stunde = t.hour + minute/60.0
109 try:
110 tracer(False) # Terminator can occur here
111 second_hand.setheading(6*sekunde) # or here
112 minute_hand.setheading(6*minute)
113 hour_hand.setheading(30*stunde)
114 if t.day != current_day:
115 display_date_time()
116 tracer(True)
117 ontimer(tick, 100)
118 except Terminator:
119 pass # turtledemo user pressed STOP
120
121def main():
122 tracer(False)

Callers 1

mainFunction · 0.85

Calls 4

tracerFunction · 0.85
display_date_timeFunction · 0.85
todayMethod · 0.80
setheadingMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…