File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818def iot_hub_trigger (event : func .EventHubEvent ):
1919
2020 try :
21- # ---- MOVE ALL BLOB CODE INSIDE FUNCTION ----
21+ message = event .get_body ().decode ('utf-8' )
22+
23+ # ✅ THIS LINE PROVES GITHUB DEPLOY IS RUNNING
24+ logging .info ("===== THIS CODE IS RUNNING FROM GITHUB ACTIONS DEPLOY =====" )
25+
26+ logging .info (f"Received message: { message } " )
27+
28+ # ---- Blob setup INSIDE function (important) ----
2229 BLOB_CONNECTION_STRING = os .getenv ('AzureWebJobsStorage' )
2330 CONTAINER_NAME = "iot-data"
2431
@@ -31,10 +38,7 @@ def iot_hub_trigger(event: func.EventHubEvent):
3138 container_client .create_container ()
3239 except ResourceExistsError :
3340 pass
34- # --------------------------------------------
35-
36- message = event .get_body ().decode ('utf-8' )
37- logging .info (f"Received message: { message } " )
41+ # ------------------------------------------------
3842
3943 try :
4044 data = json .loads (message )
You can’t perform that action at this time.
0 commit comments