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
Loading local files broken since 11.22.0
on Android (net::ERR_ACCESS_DENIED
)
#2723
Comments
11.22.0
on Android11.22.0
on Android (net::ERR_ACCESS_DENIED
)
Can you share a repro? I tried a quick test and it was working for me. |
Here's a repro for the issue: https://github.com/jacobpenny/webview-file-uri-repro This code works fine on 11.21.2. |
Thanks for the repro! This is interesting, it does look like you found a real regression. It seems the order in which properties are specified on a component matters! It was processing the (I'm not certain, but I'm guessing my previous test might have worked by initializing |
For what its worth, i've been battling with this issue for 2 days now, dropping back to older versions has not fixed the issue either, we did however upgrade to React Native Issue is as the ticket describes, we write out a HTML file to the file system before loading it into a webview on Android (we don't do this for iOS as we're able to pass in raw HTML) We get this error on Android thrown back and a blank webview
I've now tried rebuilding with a half dozen different webview versions going back to 11.17. Same issue. Manifest includes
Webview options
One thing I have noticed is that it will SOMETIMES work.. Like, maybe once every 20 errors.. So, it makes me think there is no actual permission error, there's a race condition somewhere.. We've tried delaying rendering etc, to make sure there wasn't a race condition after writing the file, but there's not, and the file write out just fine as we've inspected. There's something funky going on elsewhere We've basically had to push forward releasing our IOS app and holding back the Android one due to this.. Everything works fine on Apple devices. We're too far down the hole to roll back the major React Native upgrade. Any advice would be greatly appreciated |
@cheynewallace If dropping back to older versions hasn't helped then I think you might be seeing a different issue. There was a very clear regression in The repro that @jacobpenny shared, which worked with previous versions of My other advice would be to attach Android Studio to try debugging it yourself. I can tell you that in the case of this original issue, I could see in the debugger that |
Thanks for getting back to me @TheAlmightyBob, that all makes sense, I managed to get around it by doing a combination of rolling back to Its odd, because that render race condition issue appears quite old, however we've been using this library for a few years and never seen it until now (we were previously on 11.16). We upgraded a few other packages that had to go along with the 0.70 update as well, so maybe something there tripped it over, hard to say, we're just playing dependency jenga right now. Anyway, our Android app looks more lively for now.. I'll keep an eye out for updates on that regression and the PR you submitted. Thanks again for your help and quick response 👍 |
@cheynewallace Thank you for linking that other issue, I was unaware of it. Very interesting... in my testing via @jacobpenny's repro, the order of properties in the JSX seemed to clearly determine the order in which they were applied in native code. But it seems you and others may have found that's not always the case? If you could spare the time, I'd be curious if running @jacobpenny's repo with I think I'm going to keep #2766 focused on just reverting the simple regression, but it would be good to understand how props are applied... |
@TheAlmightyBob Sure, I just pulled down the repro repo above, here's few things i found
Here's some example code for
|
Curious. Thanks for the info. |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
Reopening because #2766 has not been merged yet |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
This comment helped me for a temporary solution. |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
'sup bot, please keep this open... unfortunately #2766 ran into some issues after the new architecture refactor... |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
Hi, Any luck on solution here? |
Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
When it is going to be fixed? Any idea? |
Bug description:
Since version
11.22.0
, it is not possible anymore to load a uri pointing to the file system on Android. The WebView shows an error message.This
leads to this
I am aware of the
allowFileAccess
setting and have set it to true.It works fine on version
11.21.2
.Expected behavior:
Uris pointing to file system should load without error.
Environment:
The text was updated successfully, but these errors were encountered: