firebase-tools icon indicating copy to clipboard operation
firebase-tools copied to clipboard

Firebase Functions for Python tries to deploy python311 even though I'm using python310

Open taeold opened this issue 2 years ago • 1 comments

Firebase CLI isn't considering python --version to inform rather than just assume latest.

Instead, I get cryptic errors like this:

functions: Failed to load function definition from source: FirebaseError: Failed to find location of Firebase Functions SDK. Did you forget to run '. "/Users/jamesdaniels/Code/my-flask-app/.firebase/yarg-asdfierjoieroi/functions/venv/bin/activate" && python3.11 -m pip install -r requirements.txt'?

Would be more helpful if CLI printed something like:

We expected python 3.11, found 3.10.

in addition to the above CTA.

taeold avatar Jun 09 '23 20:06 taeold

We are also getting a similar error after the recent 13.3.0 release but with Python 3.11 and 3.12. It looks like the documentation for Python functions still says 3.10 or 3.11 but now the tools are trying to use 3.12? This is on our CI runner so it's broken our CI. If I upgrade to 3.12 I can't deploy and can't run on the local emulators using the same version of firebase-tools.

Error: Failed to find location of Firebase Functions SDK. Did you forget to run '. "/home/runner/work/<redacted>/<redacted>/<redacted>/venv/bin/activate" && python3.12 -m pip install -r requirements.txt'?

curtis-jotson avatar Feb 15 '24 21:02 curtis-jotson