**** BEGIN LOGGING AT Sat Sep 05 02:59:58 2015 Sep 05 05:22:46 morning Sep 05 05:26:41 Tofe: After I install the "Les Echos" app, it starts with a white screen (after the splash). When I close the app, afterwards power menu is broken. I pulled the log, anything obvious in there? https://bpaste.net/show/6fd4cd5f0885 Sep 05 05:29:50 This is one where power menu works. https://bpaste.net/show/c655414fe40c Sep 05 05:30:11 Seems that luna-webappmanager somehow doesn't come up for luna-systemui in the "broken" example? Sep 05 08:47:53 Morning Sep 05 08:48:19 Herrie: btw, "The main window of app "fr.lesechos.tabletapp" was closed, so closing all child windows too" this kind of behavior can explain why the weather dashboard gets closed Sep 05 08:53:02 Herrie: void luna::WebApplicationWindow::onStageReadyTimeout() This is never a good thing. Reaching this timeout means we are going to show the app, even if things are not even properly configured (appId, parent window, etc). Sep 05 09:35:01 I have found a few others that also don't work Sep 05 09:35:10 Would it be helpful to have those logs as well? Sep 05 10:07:52 Tofe: I think for this one we would need to set a dynamic DB quota? Sep 05 10:07:53 https://bpaste.net/show/ee30a6569236 Sep 05 10:09:13 currentQuota: 5242880, expectedUsage: 31457280 Sep 05 10:45:31 Herrie: I don't know how to do that :p Sep 05 10:54:26 Tofe: Let me check app source code to see what it does Sep 05 10:54:47 I have 3 apps that lock and don't launch when you're connected to internet and breaks power stuff Sep 05 10:55:01 But when not connected they're OK and don't break power stuff Sep 05 10:55:20 So I guess we'd need to somehow detect unsuccessfull launches and make sure they get dealt with properly Sep 05 10:55:26 I can provide you IPK's ;) Sep 05 11:04:31 Tofe: OK I think I found it ;) Sep 05 11:04:44 https://bpaste.net/show/86982f407f8f Sep 05 11:04:48 The app requests 30MB Sep 05 11:05:59 I think in https://github.com/webOS-ports/luneos-components/blob/master/modules/LuneOS/Components/LunaWebView.qml#L113 we should check if model.expectedUsage > 5 * 1024 * 1024, if true use model.expectedUsage else the 5*1024*1024? Sep 05 11:47:05 So we give no limit at all? Sep 05 12:02:42 Well the app determines the limit? Sep 05 12:02:48 It seems that legacy was OK with that? Sep 05 12:03:05 DougReeder might know more? Sep 05 12:03:23 We might limit it at 64MB? Sep 05 12:06:55 Legacy allowed the 30MB for sure it seems ;) Sep 05 12:07:06 Not sure there was a hard limite Sep 05 12:21:16 Tofe: The actual problem might be SecurityError: DOM Exception 18: An attempt was made to break through the security policy of the user agent. instead Sep 05 12:21:29 Seems we might need to set some local path to bypass this? https://bugreports.qt.io/browse/QTBUG-32905 Sep 05 12:44:44 That might actually explain why DougReeders db gets deleted after app lifecycle? Sep 05 13:42:31 Herrie: You're right, the fix proposed by Qt is needed Sep 05 13:46:54 (it's not really a fix, it's more a good practice) Sep 05 14:17:12 Not sure how to do that though Sep 05 14:17:34 Seems we need to add this somewhere? http://doc.qt.io/qt-5/qqmlengine.html#offlineStoragePath-prop Sep 05 14:21:31 I propose in here https://github.com/webOS-ports/luna-webappmanager/blob/master/src/webapplicationwindow.cpp#L153 Sep 05 14:22:44 But what storage path to choose ? Don't we need something more permanent than /tmp ? Sep 05 14:23:23 Tofe: Not sure what legacy uses... I think somewhere inside /media/internal/ Sep 05 14:42:34 Let me see if I can find out on legacy Sep 05 16:00:52 Herrie: sorry, couldn't have it working to far: https://github.com/webOS-ports/luna-next-cardshell/commit/9f602f283fdd3dc5b396d70404294e46bd621c33 Sep 05 16:01:44 Better to have it commented out currently, current code might interfere with in-app gestures Sep 05 16:49:23 Tofe: Papermache creates a folder called .app-storage inside /media/internal Sep 05 16:49:37 There I have file_.media.cryptofs.apps.usr.palm.applications.net.ryanwatkins.app.papermache_0 folder Sep 05 16:49:55 With a sqlite file called 0000000000000002.db Sep 05 16:52:27 So it's not unified? Sep 05 16:56:03 Tofe i'm not sure really Sep 05 16:56:15 This is all pretty much in legacy binaries I guess Sep 05 16:58:36 I'm a bit worried if web apps can so easily put their mess wherever they want Sep 05 16:59:40 Tofe: Well /media/internal is user writable Sep 05 16:59:50 I found a bash script in 3.0.5. Doctor: https://bpaste.net/show/804922bdfec4 Sep 05 17:00:10 See line 173: # Erase all content on media drive except for palm applications Sep 05 17:00:59 /media/internal/.palm|/media/internal/.app-storage Sep 05 17:01:22 ok, I find .app-storage pretty nice Sep 05 17:01:40 We settle for this? Sep 05 17:01:59 I guess Sep 05 17:02:10 Let me do a few mins more digging Sep 05 17:02:30 Found a libWebKitLuna.so with some references to app-storage as well Sep 05 17:02:36 Might have been open sourced Sep 05 17:08:32 https://github.com/webOS-ports/luna-webappmanager/pull/31 eventually, not yet tested Sep 05 17:08:58 seems related http://www.webos-internals.org/wiki/MojoDB_Partition_Resize Sep 05 17:10:53 nizovn: DB8 = internal DB Sep 05 17:11:07 We're talking extern SQLite etc DB's here created by apps ;) Sep 05 17:11:18 DB8 size is limited to 1MB for the app I think Sep 05 17:12:10 ah, ok, understood Sep 05 17:13:38 We're just trying to figure out where these are stored and what the limits are Sep 05 17:14:18 Tofe: https://github.com/webOS-ports/org.webosinternals.saverestore/blob/93f0bce8c3528656811c742b86019745adaa7eaf/scripts/srf.app.databases#l9 Sep 05 17:16:41 aha, interesting Sep 05 17:17:00 APPSTORE=/media/internal/.app-storage Sep 05 17:17:33 I'm still slightly completely lost Sep 05 17:21:25 Tofe yeah Sep 05 17:21:37 Well I cannot find anything in OWO github for this Sep 05 17:26:38 seems /media/internal/.app-storage is the most appropriate for now Sep 05 17:31:41 ok Sep 05 17:32:53 Tofe: This seem to confirm: https://www.linkesoft.com/secret/webos.html Sep 05 17:33:02 "Secret! data is stored (encrypted) in a hidden directory /.app-storage/file_.media.cryptofs.apps.usr.palm.applications.com.linkesoft.secret_0." Sep 05 17:33:55 I found similar references for other apps Sep 05 17:36:17 Tofe: Did you test your PR for compilation at least? Sep 05 17:36:47 Herrie: not even, no Sep 05 17:36:51 I'll do that :p Sep 05 17:37:10 Hehe;) Sep 05 17:37:17 If it compiles I guess we can put it Sep 05 17:37:24 If you have an IPK I'm happy to test as well ;) Sep 05 17:37:30 I have the apps IPK laying around here Sep 05 17:37:49 in 5min should be ready Sep 05 17:38:19 on my tp there is only one app db directory in .app-storage, 4 in /var/palm/data and 9 in /var/palm/data/localstorage Sep 05 17:38:57 nizovn: Hmmmmz Sep 05 17:40:46 https://dl.dropboxusercontent.com/u/4679068/luna-next/luna-webappmanager_0.2.0-8%2Bgit2%2Bd458383343-r0.2_armv7a-vfp-neon.ipk Sep 05 17:40:59 (meaning also that it builds fine) Sep 05 17:46:13 Tofe: https://github.com/isis-project/WebKitSupplemental/blob/f41ad2e1a0e2f700bd8ee295ab154891e692bcba/misc/weboswebsettings.cpp#l137 Sep 05 17:50:32 Ah, you've got a point here... Sep 05 17:51:12 Seems we might need 2 paths? Sep 05 17:51:25 Or even 3 ;) Sep 05 18:17:22 This is for browser, but I guess we should have similar for apps Sep 05 18:27:11 Seems OfflineStorageDatabaseEnabled might not be available in QML or was deprecated between QT 4.x and 5.x ? Sep 05 18:29:10 I guess this is what we were looking for: https://github.com/openwebos/webappmanager/blob/d5d40487cc28bcf15ed2cc836b78de56920da22f/Src/webbase/SysMgrWebBridge.cpp#l496 Sep 05 19:04:47 Tofe: I get Sep 05 15:01:55 mako LunaWebAppManager[1508]: WARNING: 15:01:55.136: qrc:///qml/ApplicationContainer.qml:158: TypeError: Cannot read property 'scheme' of undefined with your IPK Sep 05 19:04:58 YOu sure you have your other fix in there? Sep 05 19:28:24 mmmmmmh nope, it's not in here Sep 05 19:29:05 Tofe: That explains :P Sep 05 19:29:30 give me 5min Sep 05 19:29:48 Sure ;) Sep 05 19:29:57 Did you see my SysMgrWebBridge above? Sep 05 19:30:37 yes Sep 05 19:30:44 While you're at it you can just as well add the 2nd path I guess Sep 05 19:31:15 which is ? Sep 05 19:32:24 I see a getenv("PERSISTENT_STORAGE_PATH"); Sep 05 19:32:42 setLocalStoragePath(QString("%1/LocalStorage").arg(storagePath)); Sep 05 19:33:01 Herrie: https://dl.dropboxusercontent.com/u/4679068/luna-next/luna-webappmanager_0.2.0-8%2Bgit2%2Bd458383343-r0.3_armv7a-vfp-neon.ipk Sep 05 19:39:22 Tofe: The error is gone but app still doesn't work :P Sep 05 19:40:59 I'm not sure how to set the local storage path Sep 05 19:43:03 Ah seems it's not in the QQmlEngine? Sep 05 19:43:23 nope Sep 05 19:43:28 it's for a QWebPage Sep 05 19:44:08 Yeah Sep 05 19:44:09 http://doc.qt.io/qt-5/qtquick-localstorage-qmlmodule.html Sep 05 19:44:29 Seems that it uses offlineStoragePath as well Sep 05 19:51:35 ok, well, so the mystery remains. Sep 05 19:52:10 I'll still a better status than before the PR Sep 05 19:52:19 Yeah Sep 05 20:01:43 Tofe: I'll merge it and run a nightly. You have anything pending you'd like to have in the release for this month? Sep 05 20:01:56 If not I guess I'll build the stable after this nightly Sep 05 20:03:15 no, that's fine Sep 05 20:03:39 and I begin to think that for some bugs we'd better try out WebEngine from qt 5.5 Sep 05 20:03:57 like for zoom gestures Sep 05 20:06:28 Tofe: Yeah Sep 05 20:06:57 For the DB max size, you have objections against this: model.accept((model.expectedUsage > (5 * 1024 * 1024)) ? (model.expectedUsage > (64*1024*1024)) ? (64 * 1024 * 1024) : model.expectedUsage : (5 * 1024 * 1024)); Sep 05 20:07:41 So If the expectedUsage > 5MB, use it when < 64MB, else max to 64MB. Otherwise regular max of 5MB Sep 05 20:09:34 Looks good Sep 05 20:12:13 Just to be a bit more flexible compared to the hard 5MB limit **** ENDING LOGGING AT Sun Sep 06 02:59:58 2015