From 6ba838a304d0e27fcc89f95cede133af207d9e9e Mon Sep 17 00:00:00 2001 From: depetrol Date: Wed, 9 Oct 2024 18:04:38 -0700 Subject: [PATCH] update docs --- examples/Python/src/WebServer/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/Python/src/WebServer/README.md b/examples/Python/src/WebServer/README.md index f4e1fc43..465f7c53 100644 --- a/examples/Python/src/WebServer/README.md +++ b/examples/Python/src/WebServer/README.md @@ -43,6 +43,8 @@ async def addone(request: Request): return {"status": "success", "num": num} ``` +`self` here refers to the `WebServer` reactor in which the handler is defined. The `self.app` is an instance of `FastAPI` application instance, defined as a state of the `WebServer` reactor. Import statements are in the `preamble` and not shown here for simplicity. This handler function will be triggered to generate a response to an HTTP `POST` request at the `/addone` endpoint. + And the reaction to the action is ```python