Closed Kagee closed 1 month ago
Hm, well, looking at the video, I can tell there is something happening at the first (successful but not returning) scan (in case 4) because the screen gets black for a short moment. This means the camera was closed and re-opened. So I guess the Intent
to open the return URL (here) was indeed started but somehow failed 🤔
Obviousely, the return URL is registered with the PWA because otherwise it wouldn't open on the second scan. So I'm really a bit puzzled…
For testing: https://pwa-test.h2x.no/ - i can replicate the problem with this bare-bones setup. The app is just a web page with two Binary Eye links that prints the GET, POST and HTTP header data.
If the PWA install box does not pop up, in Chrome, do "Add to home screen". Instead of "Addo to home screen" it should suggest "Install app".
I can, annoyingly enough, not replicate this on a Pixel 7 emulator. I had to upgrade Chrome on the emulator image for the PWA to install properly, if not it was just added as a homescreen shortcut. Uou can see the difference because homescreen shortscuts hav a chrome icon in the corner.
And, following that revelation, reisntalling Binary Eye on the actual device appears to have fixed the issue. I would assume some setting or other that i at some time changed in Binary Eye was at fault? 🤔 However, when comparing the settings from the video with the current, apparently working settings on the same phone, i see no difference.
Also possible Chrome updated between now and then, can't really verify since i didn't note version numbers of Chrome. Also can't find any related bugs or changes in recent Chrome for Android.
That's interesting! Frankly, I still have no idea what could have been the reason, and that the bug just vanished with a fresh installation of Binary Eye is surprising. But good to know! Thanks a lot for reporting! 👍
I would assume some setting or other that i at some time changed in Binary Eye was at fault?
I really doubt that, too. There's no preference that would have any effect on starting this Intent
.
Also possible Chrome updated between now and then, can't really verify since i didn't note version numbers of Chrome. Also can't find any related bugs or changes in recent Chrome for Android.
Maybe 🤷♂️
I'm trying to use Binary Eye from a PWA (installed web app, what internally apparently called "webapk" in Android). I intend to have the scan returned as a call to the PWA, so the url is as follows:
binaryeye://scan?ret=https%3A%2F%2Fscan.h2x.no%2Fscan%3Fresult%3D{RESULT}
When i open the intent from Chrome, Binary Eye scans the code, and opens the return URL, thus triggering Android to open the PWA. The value is successfully captured by the PWA (since it is just a web page that now has a query value). This is the expected flow, and also what i would expect when starting the flow from the PWA.
However, when i open the intent from inside the PWA, I have to scan the code twice before the PWA opens with the result. Based on that i do not see any web requests for the PWA before after the second scan, i belive this is Binary Eye not opening the return url, and not the PWA restarting the scan/intent.
The web page is not avaliable without login, but i can set up an public example if required. I do not belive the login is at fault, since the PWA opens just fine if the scan chain was started in Chrome.
This https://photos.app.goo.gl/1o51uWEtHGgM3WXM9 video shows the following
Google Pixel, Android 14