replace py-app with py-method to simplify the desugaring
simplify with statement
run profile change