Collection of unofficial idempotent DataRobot helpers. Ready for use in your orchestration tool of choice.
git clone https://github.com/datarobot-community/datarobotx-idp
cd datarobotx-idp
pip install -e .
import os
from datarobotx.idp.execution_environments import get_or_create_execution_environment
dr_endpoint = os.environ['DATAROBOT_ENDPOINT']
dr_token = os.environ['DATAROBOT_API_TOKEN']
env_id_1 = get_or_create_execution_environment(dr_endpoint, dr_token, "image #1")
env_id_2 = get_or_create_execution_environment(dr_endpoint, dr_token, "image #1")
assert env_id_1 == env_id_2
env_id_3 = get_or_create_execution_environment(dr_endpoint, dr_token, "image #2")
assert env_id_1 != env_id_3
- Public functions must be idempotent
- Function signatures must be type hinted (enforced by mypy)
- Functions must have numpydoc-style docstrings (enforced by ruff)
- Functions must either have a unit or integration test
- Group code so it can be easily grokked and edited at the .py level
- Minimize dependencies
- Isolate dependencies by submodule to reduce risk of dependency conflicts