Skip to content

Commit c977bef

Browse files
committed
Merge remote-tracking branch 'origin/master' into snappy2
2 parents ece6774 + 8d65537 commit c977bef

File tree

82 files changed

+894
-858
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+894
-858
lines changed

.github/workflows/analytics.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ name: analytics
33
on:
44
pull_request:
55
paths:
6-
- 'FirebaseAnalytics.podspec.json'
7-
- 'FirebaseAnalyticsSwift**'
8-
- 'GoogleAppMeasurement.podspec.json'
6+
- 'FirebaseAnalytics**'
7+
- 'GoogleAppMeasurement**'
98
- '.github/workflows/analytics.yml'
109
- 'Gemfile*'
1110
schedule:
@@ -37,6 +36,11 @@ jobs:
3736
run: scripts/third_party/travis/retry.sh pod spec lint GoogleAppMeasurement.podspec.json --platforms=${{ matrix.target }} --sources=https://github.com/firebase/SpecsDev.git,https://github.com/firebase/SpecsStaging.git,https://cdn.cocoapods.org/
3837
- name: FirebaseAnalyticsSwift
3938
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseAnalyticsSwift.podspec --platforms=${{ matrix.target }}
39+
# The following steps are only run on `ios` due to product availability.
40+
- name: GoogleAppMeasurementOnDeviceConversion
41+
run: scripts/third_party/travis/retry.sh pod spec lint GoogleAppMeasurementOnDeviceConversion.podspec.json --platforms=ios --sources=https://github.com/firebase/SpecsDev.git,https://github.com/firebase/SpecsStaging.git,https://cdn.cocoapods.org/
42+
- name: FirebaseAnalyticsOnDeviceConversion
43+
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseAnalyticsOnDeviceConversion.podspec --platforms=ios
4044

4145
# TODO: Consider pushing GoogleAppMeasurement.podspec.json to SpecsDev to enable similar test
4246
# for FirebaseAnalytics.podspec.json

.github/workflows/generate_issues.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ on:
66
- '.github/workflows/generate_issues.yml'
77
- '.github/actions/testing_report_generation**'
88
schedule:
9-
# Run every day at 5am (PST) - cron uses UTC times
10-
- cron: '0 13 * * *'
9+
# Run every day at 4am (PST) - cron uses UTC times
10+
- cron: '0 12 * * *'
1111
jobs:
1212
generate_an_issue:
1313
# Don't run on private repo.

.github/workflows/notice_generation.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,13 @@ on:
55
paths:
66
- '.github/workflows/notice_generation.yml'
77
- '.github/actions/notices_generation**'
8+
schedule:
9+
# Run every day at 5am (PST) - cron uses UTC times
10+
- cron: '0 13 * * *'
811
jobs:
912
generate_a_notice:
1013
# Don't run on private repo.
11-
if: github.repository == 'Firebase/firebase-ios-sdk' && github.event_name != 'schedule'
14+
if: github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule'
1215
runs-on: macos-12
1316
name: Generate NOTICES
1417
env:
@@ -38,12 +41,13 @@ jobs:
3841
notices-path: ${{ env.NOTICES_PATH }}
3942
- name: Create a pull request
4043
run: |
44+
RUN_URL="${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}"
4145
gem install octokit
4246
ruby scripts/create_pull_request.rb \
4347
--repo-root ${GITHUB_WORKSPACE} \
4448
--repo-token ${{ secrets.GITHUB_TOKEN }} \
4549
--target-path ${{ env.NOTICES_PATH }} \
4650
--pr-title "NOTICES Change" \
47-
--pr-body "NOTICES Change is detected." \
51+
--pr-body "NOTICES Change is detected in [this GitHub Actions Run](${RUN_URL})." \
4852
--commit-comment "NOTICES change."
4953
shell: bash

.github/workflows/prerelease.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ on:
66
types: [closed]
77
workflow_dispatch:
88
schedule:
9-
# Run every day at 11pm (PST) - cron uses UTC times
10-
- cron: '0 7 * * *'
9+
# Run every day at 10pm (PST) - cron uses UTC times
10+
- cron: '0 6 * * *'
1111

1212
concurrency:
1313
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
@@ -553,6 +553,9 @@ jobs:
553553
runs-on: macos-12
554554
steps:
555555
- uses: actions/checkout@v2
556+
- uses: ruby/setup-ruby@359bebbc29cbe6c87da6bc9ea3bc930432750108
557+
with:
558+
ruby-version: '2.7'
556559
- name: Get token
557560
run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/bot-access.txt.gpg \
558561
bot-access.txt "$bot_token_secret"

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ on:
77
- '.github/workflows/release.yml'
88
workflow_dispatch:
99
schedule:
10-
# Run every day at 11pm (PST) - cron uses UTC times
11-
- cron: '0 7 * * *'
10+
# Run every day at 9pm (PST) - cron uses UTC times
11+
- cron: '0 5 * * *'
1212

1313
concurrency:
1414
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}

.github/workflows/update-cpp-sdk-on-release.yml

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,24 +41,41 @@ jobs:
4141

4242
- name: Ensure Cocoapods repo has been updated
4343
run: |
44-
# If the new version is simply vX.Y.Z, wait up to an hour for its podspec to be present.
45-
if [[ "$GITHUB_REF" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
46-
echo "Checking Cocoapods repo for associated Firebase ${GITHUB_REF:1} podspec."
47-
podspec_url="https://github.com/CocoaPods/Specs/blob/master/Specs/0/3/5/Firebase/${GITHUB_REF:1}/Firebase.podspec.json"
44+
# If the new version is simply vX.Y.Z or X.Y.Z, wait up to an hour each for its podspec and prebuilt zip file to be present.
45+
if [[ "$GITHUB_REF" =~ ^v?[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
46+
version=$(echo "$GITHUB_REF" | sed s/^v//) # remove leading v if present
47+
echo "Checking Cocoapods repo for associated Firebase ${version} podspec."
48+
podspec_url="https://github.com/CocoaPods/Specs/blob/master/Specs/0/3/5/Firebase/${version}/Firebase.podspec.json"
4849
for retry in {1..12} error; do
4950
# Check every 5 minutes, up to an hour, for the new podspec to be present.
5051
# If it's still not present, trigger the update anyway.
5152
if [[ $retry == "error" ]]; then
52-
echo "::warning ::Firebase ${GITHUB_REF:1} podspec not found, updating anyway."
53+
echo "::warning ::Firebase ${version} podspec not found, updating anyway."
5354
exit 0
5455
fi
5556
echo -n "Check ${podspec_url} (attempt ${retry}) ..."
56-
curl -L -f -o /dev/null "${podspec_url}" 2> /dev/null && echo " success!" && break
57+
curl -H 'Authorization: token ${{ github.token }}' -L -f -o /dev/null "${podspec_url}" 2> /dev/null && echo " success!" && break
58+
echo " failed."
59+
sleep 300
60+
done
61+
echo "Checking firebase-ios-sdk repo for ${version} prebuilt zip."
62+
# Check for the zip file on this actual release URL (which might include the leading v)
63+
zipfile_url="https://github.com/firebase/firebase-ios-sdk/releases/download/${GITHUB_REF}/Firebase.zip"
64+
for retry in {1..12} error; do
65+
# Check every 5 minutes, up to an hour, for the new zip file to be present.
66+
# If it's still not present, trigger the update anyway.
67+
if [[ $retry == "error" ]]; then
68+
echo "::warning ::Firebase ${version} zip file not found, updating anyway."
69+
exit 0
70+
fi
71+
echo -n "Check ${zipfile_url} (attempt ${retry}) ..."
72+
# curl's "-r 0-0" option means only download the first byte, this prevents us from downloading 300+ MB.
73+
curl -H 'Authorization: token ${{ github.token }}' -L -f -o /dev/null -r 0-0 "${zipfile_url}" 2> /dev/null && echo " success!" && break
5774
echo " failed."
5875
sleep 300
5976
done
6077
else
61-
echo "Tag '$GITHUB_REF' doesn't match the 'vX.Y.Z' format, skipping Cocoapods repo check."
78+
echo "Tag '$GITHUB_REF' doesn't match the 'vX.Y.Z' or 'X.Y.Z' format, skipping Cocoapods repo and release zip check."
6279
fi
6380
6481
- name: Trigger firebase-cpp-sdk update

AddNewPod.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ For top-level Firebase pods that map to documented products:
6868
* Make sure the public umbrella header is imported via [Firebase.h](CoreOnly/Sources/Firebase.h)
6969
wrapped in `__has_include`. Follow the existing examples for details.
7070
* Update [Firebase.podspec](Firebase.podspec).
71-
* Register Objective C library via registerInternalLibrary API like this
71+
* Register Objective-C library via registerInternalLibrary API like this
7272
[AppCheck example](FirebaseAppCheck/Sources/Core/FIRAppCheck.m).
7373
* Register Swift library by creating a component like
7474
[Functions example](FirebaseFunctions/Sources/Internal/FunctionsComponent.swift) and

Crashlytics/CHANGELOG.md

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,134 +1,134 @@
1-
# v8.13.0
1+
# 8.13.0
22
- [added] Updated upload-symbols to 3.11 and added logic to process Flutter project information (#9379)
33
- [fixed] Added native support for ARM / M1 Macs in upload-symbols (#8965)
44
- [fixed] Fixed an issue where passing nil as a value for a custom key or user ID did not clear the stored value as expected.
55

6-
# v8.9.0
6+
# 8.9.0
77
- [fixed] Fixed an issue where exceptions with `nil` reasons weren't properly recorded (#8671).
88

9-
# v8.8.0
9+
# 8.8.0
1010
- [added] Internal SDK updates to test potential future MetricKit support.
1111

12-
# v8.4.0
12+
# 8.4.0
1313
- [fixed] Bump Promises dependency. (#8365)
1414

15-
# v8.3.0
15+
# 8.3.0
1616
- [fixed] Add missing dependency that could cause missing symbol build failures. (#8137)
1717

18-
# v8.2.0
18+
# 8.2.0
1919
- [changed] Incorporated code quality changes around integer overflow, potential race conditions, and reinstalling signal handlers.
2020
- [fixed] Fixed an issue where iOS-only apps running on iPads would report iOS as their OS Name.
2121
- [fixed] Fixed depcrecation warning for projects with minimum deployment version iOS 13 and up.
2222

23-
# v8.0.0
23+
# 8.0.0
2424
- [changed] Added a warning to upload-symbols when it detects a dSYM with hidden symbols.
2525

26-
# v7.10.0
26+
# 7.10.0
2727
- [changed] Added a warning to upload-symbols when it detects a dSYM without any symbols.
2828

29-
# v7.9.0
29+
# 7.9.0
3030
- [changed] Updated Firebase pod to allow iOS 9 installation via `pod 'Firebase/Crashlytics'`
3131

32-
# v7.8.0
32+
# 7.8.0
3333
- [added] Added a new API checkAndUpdateUnsentReportsWithCompletion for updating the crash report from the previous run of the app if, for example, the developer wants to implement a feedback dialog to ask end-users for more information. Unsent Crashlytics Reports have familiar methods like setting custom keys and logs (#7503).
3434
- [changed] Added a limit to the number of unsent reports on disk to prevent disk filling up when automatic data collection is off. Developers can ensure this limit is never reached by calling send/deleteUnsentReports every run (#7619).
3535

36-
# v7.7.0
36+
# 7.7.0
3737
- [added] Added a new API to allow for bulk logging of custom keys and values (#7302).
3838

39-
# v7.6.0
39+
# 7.6.0
4040
- [fixed] Fixed an issue where some developers experienced a race condition involving binary image operations (#7459).
4141

42-
# v7.5.0
42+
# 7.5.0
4343
- [changed] Improve start-up performance by moving some initialization work to a background thread (#7332).
4444
- [changed] Updated upload-symbols to a version that is notarized to avoid macOS security alerts (#7323).
4545
- [changed] Deleting unsent reports with deleteUnsentReports no longer happens on the main thread (#7298).
4646

47-
# v7.4.0
47+
# 7.4.0
4848
- [changed] Removed obsolete crash reporting mechanism from the SDK (#7076).
4949

50-
# v7.3.0
50+
# 7.3.0
5151
- [added] Added Crashlytics support for x86 apps running on Apple Silicon via Rosetta 2
5252
- [changed] Decreased Crashlytics CocoaPods minimum deployment target from iOS 10 to iOS 9
5353
- [changed] Removed obsolete API calls from upload-symbols
5454
- [changed] Removed obsolete onboarding calls from the SDK.
5555

56-
# v7.1.0
56+
# 7.1.0
5757
- [fixed] Fixed an issue where symbol uploads would fail when there are spaces in the project path, particularly in Unity builds (#6789).
5858
- [changed] Added additional logging when settings requests fail with a 404 status to help customers debug onboarding issues (#6847).
5959

60-
# v4.6.2
60+
# 4.6.2
6161

6262
- [changed] Improved upload-symbols conversion speed. Customers with large dSYMs should see a significant improvement in the time it takes to upload Crashlytics symbols.
6363
- [fixed] Fixed Apple Watch crash related to `sigaction` (#6434).
6464

65-
# v4.6.0
65+
# 4.6.0
6666

6767
- [added] Added stackFrameWithAddress API for recording custom errors that are symbolicated on the backend (#5975).
6868
- [fixed] Fixed comment typos (#6363).
6969
- [fixed] Remove device information from binary image data crash info entries (#6382).
7070

71-
# v4.5.0
71+
# 4.5.0
7272

7373
- [fixed] Fixed a compiler warning and removed unused networking code (#6210).
7474
- [fixed] Fixed a crash that occurred rarely when trying to restart a URL session task without a valid request (#5984).
7575
- [added] Introduced watchOS support (#6262).
7676

77-
# v4.3.1
77+
# 4.3.1
7878

7979
- [fixed] Fixed a segmentation fault that could occur when writing crash contexts to disk (#6048).
8080

81-
# v4.3.0
81+
# 4.3.0
8282

8383
- [changed] Add dispatch_once for opening sdk log file. (#5904)
8484
- [changed] Functionally neutral updated import references for dependencies. (#5902)
8585

86-
# v4.2.0
86+
# 4.2.0
8787

8888
- [changed] Removed an unnecessary linker rule for embedding the Info.plist. (#5804)
8989

90-
# v4.1.1
90+
# 4.1.1
9191

9292
- [fixed] Fixed a crash that could occur if certain plist fields necessary to create Crashlytics records were missing at runtime. Also added some diagnostic logging to make the issue cause more explicit (#5565).
9393

94-
# v4.1.0
94+
# 4.1.0
9595

9696
- [fixed] Fixed unchecked `malloc`s in Crashlytics (#5428).
9797
- [fixed] Fixed an instance of undefined behavior when loading files from disk (#5454).
9898

99-
# v4.0.0
99+
# 4.0.0
100100

101101
- [changed] The Firebase Crashlytics SDK is now generally available.
102102

103-
# v4.0.0-beta.7
103+
# 4.0.0-beta.7
104104

105105
- [changed] Increased network timeout for symbol uploads to improve reliability on limited internet connections. (#5228)
106106

107-
# v4.0.0-beta.6
107+
# 4.0.0-beta.6
108108

109109
- [added] Added a new API to record custom exception models and stacktraces to Crashlytics. This is a replacement for the `recordCustomException` API that existed in the Fabric Crashlytics SDK (#5055)
110110
- [fixed] Fixed an issue with the `sendUnsentReports` API where reports wouldn't be uploaded until the method was called twice in specific instances (#5060)
111111
- [changed] Changed Crashlytics to use GoogleDataTransport to upload crashes (#4989)
112112
- [changed] Changed the origin that Crashlytics uses to register Crash events for Crash Free Users. Ensure you have installed Firebase Analytics version 6.3.1 or above (#5030)
113113

114-
# v4.0.0-beta.5
114+
# 4.0.0-beta.5
115115

116116
- [changed] Changed two endpoints in the Firebase Crashlytics SDK with no expected end-user impact (#4953, #4988).
117117

118-
# v4.0.0-beta.4
118+
# 4.0.0-beta.4
119119

120120
- [fixed] Fixed symbol collisions with the legacy Fabric Crashlytics SDK and added a warning not to include both (#4753, #4755)
121121
- [fixed] Added crash prevention checks (#4661)
122122

123-
# v4.0.0-beta.3
123+
# 4.0.0-beta.3
124124

125125
- [fixed] Fixed an import declaration for installing Crashlytics. Previously, the declaration caused a compile error when you installed using CocoaPods with the `generate_multiple_pods_project` flag set to true (#4786)
126126

127-
# v4.0.0-beta.2
127+
# 4.0.0-beta.2
128128

129129
- [fixed] Fixed VeraCode scanner issues for unchecked error conditions (#4669)
130130

131-
# v4.0.0-beta.1
131+
# 4.0.0-beta.1
132132

133133
This Firebase Crashlytics version includes the initial beta release of the Firebase Crashlytics SDK:
134134

Crashlytics/Crashlytics/Controllers/FIRCLSExistingReportManager.m

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,12 @@ - (NSUInteger)unsentReportsCount {
151151
// which should be at the start of the array.
152152
if (validReports.count > FIRCLSMaxUnsentReports) {
153153
NSUInteger deletingCount = validReports.count - FIRCLSMaxUnsentReports;
154-
FIRCLSInfoLog(@"Deleting %lu unsent reports over the limit of %lu to prevent disk space from "
155-
@"filling up. To prevent this make sure to call send/deleteUnsentReports.",
156-
deletingCount, FIRCLSMaxUnsentReports);
154+
FIRCLSInfoLog(
155+
@"Automatic data collection is disabled. Deleting %lu unsent reports over the limit of %lu "
156+
@"to prevent disk space from "
157+
@"filling up. To take action on these reports, call send/deleteUnsentReports. To turn on "
158+
@"automatic data collection, call setCrashlyticsCollectionEnabled with true",
159+
deletingCount, FIRCLSMaxUnsentReports);
157160
}
158161

159162
// Not that validReports is sorted, delete any reports at indices > MAX_UNSENT_REPORTS, and

Dangerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ end
3535
# multiple directories may have multiple labels.
3636
def labelsForModifiedFiles()
3737
labels = []
38+
labels.push("api: analytics") if @has_analytics_changes
3839
labels.push("api: abtesting") if @has_abtesting_changes
3940
labels.push("api: appcheck") if @has_appcheck_changes
4041
labels.push("api: appdistribution") if @has_appdistribution_changes
@@ -70,6 +71,18 @@ has_changelog_changes = hasChangesIn(["CHANGELOG"])
7071
has_license_changes = didModify(["LICENSE"])
7172

7273
## Product directories
74+
@has_analytics_changes = hasChangesIn([
75+
"FirebaseAnalyticsOnDeviceConversionWrapper",
76+
"FirebaseAnalyticsSwift",
77+
"FirebaseAnalyticsWithoutAdIdSupportWrapper",
78+
"FirebaseAnalyticsWrapper"
79+
]) || didModify([
80+
"FirebaseAnalytics.podspec.json",
81+
"FirebaseAnalyticsSwift.podspec",
82+
"FirebaseAnalyticsOnDeviceConversion.podspec",
83+
"GoogleAppMeasurement.podspec.json",
84+
"GoogleAppMeasurementOnDeviceConversion.podspec.json"
85+
])
7386
@has_abtesting_changes = hasChangesIn("FirebaseABTesting")
7487
@has_abtesting_api_changes = hasChangesIn("FirebaseABTesting/Sources/Public/")
7588
@has_appcheck_changes = hasChangesIn("FirebaseAppCheck")

0 commit comments

Comments
 (0)