Azure / Azure/azure-functions-host

Default script file behavior

Open
#3,073 1 comment 0 reactions 1 assignee Claimed by @maiqbal11 View on GitHub
stack: python
Dominant language
C#
Stars
2k
Forks
482
Avg merge
2d 12h
Merged PRs (30d)
38

Description

_From @asavaritayal on June 28, 2018 18:42_

If `scriptFile` tag is not provided in `function.json`, the runtime is unable to index the Python functions.

**Observed Behvaior**

If `"scriptFile": "{filename}.py"` is present in `function.json` , the worker uses `{filename}.py` as the script file.

Elif `run.py` is present, the worker defaults to it as the script file.

Else 404 : No job functions are found

**Expected Behavior**

If `"scriptFile": "{filename}.py"` is present in `function.json`, the worker should use `{filename}.py` as the script file.

Elif `__init__.py` is present, the worker defaults to it as the script file.

Elif a single `.py` module is present, use it as the script file. [Nice to have]

Else throw 404 : No job functions are found

_Copied from original issue: Azure/azure-functions-python-worker#159_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.