Fix Python 3 TypeError in lock recipe.