diff --git a/.changes/unreleased/Under the Hood-20251105-165014.yaml b/.changes/unreleased/Under the Hood-20251105-165014.yaml new file mode 100644 index 00000000000..cf8c7dc2146 --- /dev/null +++ b/.changes/unreleased/Under the Hood-20251105-165014.yaml @@ -0,0 +1,6 @@ +kind: Under the Hood +body: Support DBT_ENGINE prefix for record-mode env vars +time: 2025-11-05T16:50:14.992799-05:00 +custom: + Author: michelleark + Issue: "12149" diff --git a/core/dbt/cli/requires.py b/core/dbt/cli/requires.py index 6b722c46773..8a7e27f81b2 100644 --- a/core/dbt/cli/requires.py +++ b/core/dbt/cli/requires.py @@ -136,12 +136,16 @@ def setup_record_replay(): recorder: Optional[Recorder] = None if rec_mode == RecorderMode.REPLAY: - previous_recording_path = os.environ.get("DBT_RECORDER_FILE_PATH") + previous_recording_path = os.environ.get( + "DBT_ENGINE_RECORDER_FILE_PATH" + ) or os.environ.get("DBT_RECORDER_FILE_PATH") recorder = Recorder( RecorderMode.REPLAY, types=rec_types, previous_recording_path=previous_recording_path ) elif rec_mode == RecorderMode.DIFF: - previous_recording_path = os.environ.get("DBT_RECORDER_FILE_PATH") + previous_recording_path = os.environ.get( + "DBT_ENGINE_RECORDER_FILE_PATH" + ) or os.environ.get("DBT_RECORDER_FILE_PATH") # ensure types match the previous recording types = get_record_types_from_dict(previous_recording_path) recorder = Recorder(