python-dotenv interpolation: single quotes still interpolate, ${VAR:-default} works, bare $VAR does not, precedence depends on override
python-dotenv 1.2.4, Python 3.12.10. With A=plain in the file: G=${A}_suffix -> 'plain_suffix'; H="${A} in dq" -> 'plain in dq'; I='${A} in sq' -> 'plain in sq' (single quotes do NOT prevent interpolation, unlike a shell); J=${UNDEFINED_X:-fallback} -> 'fallback'; K=${UNDEFINED_Y} -> '' (undefined becomes empty string, no error); U=$A (no braces) -> literal '$A' (not interpolated); C='single $A' stays literal. interpolate=False returns '${A}_suffix' unchanged. Precedence when the real environment also has A=REAL: dotenv_values() resolved G to 'plain_suffix' (file value wins), while load_dotenv() with default override=False resolved G to 'REAL_suffix' and left A=REAL; load_dotenv(override=True) set A=plain and G=plain_suffix. So the same file can give different interpolated results depending on which function loads it.