File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -140,13 +140,19 @@ async def run(self, openspace):
140140
141141 case "screenshot" :
142142 print (" Take Screenshot" )
143+ # We'll wait an extra 5 seconds before taking a screenshot just to be sure that
144+ # everything is finished
145+ time .sleep (5 )
146+
147+ # Take the screenshot
143148 await openspace .takeScreenshot ()
149+
144150 # Give the screenshot writing some time to finish. It will be a maximum of two
145151 # frames to write a screenshot + whatever time it takes to write the actual
146152 # screenshot. The writing should be on the order of 100 ms + about 35 ms for two
147- # frames get us to 135 ms. Lets be on the safe side with a 15x margin and go for
148- # a wait of 2 seconds
149- time .sleep (2 )
153+ # frames get us to 135 ms. Lets be on the safe side with a 35x margin and go for
154+ # a wait of 5 seconds
155+ time .sleep (5 )
150156
151157 case "script" :
152158 print (f" Script: { self .value } " )
Original file line number Diff line number Diff line change @@ -99,8 +99,8 @@ def __init__(self, path: str):
9999 async def run (self , openspace ):
100100 """
101101 Runs the actual instructions on the provided OpenSpace API instance. There is a
102- mandatory 250ms wait time between every instructions
102+ mandatory 1s wait time between every instructions
103103 """
104104 for instruction in self .instructions :
105105 await instruction .run (openspace )
106- time .sleep (0.25 )
106+ time .sleep (1 )
You can’t perform that action at this time.
0 commit comments