Hello, Is it possible to launch Orion within pytho...
# prefect-community
i
Hello, Is it possible to launch Orion within python?
1
k
You can use
os.system
to run the command
prefect agent start
. I wonder why you’d like to launch Orion within Python?
z
Minor note, you’d want to run
prefect orion start
— I am also curious why you want to launch it in Python though.
j
To throw it out there the
prefect
command itself is written in Python … so theoretically yes, but your use case would likely help determine what might be the best approach (solution) to your particular needs.
👍 1
@Andrew Brookins put this repository together for me, and it might be useful to peruse in your investigation. It runs all the
prefect
CLI commands through a Django Management Command. Here’s the specific Management Command: https://github.com/abrookins/django-prefect-example/blob/main/workflows/management/commands/prefectcli.py
i
thank you for all of your answers, I was a bit stuck in the environment in my job. I wasn't able to install prefect in a virtual environment or even in the python itself. thank you very much.