def pbar(maxval): widgets = [progressbar.Percentage(), ' ', progressbar.Bar(), progressbar.ETA()] return progressbar.ProgressBar(widgets=widgets, maxval=maxval).start()