How to sleep webdriver in python for milliseconds

前端 未结 3 1110
清酒与你
清酒与你 2020-11-22 04:36

I am using the time library in my script:

import time
time.sleep(1)

It can sleep my webdriver for 1 second but I need to sleep

3条回答
  •  囚心锁ツ
    2020-11-22 05:00

    If you want it to sleep in milliseconds then use float values:

    import time
    time.sleep(0.25)
    
    #0.25 > 250ms
    #0.1  > 100ms
    #0.05 > 50ms
    

提交回复
热议问题