Commit 822b28e
Update iOS dependencies - Mon Apr 18 2022 (#902)
* Update iOS dependencies - Mon Apr 18 2022
### iOS
- Firebase/Analytics → 8.15.0
- Firebase/Auth → 8.15.0
- Firebase/Core → 8.15.0
- Firebase/Crashlytics → 8.15.0
- Firebase/Database → 8.15.0
- Firebase/DynamicLinks → 8.15.0
- Firebase/Firestore → 8.15.0
- Firebase/Functions → 8.15.0
- Firebase/Installations → 8.15.0
- Firebase/Messaging → 8.15.0
- Firebase/RemoteConfig → 8.15.0
- Firebase/Storage → 8.15.0
> Created by [Update Android and iOS dependencies workflow](https://github.com/firebase/firebase-cpp-sdk/actions/runs/2185021604).
* query_main.h: fix build error due to Filter being renamed to FieldFilter.
This fixes the following build error in `ubuntu-latest-Release-x64-static`:
```
firestore/src/main/query_main.h:185:34: error: no type named 'Operator' in 'firebase::firestore::core::Filter'
using Operator = core::Filter::Operator;
~~~~~~~~~~~~~~^
```
e.g. https://github.com/firebase/firebase-cpp-sdk/runs/6065960625
* firestore_snappy.patch.txt: patch in a PR that fixes a Python build error.
This commit patches in firebase/firebase-ios-sdk#9662, which creates dedicated virtualenv instances for each Python script that is run by cmake. By doing this, each script can have its own set of dependencies installed and does not rely on the host system's Python interpreter having any particular set of third-party modules installed.
This is not specifically related to Snappy, but, for convenience, is being incorporated into the patch file for snappy.
This commit fixes the following build error (https://github.com/firebase/firebase-cpp-sdk/runs/6065960193):
```
[ 83%] Generating nanopb sources
google/firestore/v1/document.proto:20:1: warning: Import google/api/annotations.proto is unused.
google/firestore/v1/query.proto:20:1: warning: Import google/api/annotations.proto is unused.
google/firestore/v1/common.proto:20:1: warning: Import google/api/annotations.proto is unused.
google/firestore/v1/write.proto:20:1: warning: Import google/api/annotations.proto is unused.
google/firestore/admin/index.proto:21:1: warning: Import google/api/annotations.proto is unused.
*************************************************************
*** Could not import the Google protobuf Python libraries ***
*** Try installing package 'python-protobuf' or similar. ***
*************************************************************
Traceback (most recent call last):
File "external/src/firestore/Firestore/Protos/tmpuwkOue.py", line 25
import nanopb_generator as nanopb
File "external/src/firestore-build/external/src/nanopb/generator/nanopb_generator.py", line 25
import google.protobuf.text_format as text_format
File "external/src/firestore-build/external/src/protobuf/python/google/protobuf/text_format.py", line 51
import six
ImportError: No module named six
--nanopb_out: protoc-gen-nanopb: Plugin failed with status code 1.
```
* firestore_snappy.patch.txt: hack test to see if the windows python error can be fixed by using a temporary directory.
A previous commit, bc4a657, patched firebase-ios-sdk with firebase/firebase-ios-sdk#9662, which modified cmake builds to create a python virtualenv for each python script.
This, however, ran into a strange problem in the Windows GitHub Actions runners, where creating the virtualenv failed when it attempted to call ensurepip.
The suspected root cause is a MAX_PATH length violation.
To test out this hypothesis, this commit modifies the FirebaseSetupPythonInterpreter() to create the Python virtualenv in a temporary directory instead of a well-defined subdirectory of cmake's binary directory.
This should have a shorter path length for the virtualenv. If this works, then possibly we will need to provide a way to override the base directory for the pyvenv's.
Here is the actual failure from https://github.com/firebase/firebase-cpp-sdk/runs/6083486670
```
-- Found PythonInterp: C:/ProgramData/chocolatey/bin/python2.7.exe (found suitable version "2.7.9", minimum required is "2.7")
-- Found Python3: C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe (found version "3.10.4") found components: Interpreter
-- FirebaseSetupPythonInterpreter(FirestoreProtos): Creating Python virtualenv in D:/a/firebase-cpp-sdk/firebase-cpp-sdk/ta/admob/it/bin/external/src/firestore-build/Firestore/Protos/pyvenv/FirestoreProtos using C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe
Error: Command '['D:\\a\\firebase-cpp-sdk\\firebase-cpp-sdk\\ta\\admob\\it\\bin\\external\\src\\firestore-build\\Firestore\\Protos\\pyvenv\\FirestoreProtos\\Scripts\\python3.exe', '-Im', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 3221225781.
CMake Error at bin/external/src/firestore/cmake/python_setup.cmake:133 (message):
Failed to create a Python virtualenv in
D:/a/firebase-cpp-sdk/firebase-cpp-sdk/ta/admob/it/bin/external/src/firestore-build/Firestore/Protos/pyvenv/FirestoreProtos
using C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe
Call Stack (most recent call first):
bin/external/src/firestore/Firestore/Protos/CMakeLists.txt:16 (FirebaseSetupPythonInterpreter)
```
* Revert "firestore_snappy.patch.txt: hack test to see if the windows python error can be fixed by using a temporary directory."
This hack didn't fix anything: the same problem occurred: https://github.com/firebase/firebase-cpp-sdk/runs/6087940880
This reverts commit 3936b10.
* Capture stderr when creating the virtualenv to see if it adds any extra info
* Revert "Capture stderr when creating the virtualenv to see if it adds any extra info"
Didn't help.
This reverts commit 3030e74.
* build_testapps.py: Specify `FIREBASE_PYTHON_HOST_EXECUTABLE` to cmake
This _may_ fix the following `build-desktop-windows-latest-openssl` build error:
```
-- Found PythonInterp: C:/ProgramData/chocolatey/bin/python2.7.exe
-- Found Python3: C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe
-- FirebaseSetupPythonInterpreter(FirestoreProtos): Creating Python virtualenv in D:/a/firebase-cpp-sdk/firebase-cpp-sdk/ta/admob/it/bin/external/src/firestore-build/Firestore/Protos/pyvenv/FirestoreProtos using C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe
CMake Error at bin/external/src/firestore/cmake/python_setup.cmake:136 (message):
Failed to create a Python virtualenv in
D:/a/firebase-cpp-sdk/firebase-cpp-sdk/ta/admob/it/bin/external/src/firestore-build/Firestore/Protos/pyvenv/FirestoreProtos
using C:/hostedtoolcache/windows/Python/3.10.4/x64/python3.exe
Command
'['D:\\a\\firebase-cpp-sdk\\firebase-cpp-sdk\\ta\\admob\\it\\bin\\external\\src\\firestore-build\\Firestore\\Protos\\pyvenv\\FirestoreProtos\\Scripts\\python3.exe',
'-Im', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit
status 3221225781.
Call Stack (most recent call first):
bin/external/src/firestore/Firestore/Protos/CMakeLists.txt:16 (FirebaseSetupPythonInterpreter)
```
It appears that `find_package(Python3)` is finding an undesirable Python interpreter (i.e. the one in C:/hostedtoolcache). Instead, it should find the one installed by the GitHub Actions workflow. Probably this incorrect Python doesn't correctly support virtualenv.
By setting the `FIREBASE_PYTHON_HOST_EXECUTABLE` cmake cache variable, the `FirebaseSetupPythonInterpreter()` function will use that interpreter, the correct interpreter, instead of searching for one and finding a wrong one.
Co-authored-by: firebase-workflow-trigger-bot <[email protected]>
Co-authored-by: Denver Coneybeare <[email protected]>
Co-authored-by: Jon Simantov <[email protected]>1 parent c2619dc commit 822b28e
File tree
22 files changed
+864
-595
lines changed- admob/integration_test
- analytics
- integration_test
- ios_headers
- app/integration_test
- auth/integration_test
- cmake/external
- database/integration_test
- dynamic_links/integration_test
- firestore
- integration_test_internal
- integration_test
- src/main
- functions/integration_test
- installations/integration_test
- ios_pod
- messaging/integration_test
- release_build_files
- remote_config/integration_test
- scripts/gha
- storage/integration_test
22 files changed
+864
-595
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
Large diffs are not rendered by default.
0 commit comments