Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync: Send pixels for account removal + decoding issues #1065

Merged
merged 10 commits into from
Nov 11, 2024

Conversation

graeme
Copy link
Contributor

@graeme graeme commented Nov 8, 2024

Please review the release process for BrowserServicesKit here.

Required:

Task/Issue URL: https://app.asana.com/0/1201493110486074/1208723035104886/f
iOS PR: duckduckgo/iOS#3557
macOS PR: duckduckgo/macos-browser#3530
What kind of version bump will this require?: Minor

Description:

Adds sync errors for catching when the keychain read throws a decoding error and when the account is deleted for various reasons

Steps to test this PR:

  1. Make sure you've already activated sync.
  2. Deactivate sync (either delete the server data or just turn it off)
  3. You should see the sync_account_removed_reason_user-turned-off pixel in the console.

OS Testing:

  • iOS 14
  • iOS 15
  • iOS 16
  • macOS 10.15
  • macOS 11
  • macOS 12

Internal references:

Software Engineering Expectations
Technical Design Template

@graeme graeme self-assigned this Nov 8, 2024
do {
try updateAccount(account)
} catch {
dependencies.errorEvents.fire(.failedToSetupEngine, error: error)
}
}

private func updateAccount(_ account: SyncAccount? = nil) throws {
guard account?.state != .initializing else {
private func updateAccount(_ account: SyncAccount) throws {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Differentiating this from account removal to:

  • Enforce giving a reason for reporting
  • Prevent propagating nil values resulting in account removal

@graeme graeme marked this pull request as ready for review November 11, 2024 10:49
@Bunn Bunn self-requested a review November 11, 2024 13:14
@graeme graeme merged commit 6be7815 into main Nov 11, 2024
8 checks passed
@graeme graeme deleted the graeme/more-sync-pixels branch November 11, 2024 14:48
samsymons added a commit that referenced this pull request Nov 12, 2024
* main:
  Remediate TunnelVision, TunnelCrack and fix "Exclude Local Networks" (#1039)
  Sync: Send pixels for account removal + decoding issues (#1065)
  Bump github.com/duckduckgo/content-scope-scripts from 6.31.0 to 6.32.0 (#1067)
  Behavioral toast updates (#1063)
  point to CSS branch (#1051)
mgurgel pushed a commit that referenced this pull request Nov 18, 2024
Please review the release process for BrowserServicesKit
[here](https://app.asana.com/0/1200194497630846/1200837094583426).

**Required**:

Task/Issue URL:
https://app.asana.com/0/1201493110486074/1208723035104886/f
iOS PR: duckduckgo/iOS#3557
macOS PR: duckduckgo/macos-browser#3530
What kind of version bump will this require?: Minor

**Description**:

Adds sync errors for catching when the keychain read throws a decoding
error and when the account is deleted for various reasons

**Steps to test this PR**:
1. Make sure you've already activated sync.
2. Deactivate sync (either delete the server data or just turn it off)
3. You should see the `sync_account_removed_reason_user-turned-off`
pixel in the console.

**OS Testing**:

* [ ] iOS 14
* [ ] iOS 15
* [ ] iOS 16
* [ ] macOS 10.15
* [ ] macOS 11
* [ ] macOS 12

---
###### Internal references:
[Software Engineering
Expectations](https://app.asana.com/0/59792373528535/199064865822552)
[Technical Design
Template](https://app.asana.com/0/59792373528535/184709971311943)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants