some fixes and add progress bar