While it is for .NET/C# rather than Python, this post may give you some inspiration...
f
flat-umbrella-41594
10/26/2022, 3:07 PM
I have actually looked at this before and had trouble attaching to the process, in linux there wasn't a pulumi-automation executable to attach to, though there were many go processes