Skip to content

func pack --build-native-deps fails for Python 3.13+ when running on Windows #4740

@hallvictoria

Description

@hallvictoria

Version

4.4.0+

Description

Running func pack --build-native-deps for Python 3.13+ on a Windows machine throws an error saying that:

The directory name is invalid. : 'C:\Users\victoriahall\AppData\Local\Temp\azure-functions\python:4-python3.13-buildenv-docker'

I also tested with CT version 4.5.0 and got the same error. This only seems to happen with Windows - Mac seems to work as expected.

Full output:

(.venv313) PS C:\Users\victoriahall\Documents\repos\sdk-servicebus> func pack --build-native-deps
'local.settings.json' found in root directory (C:\Users\victoriahall\Documents\repos\sdk-servicebus).
Resolving worker runtime to 'python'.
'local.settings.json' found in root directory (C:\Users\victoriahall\Documents\repos\sdk-servicebus).
Resolving worker runtime to 'python'.

Validating project...

  Validate host.json: PASSED
  Validate Flag Compatibility: PASSED
  Validate Folder Structure: PASSED
  Validation .python_packages directory exists: WARNING
    Directory '.python_packages' not found or is empty.
  Validate Python Programming Model: PASSED

The directory name is invalid. : 'C:\Users\victoriahall\AppData\Local\Temp\azure-functions\python:4-python3.13-buildenv-docker'
(.venv313) PS C:\Users\victoriahall\Documents\repos\sdk-servicebus> func --version
4.4.0

Steps to reproduce

  1. On a Windows machine, download Python 3.13 & create a 3.13 environment
  2. Start Docker
  3. Run func pack --build-native-deps in the terminal

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions