Expo-Notifications can't fetch token after Expo Upgrade 45/46

Hi there,

lately I wanted to upgrade my Managed Expo App from SDK 43 to 45 (also tested 46).
The app was running fine and the expo-notifications worked as well.

But after the Expo SDK Upgrade, I got the following error in Expo Go on Android:

[expo-notifications] Error encountered while updating server registration with latest device push token., [Error: Fetching the token failed: Please set your Project ID. A valid Firebase Project ID is required to communicate with Firebase server APIs: It identifies your application with Firebase.

Of course everything was already set up correctly, because it worked before the upgrade.
I haven’t changed anything, except some dependency fixes according to the Expo Upgrade manual.
I also checked everything again like the google-services.json, Firebase and Expo configurations, etc., but everything seems correct.

Does anyone know what could be the problem? Do you need more information?
Thank you!!

SDK Version: 45 (same problem with 46)
Platforms: Android

Hi, the same problem here, And I think this is not because the update and the problem is because of sth else! :thinking:

I made an EAS build of my app and the notifications actually work. Is it just an Expo Go problem??

1 Like

I use expo build:android to have apk compiles and actually as my compiles with expo build:android can’t resolve the push token (it was working but now it doesn’t), I will be thankful to tell me how can I have apk compiles for my project with EAS build, to check will it be start working or not!

In my case, android is ok, but iOS i tested with Expo SDK 43, 44, 45 all not working. It failed from this line:
const { status } = await Notifications.requestPermissionsAsync();

Any code placed after is not triggered. The app doesn’t crash but no token return. I guess it could be issue with new iOS version / Xcode? My app is standalone. I do “Expo eject” then “Npx pod-install” in Mac then upload to Apple store using XCode 13.

My SDK 45 package.json has these:
“expo-notifications”: “~0.15.4”,
“expo-updates”: “~0.13.4”,
“firebase”: “8.2.3”,

Hi! I have the same issue. Any solution?

Same here. In Expo Go, Notifications.getExpoPushTokenAsync() fails with the following error:

Fetching the token failed: Please set your Project ID. A valid Firebase Project ID is required to communicate with Firebase server APIs: It identifies your application with Firebase.Please refer to פתרון בעיות של אפשרויות אתחול  |  Firebase.

It only started today for me. Was fine yesterday and before.

When I build an APK with expo build:android however, there is no error, and push notifications work (both on Android and iOS).

Expo SDK v44.0.6.

1 Like

I’ve got the same issue.

Everything started after i upgraded from expo 45 to 46, now firebase phone auth doesn’t work, firebase recaptcha invisible verification crashes the app and also notification token is not working, i get firebase project id error, I was so happy after switching to expo but now I’m getting the same bug problems due to which i left react-native bare workflow

There’s a fix coming soon that should hopefully resolve this. Stay tuned for an update to Expo Go [ci] Fix incorrect expo-git-decrypt key name by Kudo · Pull Request #18652 · expo/expo · GitHub

1 Like

This bug has been fix with version: 2.25.2 of Expo Go on 2022-08-16T22:00:00Z

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.