Search Issue Tracker
By Design
Votes
0
Found in [Package]
2.2.0
Issue ID
MNB-58
Regression
No
UnityNotificationManager.java:164: error: cannot find symbol error when targeting SDK API lower than 33 with Mobile Notifications
Steps to reproduce:
1. Open the attached user's project
2. Make sure the SDK path in External Settings points toward Android Modules installed via HUB
3. Set the "Target SDK level" to 32, 31 or 30
4. Build for Android
5. Observe console error
Expected behavior: Build success
Actual behavior: build fails
Reproducible on: Mobile Notifications 2.2.0 (2021.3.28f1, 2022.3.4f1, 2023.1.4f1, 2023.2.0a23)
Not reproducible on: Mobile Notifications 2.1.1 (2021.3.26f1, 2022.2.21f1, 2023.1.0b18, 2023.2.0a16)
Notes:
-Console error:
UnityNotificationManager.java:164: error: cannot find symbol
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU)
symbol: variable TIRAMISU
location: class VERSION_CODES
-Workaround is to set the Target SDK level to 33
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on PluginManager::RefreshPlugins when closing the Editor without making any changes with JetBrains Rider selected as the External Code Editor and Google Mobile Ads third-party plugin imported
- GetMainLight() returns incorrect distanceAttenuation value for a Custom Shader when URP Forward+ Rendering Path is used
- Standalone Profiler crash on GuidReservations::Reserve when it is opened on a specific project
- m_RenderPipelineGlobalSettingsMap or m_SRPDefaultSettings is pointing to UnityEngine.Rendering.HighDefinition.HDRenderPipeline when High Definition RP package is removed
- Rendering Debugger fields have no padding at the bottom of the fields list
Resolution Note:
Mobile Notifications require SDK 33 to compile the code.
By default Unity set compile SDK to the same as target SDK. This can be altered by using custom gradle template:
- Enable Custom Main Gradle Template in Player Settings (Publishing)
- Open the template file in text Editor and modify compileSdkVersion to 33 instead of default **TARGETSDKVERSION**
Also note, that from August 31 Google Play will require to target SDK 33 for all new apps and app updates, so if you plan to publish anything after that date, set target SDK to 33:
https://developer.android.com/google/play/requirements/target-sdk