[Python] Creating an Azure Function in vscode - no flolder is ever created with __init__.py

Discussão em 'Python' iniciado por Stack, Fevereiro 12, 2025.

  1. Stack

    Stack Membro Participativo

    I am trying to create an Azure Function (HTTP Trigger) using Python in VSCode. All the instructions say that the folder structure will be created automatically but it never is.

    So this is never created:

    function_app/
    ├── __init__.py
    ├── function.json
    └── other_files.py


    Any ideas? I am new to Python / VScode. If I create the folder and files manually and add breakpoints to init.py it doesn't trigger it. I think its an issue due to the way the project is configured at the start. All the AI / Youtube / documentation state that these folders and files are automatically created.

    These are the instructions I am following after ensuring everything is installed (Core Tools / python etc)

    Open the command palette (Ctrl+Shift+P or Cmd+Shift+P on macOS). Type Azure Functions: Create New Project... and select it. Choose a directory for your project. Select Python as the language. Select the version of the Azure Functions runtime you want to use. Choose HTTP trigger as the template for your function. Provide a name for your function. Choose the authorization level.

    Continue reading...

Compartilhe esta Página