ocastastudios / web-reader

Desktop version of the Electricomics Reader
Other
5 stars 1 forks source link

Profiling Performance of Electricomics in Web & iPad readers #1

Open DaveTheCrane opened 8 years ago

DaveTheCrane commented 8 years ago

Hi Ben & all,

A user of the system (Tzvi Lebetkin of Biblicalcomix) reported problems with a comic he'd made crashing on his device (ipad air 2, 2GB ram, ios 9.3.3). I picked it up to have a quick look... Raising this against the webreader project as the ipad reader isn't on github AFAICT

What I'd hoped to do was use the safari remote debugger tools to inspect or profile the comic while it was being played/viewed/consumed or whatever. It recognised my ipad, but I get "no inspectable applications" on the menu with either the ipad app or the desktop viewer running. I presume that both apps are running a webview of some sort (I know from talking to the Ocasta folk previously that the app's not cordova, but a native app with a uiwebview embedded to play the comics)

I don't know enough about ios development to know whether I ought to be able to see something or not, I'm just following the steps I use to debug cordova apps on-device. Am I not doing something I should be doing? Is it possible to switch on "debuggability" of the webview components in a future version? (Safari 9.0.3 on El Capitan)

Quick google suggests it'll only let me debug into apps that I sideload onto the ios device via xcode, is that right?

Two questions come out of this, I suppose: 1) is there a known mechanism/procedure for profiling memory usage of the ipad app that comic creators/developers can use right now? 2) has Ocasta got any existing "load test" data or guidance on the biggest comics a device will support? I'm guessing that the comic crashed on Tzvi's device because it ran out of RAM (it played fine on my 16GB ipad) - so I'm wary that anything big that I make on my newer ipad won't play on older models.

Not sure how it crashed, what the symptoms were, I'll try to find out from Tzvi...

thanks in advance

Dave

bencollier commented 8 years ago

Hi Dave,

Apple doesn't let you debug production apps whether we've turned on debuggablity or not. The easiest way is to run a local web server in the project directory and point Safari on the iPad to it - you'll then be able to debug it. If you're using the Generator it does this for you - http://127.0.0.1:8123/1-electricomic/#/step/step-1

We're using the WKWebView instead of UIWebView which gives faster performance and larger memory allocation.

We can't see any crashes coming in our logs though... One problem could be the iPad lacking free storage space. If you check Settings -> General -> Storage & iCloud Usage to see if there's any free space on the device. Often if it's zero or close apps can randomly crash.