Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Screenshot record fails because of --> "Accessibility content change on non-UI thread" #311

Open
findjigar opened this issue Sep 20, 2022 · 0 comments

Comments

@findjigar
Copy link

Espresso version: 3.5.0-alpha07
Material version: 1.5.0

E/ViewRootImpl: Accessibility content change on non-UI thread. Future Android versions will throw an exception.
    android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
        at android.view.ViewRootImpl$SendWindowContentChangedAccessibilityEvent.runOrPost(ViewRootImpl.java:8882)
        at android.view.ViewRootImpl.postSendWindowContentChangedCallback(ViewRootImpl.java:7928)
        at android.view.ViewRootImpl.notifySubtreeAccessibilityStateChanged(ViewRootImpl.java:8108)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.ViewGroup.notifySubtreeAccessibilityStateChanged(ViewGroup.java:3705)
        at android.view.View.notifyViewAccessibilityStateChangedIfNeeded(View.java:12837)
        at android.view.View.setLabelFor(View.java:9953)
        at com.google.android.material.textfield.TextInputLayout$AccessibilityDelegate.onInitializeAccessibilityNodeInfo(TextInputLayout.java:4458)
        at androidx.core.view.AccessibilityDelegateCompat$AccessibilityDelegateAdapter.onInitializeAccessibilityNodeInfo(AccessibilityDelegateCompat.java:87)
        at android.view.View.onInitializeAccessibilityNodeInfo(View.java:8255)
        at com.google.android.material.textfield.TextInputEditText.onInitializeAccessibilityNodeInfo(TextInputEditText.java:194)
        at androidx.core.view.ViewCompat.onInitializeAccessibilityNodeInfo(ViewCompat.java:698)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.createNodeInfoFromView(AccessibilityUtil.java:179)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.createNodeInfoFromView(AccessibilityUtil.java:156)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.access$000(AccessibilityUtil.java:41)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil$AXTreeNode.<init>(AccessibilityUtil.java:602)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:581)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
E/ViewRootImpl:     at com.facebook.testing.screenshot.layouthierarchy.AccessibilityUtil.generateAccessibilityTree(AccessibilityUtil.java:586)
        at com.facebook.testing.screenshot.internal.ScreenshotImpl.record(ScreenshotImpl.java:280)
        at com.facebook.testing.screenshot.internal.RecordBuilderImpl.record(RecordBuilderImpl.java:154)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant