question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error with RN 0.57: java.lang.String cannot be cast to AccessibilityDelegateUtil

See original GitHub issue

Current behaviour

With RN version 0.57, on android, in a new application created with react-native init every component crash the application with the following error:

java.lang.String cannot be cast to com.facebook.react.uimanager.AccessibilityDelegateUtil$AccessibilityRole
setDelegate
    AccessibilityDelegateUtil.java:93
updateViewAccessibility
    BaseViewManager.java:260
onAfterUpdateTransaction
    BaseViewManager.java:266
updateProperties
    ViewManager.java:33
createView
    NativeViewHierarchyManager.java:269
execute
    UIViewOperationQueue.java:200
run
    UIViewOperationQueue.java:888
flushPendingBatches
    UIViewOperationQueue.java:1001
access$2400
    UIViewOperationQueue.java:46
doFrameGuarded
    UIViewOperationQueue.java:1061
doFrame
    GuardedFrameCallback.java:29
doFrame
    ReactChoreographer.java:134
doFrame
    ChoreographerCompat.java:105
run
    Choreographer.java:909
doCallbacks
    Choreographer.java:723
doFrame
    Choreographer.java:655
run
    Choreographer.java:897
handleCallback
    Handler.java:790
dispatchMessage
    Handler.java:99
loop
    Looper.java:164
main
    ActivityThread.java:6494
invoke
    Method.java
run
    RuntimeInit.java:438
main
    ZygoteInit.java:807

Code sample

  • create a new app with react-native init
  • than install react-native-paper with
$ yarn add react-native-paper
$ yarn add react-native-vector-icons
$ react-native link react-native-vector-icons
  • add PaperProvider Component
  • add a Button or AppBar to the main component

Your Environment

software version
android Oreo
react-native 0.57
react-native-paper 2.1.3
node 10.0
npm or yarn 1.10.1

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
Trancevercommented, Oct 23, 2018
0reactions
httolcommented, Oct 23, 2018

same issue,i think its a bug

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do I fix this React Native error:"java.lang.String cannot be ...
Your version is 0.57 while Error when trying to use Button in react-native says it works in 0.55 version. Better give it a...
Read more >
java.lang.string cannot be cast to com.facebook.react.bridge ...
The error message says it all. com.facebook.react.bridge.readablenativemap cannot be cast to java.lang.string. You are returning an array just fine, ...
Read more >
React Native Error 'java.lang.String cannot be cast to com ...
The issue is caused by a bug in the latest react native version 0.57. The react native error is caused by Button component...
Read more >
ReactNative遇到的问题 - 简书
1、React Native -- java.lang.string cannot ...uimanager.accessibility DelegateUt 问题描述: 给...
Read more >
java.lang.String cannot be cast to java.lang.Double #218
Asked question in discussions; Tried the troubleshooting Wiki; Followed the migration Wiki. Describe the bug After npm i react-natove-dotenv and set it out ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found