Mantano / iridium

Unofficial Dart/Flutter port of some of the Readium 2 components
80 stars 27 forks source link

ERR_UNSAFE_PORT when opening book #106

Open carman247 opened 10 months ago

carman247 commented 10 months ago

Occasionally I get a blank WebView screen with the message ERR_UNSAFE_PORT

I think the IP and port it's trying to use are 127.0.0.1:4045

jmgeffroy commented 10 months ago

Hello @carman247, can you please try to deactivate the use HTTP server? This can be done by changing the default value here: https://github.com/Mantano/iridium/blob/fcc2e2e690276e2a1ce412d3c15ee813b7c13354/components/navigator/lib/src/publication/publication_controller.dart#L43-L43 It could be a good idea to search for places where this might be explicitly given a different value. Please let me know if it works or not. I haven't tested on iOS for a while, and right now today, I can't.

carman247 commented 10 months ago

Ok, will this affect performance at all? I'll test it and see if the problem continues to occur.

By the way, I was testing on an Android 13 device.

jmgeffroy commented 10 months ago

Not at all. In fact, we had implemented this optimization in our (unpublished) Mantano Reader app, which was written in Java/Kotlin, and it improved the performances very signicantly. With our Flutter/Dart implementation we expected similar gains, but we found no measurable difference, which is strange and should be investigated one of these days. However, we feel that for now the performances are good enough and we should focus on other stuff. Don't hesitate sharing your observations.