Happy new year folks,
What is the recommended way to run a Python script within the AYON Python context, such that AYON automatically uses the Python scripts from the addon version defined by the current bundle?
I’m aware that this can normally be done with the following command:
%LOCALAPPDATA%/Ynput/AYON/shim/ayon_console.exe run [PATH TO PYTHON SCRIPT]
However, I’m not sure what the best approach is for providing the PATH TO PYTHON SCRIPT when the script lives inside an AYON addon and is managed by the addon system.
The directory %LOCALAPPDATA%/Ynput/AYON/addons contains all client-side addon code, but there doesn’t seem to be a way to programmatically select which addon (and version) should be used so that it matches the active bundle context.
Is there a supported way to provide a relative path, or otherwise resolve the script path, so that the correct addon version is used automatically?
Regards,
Tu