Fixed missing import (had worked in IDLE).