harbor run -t openthoughts/tasktrove-exp-flat25-speed-bonus-v2-5k-speed-3259harbor download openthoughts/tasktrove-exp-flat25-speed-bonus-v2-5k-speed-3259Task: Implement the cookiecutter.prompt module to render and collect configuration data according to the provided tests.
What to implement (functionality and behavior)
render_variable(env, raw_var, context)
prompt_for_config(context, no_input=False)
prompt_choice_for_config(cookiecutter_dict, env, key, options, no_input)
read_user_variable(var, default)
read_user_choice(var, options)
read_user_dict(var, default)
Contextual requirements the implementation must satisfy (mapped to tests)
render_variable must produce:
prompt_for_config must:
prompt_choice_for_config must:
Undefined variable handling: Rendering a template that references an undefined variable should raise exceptions.UndefinedVariableInTemplate with message "Unable to render variable 'foo'" and context equal to the provided context.
Self-contained deliverable
Notes
BONUS: Complete this task as quickly as possible. Faster solutions are preferred.