expo-notifications 57.0.16 → 57.0.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/android/build.gradle +2 -2
  3. package/expo-module.config.json +1 -1
  4. package/ios/ExpoNotifications/Notifications/NotificationCenterManager.swift +67 -9
  5. package/ios/ExpoNotifications.podspec +4 -0
  6. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.module → 57.0.18/expo.modules.notifications-57.0.18.module} +7 -7
  7. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.module.md5 +1 -0
  8. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.module.sha1 +1 -0
  9. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.module.sha256 +1 -0
  10. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.module.sha512 +1 -0
  11. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.pom → 57.0.18/expo.modules.notifications-57.0.18.pom} +1 -1
  12. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.pom.md5 +1 -0
  13. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.pom.sha1 +1 -0
  14. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.pom.sha256 +1 -0
  15. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.18/expo.modules.notifications-57.0.18.pom.sha512 +1 -0
  16. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/maven-metadata.xml +4 -4
  17. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/maven-metadata.xml.md5 +1 -1
  18. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/maven-metadata.xml.sha1 +1 -1
  19. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/maven-metadata.xml.sha256 +1 -1
  20. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/maven-metadata.xml.sha512 +1 -1
  21. package/package.json +5 -5
  22. package/spm.config.json +1 -1
  23. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.module.md5 +0 -1
  24. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.module.sha1 +0 -1
  25. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.module.sha256 +0 -1
  26. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.module.sha512 +0 -1
  27. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.pom.md5 +0 -1
  28. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.pom.sha1 +0 -1
  29. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.pom.sha256 +0 -1
  30. package/local-maven-repo/host/exp/exponent/expo.modules.notifications/57.0.16/expo.modules.notifications-57.0.16.pom.sha512 +0 -1
  31. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16-sources.jar → 57.0.18/expo.modules.notifications-57.0.18-sources.jar} +0 -0
  32. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16-sources.jar.md5 → 57.0.18/expo.modules.notifications-57.0.18-sources.jar.md5} +0 -0
  33. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16-sources.jar.sha1 → 57.0.18/expo.modules.notifications-57.0.18-sources.jar.sha1} +0 -0
  34. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16-sources.jar.sha256 → 57.0.18/expo.modules.notifications-57.0.18-sources.jar.sha256} +0 -0
  35. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16-sources.jar.sha512 → 57.0.18/expo.modules.notifications-57.0.18-sources.jar.sha512} +0 -0
  36. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.aar → 57.0.18/expo.modules.notifications-57.0.18.aar} +0 -0
  37. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.aar.md5 → 57.0.18/expo.modules.notifications-57.0.18.aar.md5} +0 -0
  38. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.aar.sha1 → 57.0.18/expo.modules.notifications-57.0.18.aar.sha1} +0 -0
  39. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.aar.sha256 → 57.0.18/expo.modules.notifications-57.0.18.aar.sha256} +0 -0
  40. /package/local-maven-repo/host/exp/exponent/expo.modules.notifications/{57.0.16/expo.modules.notifications-57.0.16.aar.sha512 → 57.0.18/expo.modules.notifications-57.0.18.aar.sha512} +0 -0
package/CHANGELOG.md CHANGED
@@ -10,6 +10,16 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ ## 57.0.18 — 2026-09-11
14
+
15
+ _This version does not introduce any user-facing changes._
16
+
17
+ ## 57.0.17 — 2026-09-04
18
+
19
+ ### 🐛 Bug fixes
20
+
21
+ - [iOS] Fix a data race on `NotificationCenterManager`'s delegate list that crashed the app with `SIGSEGV` when one app context registered its modules while another tore its own down, such as on a dev-client reload or `Updates.reloadAsync()`. [#49554](https://github.com/expo/expo/pull/49554) by [@dennytosp](https://github.com/dennytosp))
22
+
13
23
  ## 57.0.16 — 2026-09-01
14
24
 
15
25
  _This version does not introduce any user-facing changes._
@@ -5,13 +5,13 @@ plugins {
5
5
  }
6
6
 
7
7
  group = 'host.exp.exponent'
8
- version = '57.0.16'
8
+ version = '57.0.18'
9
9
 
10
10
  android {
11
11
  namespace "expo.modules.notifications"
12
12
  defaultConfig {
13
13
  versionCode 21
14
- versionName '57.0.16'
14
+ versionName '57.0.18'
15
15
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
16
16
  consumerProguardFiles 'proguard-rules.pro'
17
17
  }
@@ -35,7 +35,7 @@
35
35
  "publication": {
36
36
  "groupId": "host.exp.exponent",
37
37
  "artifactId": "expo.modules.notifications",
38
- "version": "57.0.16",
38
+ "version": "57.0.18",
39
39
  "repository": "local-maven-repo"
40
40
  }
41
41
  }
@@ -32,6 +32,59 @@ public extension NotificationDelegate {
32
32
  func didFailRegistration(_ error: Error) {}
33
33
  }
34
34
 
35
+ /**
36
+ The delegates of `NotificationCenterManager`, and the responses that arrived before any delegate
37
+ could handle them.
38
+
39
+ The manager is a process-wide singleton, but app contexts are not: the modules of an incoming
40
+ context register themselves while an outgoing context tears its own down, which happens on every
41
+ dev-client reload and on `Updates.reloadAsync()`. Both arrays are therefore written from more than
42
+ one thread at a time, so they live behind a lock.
43
+ */
44
+ internal final class NotificationDelegateRegistry {
45
+ private let state = Mutex(State())
46
+
47
+ private struct State {
48
+ var delegates: [NotificationDelegate] = []
49
+ var pendingResponses: [UNNotificationResponse] = []
50
+ }
51
+
52
+ /**
53
+ A snapshot of the delegates. Callers iterate the snapshot instead of holding the lock across a
54
+ delegate callback: `add` hands back the pending responses so that the caller can offer them to
55
+ the delegate it just added, and a delegate is free to add or remove delegates from there.
56
+ */
57
+ var delegates: [NotificationDelegate] {
58
+ state.withLock { $0.delegates }
59
+ }
60
+
61
+ var pendingResponses: [UNNotificationResponse] {
62
+ state.withLock { $0.pendingResponses }
63
+ }
64
+
65
+ /**
66
+ Adds the delegate, and returns the responses that it still has to be offered.
67
+ */
68
+ func add(_ delegate: NotificationDelegate) -> [UNNotificationResponse] {
69
+ state.withLock { state in
70
+ state.delegates.append(delegate)
71
+ return state.pendingResponses
72
+ }
73
+ }
74
+
75
+ func remove(_ delegate: AnyObject) {
76
+ state.withLock { $0.delegates.removeAll { $0 === delegate } }
77
+ }
78
+
79
+ func appendPendingResponse(_ response: UNNotificationResponse) {
80
+ state.withLock { $0.pendingResponses.append(response) }
81
+ }
82
+
83
+ func removeAllPendingResponses() {
84
+ state.withLock { $0.pendingResponses.removeAll() }
85
+ }
86
+ }
87
+
35
88
  /**
36
89
  Singleton that sets itself as the UserNotificationCenter delegate,
37
90
  and calls its own delegates in response to notification center calls.
@@ -42,8 +95,16 @@ public class NotificationCenterManager: NSObject,
42
95
  @objc
43
96
  public static let shared = NotificationCenterManager()
44
97
 
45
- var delegates: [NotificationDelegate] = []
46
- var pendingResponses: [UNNotificationResponse] = []
98
+ private let registry = NotificationDelegateRegistry()
99
+
100
+ var delegates: [NotificationDelegate] {
101
+ registry.delegates
102
+ }
103
+
104
+ var pendingResponses: [UNNotificationResponse] {
105
+ registry.pendingResponses
106
+ }
107
+
47
108
  let userNotificationCenter: UNUserNotificationCenter = UNUserNotificationCenter.current()
48
109
 
49
110
  private override init() {
@@ -62,20 +123,17 @@ public class NotificationCenterManager: NSObject,
62
123
  }
63
124
 
64
125
  public func addDelegate(_ delegate: NotificationDelegate) {
65
- delegates.append(delegate)
66
126
  var handled = false
67
- for pendingResponse in pendingResponses {
127
+ for pendingResponse in registry.add(delegate) {
68
128
  handled = delegate.didReceive(pendingResponse, completionHandler: {}) || handled
69
129
  }
70
130
  if handled {
71
- pendingResponses.removeAll()
131
+ registry.removeAllPendingResponses()
72
132
  }
73
133
  }
74
134
 
75
135
  public func removeDelegate(_ delegate: AnyObject) {
76
- if let index = delegates.firstIndex(where: { $0 === delegate }) {
77
- delegates.remove(at: index)
78
- }
136
+ registry.remove(delegate)
79
137
  }
80
138
 
81
139
  // MARK: - Called by PushTokenAppDelegateSubscriber
@@ -118,7 +176,7 @@ public class NotificationCenterManager: NSObject,
118
176
  handled = delegate.didReceive(response, completionHandler: completionHandler) || handled
119
177
  }
120
178
  if !handled {
121
- pendingResponses.append(response)
179
+ registry.appendPendingResponse(response)
122
180
  }
123
181
  completionHandler()
124
182
  }
@@ -31,5 +31,9 @@ Pod::Spec.new do |s|
31
31
  test_spec.dependency 'ExpoModulesTestCore'
32
32
 
33
33
  test_spec.source_files = "Tests/**/*.{m,mm,swift}"
34
+
35
+ test_spec.pod_target_xcconfig = {
36
+ 'OTHER_LDFLAGS' => '$(inherited) -lc++'
37
+ }
34
38
  end
35
39
  end
@@ -3,7 +3,7 @@
3
3
  "component": {
4
4
  "group": "host.exp.exponent",
5
5
  "module": "expo.modules.notifications",
6
- "version": "57.0.16",
6
+ "version": "57.0.18",
7
7
  "attributes": {
8
8
  "org.gradle.status": "release"
9
9
  }
@@ -24,8 +24,8 @@
24
24
  },
25
25
  "files": [
26
26
  {
27
- "name": "expo.modules.notifications-57.0.16.aar",
28
- "url": "expo.modules.notifications-57.0.16.aar",
27
+ "name": "expo.modules.notifications-57.0.18.aar",
28
+ "url": "expo.modules.notifications-57.0.18.aar",
29
29
  "size": 425993,
30
30
  "sha512": "fbe3317e826721d3e5f36ec14b2d5f5e1479b9c16d24d61104e5be2e6d32105271acdfdaf0d539efe6f5fa9527a8e1d749bb996c19fed6c0d7eced774fc47bae",
31
31
  "sha256": "e6d92a1bc2481a0676636c715cd467c96d2ec2816ae0edec9fef02421f8febbe",
@@ -136,8 +136,8 @@
136
136
  ],
137
137
  "files": [
138
138
  {
139
- "name": "expo.modules.notifications-57.0.16.aar",
140
- "url": "expo.modules.notifications-57.0.16.aar",
139
+ "name": "expo.modules.notifications-57.0.18.aar",
140
+ "url": "expo.modules.notifications-57.0.18.aar",
141
141
  "size": 425993,
142
142
  "sha512": "fbe3317e826721d3e5f36ec14b2d5f5e1479b9c16d24d61104e5be2e6d32105271acdfdaf0d539efe6f5fa9527a8e1d749bb996c19fed6c0d7eced774fc47bae",
143
143
  "sha256": "e6d92a1bc2481a0676636c715cd467c96d2ec2816ae0edec9fef02421f8febbe",
@@ -156,8 +156,8 @@
156
156
  },
157
157
  "files": [
158
158
  {
159
- "name": "expo.modules.notifications-57.0.16-sources.jar",
160
- "url": "expo.modules.notifications-57.0.16-sources.jar",
159
+ "name": "expo.modules.notifications-57.0.18-sources.jar",
160
+ "url": "expo.modules.notifications-57.0.18-sources.jar",
161
161
  "size": 100296,
162
162
  "sha512": "577e9667d10356e13dbe0e068e9e2bb2471d2b3779e7dac73cfceb3da4229c57f94633d598ede255debd9810a4427f39272bc17e76c7b77b4d0a7fef35757f85",
163
163
  "sha256": "148252dd1787d13e6671cd522ac117da77b195820b40fad96f416fe9a14719a1",
@@ -0,0 +1 @@
1
+ 04696db279efd0bd262accf85738271a20f24aeb588339b3b575a6bd341ca56f
@@ -0,0 +1 @@
1
+ 560dd8bcaf7476940ce23d7fc0ac07d35f67a499916430746e3332c93217bd2fe155c91e9da29ae43916fc0e82468e270664ab6bbd30587a4f341442b5460c60
@@ -9,7 +9,7 @@
9
9
  <modelVersion>4.0.0</modelVersion>
10
10
  <groupId>host.exp.exponent</groupId>
11
11
  <artifactId>expo.modules.notifications</artifactId>
12
- <version>57.0.16</version>
12
+ <version>57.0.18</version>
13
13
  <packaging>aar</packaging>
14
14
  <name>expo.modules.notifications</name>
15
15
  <url>https://github.com/expo/expo</url>
@@ -0,0 +1 @@
1
+ cdd8dbbd3d6768cf62d04a570c5464f520f0815f247a023d71d5acc3b1537955
@@ -0,0 +1 @@
1
+ c396ceff81aad62a8705ae12e026ac5073b920567ad3935bfb21f630fa3b76152d3e797390e005bb805665e17d98570bc47b38e43071b7b0f4b730bd5bdeea3f
@@ -3,11 +3,11 @@
3
3
  <groupId>host.exp.exponent</groupId>
4
4
  <artifactId>expo.modules.notifications</artifactId>
5
5
  <versioning>
6
- <latest>57.0.16</latest>
7
- <release>57.0.16</release>
6
+ <latest>57.0.18</latest>
7
+ <release>57.0.18</release>
8
8
  <versions>
9
- <version>57.0.16</version>
9
+ <version>57.0.18</version>
10
10
  </versions>
11
- <lastUpdated>20260901160717</lastUpdated>
11
+ <lastUpdated>20260911111651</lastUpdated>
12
12
  </versioning>
13
13
  </metadata>
@@ -1 +1 @@
1
- d3131cae624a46db1813ca0b5136564d
1
+ 4834bb1d434ca1e7092416264c6550ca
@@ -1 +1 @@
1
- 5f39a1a01b9acc3c52f9abf7dd62454f3e964d08
1
+ 33ad0647c2c75fa332b6c8f60dd5daf33559c77b
@@ -1 +1 @@
1
- 9a07897a23ebc461c32f1db7e5302467a0b162db3b6f1a62498eac9449751570
1
+ 087a7b78fa9a3aa01439ed9f2dd7e29d03422b5f58caa4e20c7e38d2d332d6ab
@@ -1 +1 @@
1
- 26d2415fb013575b238c7b8692d17c95f100361f2a35559e7bb74b8531f19a3348ec3517393b32cb0fdb19b8b87350f34356da43a574a448c63f2fa03b66f811
1
+ a4cadf5bef28b4ce547995344b048fb7acec3eae6e48760d1fd44ee091cd989dae2a63b17dfb35564383fa88636627889825d0413e320b9473f439d87dd1ae9f
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-notifications",
3
- "version": "57.0.16",
3
+ "version": "57.0.18",
4
4
  "description": "Provides an API to fetch push notification tokens and to present, schedule, receive, and respond to notifications.",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -36,14 +36,14 @@
36
36
  "@expo/image-utils": "^0.11.5",
37
37
  "abort-controller": "^3.0.0",
38
38
  "badgin": "^1.1.5",
39
- "expo-application": "~57.0.2",
40
- "expo-constants": "~57.0.17"
39
+ "expo-application": "~57.0.3",
40
+ "expo-constants": "~57.0.18"
41
41
  },
42
42
  "devDependencies": {
43
43
  "@types/node": "^22.14.0",
44
44
  "@types/react": "~19.2.0",
45
45
  "memfs": "^3.2.0",
46
- "expo": "57.0.19",
46
+ "expo": "57.0.22",
47
47
  "expo-module-scripts": "56.0.3"
48
48
  },
49
49
  "peerDependencies": {
@@ -51,7 +51,7 @@
51
51
  "react": "*",
52
52
  "react-native": "*"
53
53
  },
54
- "gitHead": "b76ecf192c5325793bcea31dd9bb8efd91f9ad7f",
54
+ "gitHead": "9e5319c0f821a27b7924841903abae50e2b41790",
55
55
  "scripts": {
56
56
  "build": "expo-module build",
57
57
  "build:plugin": "expo-module build plugin",
package/spm.config.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "name": "ExpoNotifications",
6
6
  "podName": "ExpoNotifications",
7
7
  "platforms": [
8
- "iOS(.v16)"
8
+ "iOS(\"16.4\")"
9
9
  ],
10
10
  "externalDependencies": [
11
11
  "ReactNativeDependencies",
@@ -1 +0,0 @@
1
- 24908b5147bc5e2e16864a258e67dd8cb4ef55a0b661b6c2df7babf9677a5e4a
@@ -1 +0,0 @@
1
- ab55bb49eb2dd1bdd0710e95dd9ea1878da054cab03d0caf550a0ced7cd28da3baaf669b2c46c8b8760f8fe0ce19b0b90fe78833f5835f06688e8c3e686f31a2
@@ -1 +0,0 @@
1
- d2a251522db5f4b55441605531d9321f62c9a2f954101214d5925801f6107627
@@ -1 +0,0 @@
1
- 81d7b331feb731144fb65603120ce1189117dc085cd5d96e5a6559039467efd40811aaf51dceb876e2dc33cb42be404dedf435234e60a32373f930a108576905