updated max number of attempts to stop from 10 to 100