Make a code change

While the app is still running, open the file sam-app/hello_world/app.py and make a simple code change. For example, change the response message to return hello my friend instead of hello world. Your Lambda handler should look like this after the change:

MakeCodeChange

Note: Make sure you save the file after changing it.

You don’t have to restart the sam local process, just refresh the browser tab or re-trigger the curl command to see the changes reflected in your endpoint. SamLocalCodeChange

You only need to restart sam local if you change the template.yaml.