birkir / react-native-carplay

CarPlay with React Native
https://birkir.dev/react-native-carplay/
MIT License
625 stars 103 forks source link

"Unsupported object" error when pushing/presenting templates (example app) #176

Closed bitcrumb closed 3 months ago

bitcrumb commented 3 months ago

Describe the bug When running the example app, I get "Unsupported object" errors for voice control (present), map (push) and search (push). Is this something that used to work and has now changed? And if I try to present these via setRootTemplate, I get the same error.

To Reproduce Steps to reproduce the behavior: Run Example app and try opening voice/map/search.

Expected behavior I should be able to present these templates.

Screenshots/Videos

Simulator Screenshot - iPhone 15 Pro - 2024-03-25 at 15 37 32 Simulator Screenshot - iPhone 15 Pro - 2024-03-25 at 15 38 12 Simulator Screenshot - iPhone 15 Pro - 2024-03-25 at 15 38 17

CarPlay (please complete the following information):

saikiranm33 commented 3 months ago

@bitcrumb how do fixed the above issues ?

bitcrumb commented 3 months ago

@saikiranm33 The example project missed some entitlements (which got rid of most of the errors, but not all).

KestasVenslauskas commented 2 months ago

having same problem on emulator iOS version 15.4 Is this not enough?

com.apple.developer.carplay-audio

iOS version 17+ works fine.

ElangoPrince commented 2 months ago

@bitcrumb Facing same issue while using searchTemplate. I have added relevant entitlement in my project. (com.apple.developer.carplay-fueling). How to fix that? @birkir FYI.

Exception 'Unsupported object <CPSearchTemplate: 0x600003fc6700> <identifier: 9E253DD3-3912-4F2C-B5C2-B7FD1CD88709, userInfo: {
    templateId = "search-1714990663678-3200635217977703";
}, tabTitle: (null), tabImage: (null), showsTabBadge: 0> passed to pushTemplate:animated:completion:. Allowed classes: {(
    CPInformationTemplate,
    CPActionSheetTemplate,
    CPTabBarTemplate,
    CPAlertTemplate,
    CPGridTemplate,
    CPPointOfInterestTemplate,
    CPListTemplate
)}' was thrown while invoking pushTemplate on target RNCarPlay with params (
    "search-1714990663678-3200635217977703",
    1
)
ElangoPrince commented 2 months ago

@bitcrumb Facing same issue while using searchTemplate. I have added relevant entitlement in my project. (com.apple.developer.carplay-fueling). How to fix that? @birkir FYI.

Exception 'Unsupported object <CPSearchTemplate: 0x600003fc6700> <identifier: 9E253DD3-3912-4F2C-B5C2-B7FD1CD88709, userInfo: {
    templateId = "search-1714990663678-3200635217977703";
}, tabTitle: (null), tabImage: (null), showsTabBadge: 0> passed to pushTemplate:animated:completion:. Allowed classes: {(
    CPInformationTemplate,
    CPActionSheetTemplate,
    CPTabBarTemplate,
    CPAlertTemplate,
    CPGridTemplate,
    CPPointOfInterestTemplate,
    CPListTemplate
)}' was thrown while invoking pushTemplate on target RNCarPlay with params (
    "search-1714990663678-3200635217977703",
    1
)

I'm closing this issue. Since, Map's entitlements is required to use search template.