firebase-cpp-sdk icon indicating copy to clipboard operation
firebase-cpp-sdk copied to clipboard

Fix python interpreter build issues on systems without `python` executable

Open dconeybe opened this issue 3 years ago • 2 comments

Hardcoding python as the Python executable doesn't work on new MacBooks (and gLinux) since the python executable does not exist, only python3. So instead, use cmake's built-in mechanism for finding a Python interpreter, which will find either python or python3. A similar change was made to the Unity SDK: https://github.com/firebase/firebase-unity-sdk/pull/395.

The scripts that are run on GitHub Actions runners needed to be changed to explicitly specify -DFIREBASE_PYTHON_EXECUTABLE:FILEPATH=<python path> to ensure that the Python interpreter into which the dependencies (e.g. absl-py) were installed gets used. Otherwise, FindPythonInterp/find_package(Python3) may choose a different Python interpreter which does not have the dependencies installed and cause the scripts to fail due to the missing dependencies.

I also changed the cmake cache variable FIREBASE_PYTHON_EXECUTABLE to set FIREBASE_PYTHON_HOST_EXECUTABLE, which is used by the firebase-ios-sdk. Therefore, the GitHub Actions scripts need only set the former cmake cache variable and not the latter.

dconeybe avatar Jul 05 '22 20:07 dconeybe

❌  Integration test FAILED

Requested by @jonsimantov on commit aed2d15387c8f84fa9a00ec18fce9bce70a1240e Last updated: Mon Jul 11 15:22 PDT 2022 View integration test log & download artifacts

Failures Configs
database [TEST] [ERROR] [Linux] [1/2 ssl_lib: x86] [All 2 build_type]
firestore [TEST] [ERROR] [Linux] [1/2 ssl_lib: x86] [1/2 build_type: openssl]
[TEST] [FLAKINESS] [Android] [1/2 os: ubuntu] [1/2 android_device: android_latest]
(1 failed tests)  CRASH/TIMEOUT
[TEST] [FLAKINESS] [Android] [1/2 os: windows] [1/2 android_device: android_latest]
(1 failed tests)  WriteBatchTest.TestBatchesFailAtomicallyRaisingCorrectEvents
gma [TEST] [FLAKINESS] [iOS] [macos] [1/6 ios_device: ios_target]
(1 failed tests)  FirebaseGmaTest.TestRewardedAdStress
storage [TEST] [ERROR] [Linux] [1/2 ssl_lib: x86] [All 2 build_type]
[TEST] [FLAKINESS] [Android] [1/2 os: macos] [1/2 android_device: android_latest]
(1 failed tests)  CRASH/TIMEOUT

Add flaky tests to go/fpl-cpp-flake-tracker

github-actions[bot] avatar Jul 06 '22 15:07 github-actions[bot]

CPP binary SDK packaging triggered: https://github.com/firebase/firebase-cpp-sdk/actions/runs/2626994699 and subsequent integration tests: https://github.com/firebase/firebase-cpp-sdk/actions/runs/2627563631

dconeybe avatar Jul 07 '22 11:07 dconeybe