Open
Description
Investigative information
func --version
4.0.5530
Repro steps
Provide the steps required to reproduce the problem:
- Create a new Azure function
func new --template "Timer Trigger" --name another_trigger
- Change the generated code from
@app.timer_trigger(schedule="0 */5 * * * *", arg_name="myTimer", run_on_startup=True,
use_monitor=False)
def another_trigger(myTimer: func.TimerRequest) -> None:
to
@app.timer_trigger(schedule="0 */5 * * * *", arg_name="my_timer", run_on_startup=True,
use_monitor=False)
def another_trigger(my_timer: func.TimerRequest) -> None:
- Run the function, which results in an error of the form:
The 'another_trigger' function is in error: The binding name my_timer is invalid. Please assign a valid name to the binding.
Expected behaviour
It should be possible to use a binding name that uses snake case, since this is the normal convention for Python programs.
Actual behaviour
The 'another_trigger' function is in error: The binding name my_timer is invalid. Please assign a valid name to the binding.
Known workarounds
Remove the _
character from the binding and variable name.
Contents of the requirements.txt file:
azure-functions==1.18.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment