Subprocess on Webhook is doubling commands

Hey Shotgrid-Webhook-Team,

I have recently started to use some Webhooks for our pipeline in order to cache out animation from Maya, sending them to Houdini and to deadline. Everything is working in terms of execution and flow of the code, however when I start a subprocess.Popen/run/call with the standalone mayapy.exe and run the code “import maya.standalone maya.standalone.initialize(“python”)” it starts another instance of the webhook executing the same code from the sg_webhook_server.py.
this may sound confusing so let me break it down a bit more here:
sg_webhook_server.py =>starts a subprocess.run with “C:/Program Files/Autodesk/Maya2023/bin/mayapy.exe” and “pipelinepath/Webhook/2023-11-07/sg_webhook_maya.py”

sg_webhook_maya.py => here is a bunch of custom code, but when this line “maya.standalone.initialize(“python”)” is being executed, another process of the webhooks starts and all of the debugging prints will be printed a second time and all my publishes will happen twice on shotgrid ?
Is there any way to avoid this behaviour ?

Kind regards
Pirmin