From 039c923f72aa11ab943ae6812c13ec777edca27a Mon Sep 17 00:00:00 2001 From: jtl-novatec <151550827+jtl-novatec@users.noreply.github.com> Date: Wed, 17 Apr 2024 13:12:58 +0200 Subject: [PATCH] Update index.md --- .../content/labs/instrumentation/manual/metrics/index.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tutorial/content/labs/instrumentation/manual/metrics/index.md b/tutorial/content/labs/instrumentation/manual/metrics/index.md index bdd1060..f7c01a2 100644 --- a/tutorial/content/labs/instrumentation/manual/metrics/index.md +++ b/tutorial/content/labs/instrumentation/manual/metrics/index.md @@ -149,14 +149,11 @@ from metric_utils import create_meter # global variables app = Flask(__name__) - -if __name__ == "__main__": - # setup metrics - meter = create_meter("app.py", "0.1") +meter = create_meter("app.py", "0.1") ``` Finally, open `app.py` and import `create_meter`. -Invoke the function inside the file's main section and assign the return value to a global variable `meter`. +Invoke the function and assign the return value to a global variable `meter`. ### create instruments to record measurements