complete function run