[PR #2267] [MERGED] [EC-628] Added Crashlytics to the watchOS project #3470

Closed
opened 2025-11-26 23:33:13 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/2267
Author: @fedemkr
Created: 12/26/2022
Status: Merged
Merged: 12/30/2022
Merged by: @vvolkgang

Base: masterHead: EC-628-watch-crashlytics


📝 Commits (10+)

  • da0df9c EC-628 Added Crashlytics to the watchOS project, missing GoogleService-Info.plist for now
  • 9536396 addition of GoogleServices-info.plist.gpg
  • 0e5eac4 Re-add GoogleService-info.plist.gpg
  • 950c608 Merge branch 'master' into EC-628-watch-crashlytics
  • 5e8f0fc EC-628 Updated build.yml to decrypt and copy the GoogleService-Info.plist for Crashlytics and also added step to upload Watch dSYMs to Crashlytics
  • 7a6ba90 EC-628 Fix run command upload watch dsym build.yml
  • 445b1ef EC-628 Updated Apple iOS macos version to 12 in order to resolve Watch XCode dependencies correctly with SPM
  • 202deb8 EC-628 Added some logs to see where I'm located cause it's issuing a wrong path. Also deactivated droid builds so that it's faster to test and doesn't consume resources on that till the build is OK
  • 2032e3e EC-628 fixed variable reference build.yml
  • adfbbd2 EC-628 Removed ls of watch dsym export path before creating the folder that was causing the build to fail

📊 Changes

7 files changed (+226 additions, -6 deletions)

View changed files

.github/secrets/GoogleService-Info.plist.gpg (+0 -0)
📝 .github/workflows/build.yml (+25 -5)
src/watchOS/bitwarden/GoogleService-Info.plist (+34 -0)
src/watchOS/bitwarden/bitwarden WatchKit Extension/ExtensionDelegate.swift (+11 -0)
📝 src/watchOS/bitwarden/bitwarden WatchKit Extension/bitwardenApp.swift (+3 -1)
📝 src/watchOS/bitwarden/bitwarden.xcodeproj/project.pbxproj (+40 -0)
src/watchOS/bitwarden/bitwarden.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved (+113 -0)

📄 Description

Type of change

  • Bug fix
  • New feature development
  • Tech debt (refactoring, code cleanup, dependency upgrades, etc)
  • Build/deploy pipeline (DevOps)
  • Other

Objective

Add Firebase Crashlytics to the watchOS project so that we have crash reporting. AppCenter doesn't support watchOS that's why we are implementing the other one.

Code changes

  • ExtensionDelegate: Added this extension delegate to configure the firebase app
  • bitwardenApp: Referenced the delegate by using WKExtensionDelegateAdaptor
  • GoogleService-Info.plist: Added dummy info plist for the google service to have the reference in the project. Then it will be overriden in the CI build process with the one with the actual values.
  • project: Added firebase-ios-sdk package and the Crashlytics product.
  • build.yml:
    • Increased the runs-on to macos-12 in order to use newer XCode that can resolve dependencies using current schema for Swift Package Manager.
    • Decrypt GoogleService-Info.plist needed for Firebase config.
    • Copy watchOS app dSYMs to the export path on a new folder (they are on a new folder so they are not uploaded to AppCenter).
    • Added step to upload these dSYMs to Firebase Crashlytics. Regarding to this I wasn't able to make it work directly using the path with some wildcards so I just use bash find to get the upload-symbols script and execute it afterwards; this should be improved, but for now it works.
  • GoogleService-Info.plist.gpg: Added encrypted plist file for the Firebase config on the watchOS app

Before you submit

  • Please check for formatting errors (dotnet format --verify-no-changes) (required)
  • Please add unit tests where it makes sense to do so (encouraged but not required)
  • If this change requires a documentation update - notify the documentation team
  • If this change has particular deployment requirements - notify the DevOps team

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/2267 **Author:** [@fedemkr](https://github.com/fedemkr) **Created:** 12/26/2022 **Status:** ✅ Merged **Merged:** 12/30/2022 **Merged by:** [@vvolkgang](https://github.com/vvolkgang) **Base:** `master` ← **Head:** `EC-628-watch-crashlytics` --- ### 📝 Commits (10+) - [`da0df9c`](https://github.com/bitwarden/android/commit/da0df9c44053e41d7c13d26802750e72e500ae0d) EC-628 Added Crashlytics to the watchOS project, missing GoogleService-Info.plist for now - [`9536396`](https://github.com/bitwarden/android/commit/9536396a49090afa194d34b57e2a54d0bceeea56) addition of GoogleServices-info.plist.gpg - [`0e5eac4`](https://github.com/bitwarden/android/commit/0e5eac48a0d5f4eb7e6b5437ed86c514e5121569) Re-add GoogleService-info.plist.gpg - [`950c608`](https://github.com/bitwarden/android/commit/950c6080eae578b82bec6d05f2689bd01ad3f194) Merge branch 'master' into EC-628-watch-crashlytics - [`5e8f0fc`](https://github.com/bitwarden/android/commit/5e8f0fc29b3cd636a33d93e03ecb85e6e309c2b0) EC-628 Updated build.yml to decrypt and copy the GoogleService-Info.plist for Crashlytics and also added step to upload Watch dSYMs to Crashlytics - [`7a6ba90`](https://github.com/bitwarden/android/commit/7a6ba90948e0dd6ecf0e272097226aee229ebd23) EC-628 Fix run command upload watch dsym build.yml - [`445b1ef`](https://github.com/bitwarden/android/commit/445b1ef1ae8f43419b15045ffa51b2be7ad138b9) EC-628 Updated Apple iOS macos version to 12 in order to resolve Watch XCode dependencies correctly with SPM - [`202deb8`](https://github.com/bitwarden/android/commit/202deb8e1778894cd009da2588b188775880f947) EC-628 Added some logs to see where I'm located cause it's issuing a wrong path. Also deactivated droid builds so that it's faster to test and doesn't consume resources on that till the build is OK - [`2032e3e`](https://github.com/bitwarden/android/commit/2032e3ea3647d6742523d8d7ef7938ec3961ad66) EC-628 fixed variable reference build.yml - [`adfbbd2`](https://github.com/bitwarden/android/commit/adfbbd25488f1ac6e9bcaf333bdb3e284ea691e2) EC-628 Removed ls of watch dsym export path before creating the folder that was causing the build to fail ### 📊 Changes **7 files changed** (+226 additions, -6 deletions) <details> <summary>View changed files</summary> ➕ `.github/secrets/GoogleService-Info.plist.gpg` (+0 -0) 📝 `.github/workflows/build.yml` (+25 -5) ➕ `src/watchOS/bitwarden/GoogleService-Info.plist` (+34 -0) ➕ `src/watchOS/bitwarden/bitwarden WatchKit Extension/ExtensionDelegate.swift` (+11 -0) 📝 `src/watchOS/bitwarden/bitwarden WatchKit Extension/bitwardenApp.swift` (+3 -1) 📝 `src/watchOS/bitwarden/bitwarden.xcodeproj/project.pbxproj` (+40 -0) ➕ `src/watchOS/bitwarden/bitwarden.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved` (+113 -0) </details> ### 📄 Description ## Type of change - [ ] Bug fix - [X] New feature development - [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) - [ ] Build/deploy pipeline (DevOps) - [ ] Other ## Objective <!--Describe what the purpose of this PR is. For example: what bug you're fixing or what new feature you're adding--> Add Firebase Crashlytics to the watchOS project so that we have crash reporting. AppCenter doesn't support watchOS that's why we are implementing the other one. ## Code changes <!--Explain the changes you've made to each file or major component. This should help the reviewer understand your changes--> <!--Also refer to any related changes or PRs in other repositories--> * **ExtensionDelegate:** Added this extension delegate to configure the firebase app * **bitwardenApp:** Referenced the delegate by using `WKExtensionDelegateAdaptor` * **GoogleService-Info.plist:** Added dummy info plist for the google service to have the reference in the project. Then it will be overriden in the CI build process with the one with the actual values. * **project:** Added `firebase-ios-sdk` package and the `Crashlytics` product. * **build.yml:** * Increased the `runs-on` to `macos-12` in order to use newer XCode that can resolve dependencies using current schema for Swift Package Manager. * Decrypt `GoogleService-Info.plist` needed for Firebase config. * Copy watchOS app dSYMs to the export path on a new folder (they are on a new folder so they are not uploaded to AppCenter). * Added step to upload these dSYMs to Firebase Crashlytics. Regarding to this I wasn't able to make it work directly using the path with some wildcards so I just use bash `find` to get the `upload-symbols` script and execute it afterwards; this should be improved, but for now it works. * **GoogleService-Info.plist.gpg:** Added encrypted plist file for the Firebase config on the watchOS app ## Before you submit - Please check for formatting errors (`dotnet format --verify-no-changes`) (required) - Please add **unit tests** where it makes sense to do so (encouraged but not required) - If this change requires a **documentation update** - notify the documentation team - If this change has particular **deployment requirements** - notify the DevOps team --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-26 23:33:13 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#3470