android-developer-assistant icon indicating copy to clipboard operation
android-developer-assistant copied to clipboard

App doesn't detect access from text to screen

Open Galo223344 opened this issue 4 years ago • 11 comments

The app tells me to enable the use of text from screen, however I have it enabled Screenshot_20200213-175336 Screenshot_20200213-175330

Galo223344 avatar Feb 13 '20 20:02 Galo223344

That's interesting. The fact is, in your case, the operating system delivers an empty view hierarchy. Normally it happens when the assist app has no access to the "text from screen". This is why it is advised to verify the assist app settings.

However, it's quite hard to answer, why it happens in your case.

Could you please share more information?:

  • What device do you use (model, android version)?
  • Did you try to inspect other apps? Does the "Screen data isn't available" appears always, for any inspected app, or only for a specific one?

jwisniewski avatar Feb 13 '20 21:02 jwisniewski

I'm using a Xiaomi MI A1 running Android 9 rooted with Magisk. This happens on every app, not a specific one

Galo223344 avatar Feb 13 '20 21:02 Galo223344

The only possibility I see is the fact, the operating system has been modified by Magisk. I'm not familiar with this rooting solution, it is really hard for me to tell something more.

To be honest, I'm focused on support of not rooted devices. Plain devices have multiple constrains but also multiple well established functionalities, Developer Assistant is aligned to that. To work in this environment.

I must say, testing on rooted devices is not my priority. There is just too many cases to handle with official Android distributions.

In case you made any purchase in the app, please contact me via support(at)appsisle.com, sending your order ID, I will refund the purchase of course:)

jwisniewski avatar Feb 14 '20 20:02 jwisniewski

Although I don't think that the issue is being caused by Magisk I understand what you mean and I'd understand if you want to close this issue, however please take a look at what I found while checking the logcat. This appears the first time the app gets called using the home button Screenshot_20200214-175747~2

Galo223344 avatar Feb 14 '20 21:02 Galo223344

just in case i had a time that the app wasn't able to see the text... i found that sometimes the settings show that there active but there not, have you turned off the settings and reactivated them?

On Fri, Feb 14, 2020, 2:14 PM Jaroslaw Wisniewski [email protected] wrote:

The only possibility I see is the fact, the operating system has been modified by Magisk. I'm not familiar with this rooting solution, it is really hard for me to tell something more.

To be honest, I'm focused on support of not rooted devices. Plain devices have multiple constrains but also multiple well established functionalities, Developer Assistant is aligned to that. To work in this environment.

I must say, testing on rooted devices is not my priority. There is just too many cases to handle with official Android distributions.

In case you made any purchase in the app, please contact me via support(at) appsisle.com, sending your order ID, I will refund the purchase of course:)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/jwisniewski/android-developer-assistant/issues/4?email_source=notifications&email_token=ANFRY76OZMSSPJVTCTEPPCDRC33SDA5CNFSM4KU2X4O2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEL2JTHI#issuecomment-586455453, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANFRY7ZQ5PNTYCLUB2F2ZXLRC33SDANCNFSM4KU2X4OQ .

JohnholderStl avatar Feb 14 '20 22:02 JohnholderStl

Yep. Tried several times

Galo223344 avatar Feb 15 '20 00:02 Galo223344

@Galo223344 Thanks for the report related to the requestLayout(), I will verify it. However this won't help with our issue in any way.

Basing on the input from @JohnholderStl (thanks for that!) I will update the screen, which additional suggestion to try to deactivate and activate the "Use text from screen" switcher to verify if it will help in case user sees it activated but still no views information delivered by the operating system.

@Galo223344 for you case, I would like to help, however it's hard to propose something useful, the app has a simple "if statement", if the operating system returned NO views, which could be analyzed by the app, then it shows the UI you have experienced. Normally, during my tests it happened only if user didn't activate the "Use text from screen". Even if the app wouldn't display this screen, we would still have the issue: no data to present on screens displayed instead.

If you would be interested, the exact API I'm mentioning is: https://developer.android.com/reference/android/app/assist/AssistStructure.html#getWindowNodeCount()

I believe, on your device, this method returns 0. Thus the app has no windows to iterate through to collect information on their views.

I will keep this issue open and try to reproduce the case somehow, but I wonder if I will be able to help.

jwisniewski avatar Feb 16 '20 11:02 jwisniewski

The only possibility I see is the fact, the operating system has been modified by Magisk. I'm not familiar with this rooting solution, it is really hard for me to tell something more.

To be honest, I'm focused on support of not rooted devices. Plain devices have multiple constrains but also multiple well established functionalities, Developer Assistant is aligned to that. To work in this environment.

I must say, testing on rooted devices is not my priority. There is just too many cases to handle with official Android distributions.

In case you made any purchase in the app, please contact me via support(at)appsisle.com, sending your order ID, I will refund the purchase of course:)

It's 100% not magisk, Magisk is a systemless root binary so a Non-root app shouldn't even be effected unless he installed some sort of magisk module that effects the app directly; which is unlikely. Most likely it's just his ROM (MIUI) which is notorious for being a pain in the ass for developers because they don't like to stick to the standard.

Example : I have Magisk Root on my OnePlus 6T with Android 10 (OOS ROM) and can use your app just fine.

gghhkm avatar Nov 24 '20 20:11 gghhkm

Although I don't think that the issue is being caused by Magisk I understand what you mean and I'd understand if you want to close this issue, however please take a look at what I found while checking the logcat. This appears the first time the app gets called using the home button Screenshot_20200214-175747~2

Try disabling MIUI Optimization in developer settings.

gghhkm avatar Nov 24 '20 20:11 gghhkm

In my case the reason was SmaliPatcher Magisk module for bypassing secure flag. I disabled the module, rebooted, then the application started working correctly.

vellrya avatar May 15 '22 22:05 vellrya

That's very likely the reason why it didn't work for me. When I originally reported the bug I also had the smali patcher applied.

El dom., 15 may. 2022 19:11, vellrya @.***> escribió:

In my case the reason was SmaliPatcher Magisk module for bypassing secure flag. I disabled the module, rebooted, then the application started working correctly.

— Reply to this email directly, view it on GitHub https://github.com/jwisniewski/android-developer-assistant/issues/4#issuecomment-1127060473, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALCPNHM77FZV62KWOHBDVUTVKFZABANCNFSM4KU2X4OQ . You are receiving this because you were mentioned.Message ID: @.***>

Galo223344 avatar May 16 '22 07:05 Galo223344