I think you don't need `locals()` here.