RESOLVED FIXED 126626
Stub for WebSession API
https://bugs.webkit.org/show_bug.cgi?id=126626
Summary Stub for WebSession API
Martin Hock
Reported 2014-01-08 00:38:51 PST
Stub for WebSession API
Attachments
patch (28.31 KB, patch)
2014-01-08 00:40 PST, Martin Hock
no flags
rebase + style fixes (32.35 KB, patch)
2014-01-08 00:49 PST, Martin Hock
no flags
ChangeLog (27.06 KB, patch)
2014-01-08 01:03 PST, Martin Hock
sam: review+
address comments (26.97 KB, patch)
2014-01-08 10:38 PST, Martin Hock
eflews.bot: commit-queue-
rebase (27.00 KB, patch)
2014-01-08 11:08 PST, Martin Hock
no flags
add reviewer (27.00 KB, patch)
2014-01-08 11:15 PST, Martin Hock
no flags
move Session to API namespace (27.08 KB, patch)
2014-01-08 12:32 PST, Martin Hock
no flags
style (27.08 KB, patch)
2014-01-08 12:34 PST, Martin Hock
no flags
Martin Hock
Comment 1 2014-01-08 00:40:12 PST
Martin Hock
Comment 2 2014-01-08 00:49:59 PST
Created attachment 220605 [details] rebase + style fixes
Martin Hock
Comment 3 2014-01-08 01:03:35 PST
Created attachment 220606 [details] ChangeLog
WebKit Commit Bot
Comment 4 2014-01-08 01:06:38 PST
Attachment 220606 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebKit2/ChangeLog', u'Source/WebKit2/Shared/API/c/WKBase.h', u'Source/WebKit2/Shared/API/c/WKSharedAPICast.h', u'Source/WebKit2/Shared/APIObject.h', u'Source/WebKit2/UIProcess/API/C/WKSessionRef.cpp', u'Source/WebKit2/UIProcess/API/C/WKSessionRef.h', u'Source/WebKit2/UIProcess/API/Cocoa/WKSession.h', u'Source/WebKit2/UIProcess/API/Cocoa/WKSession.mm', u'Source/WebKit2/UIProcess/API/Cocoa/WKSessionInternal.h', u'Source/WebKit2/UIProcess/WebSession.cpp', u'Source/WebKit2/UIProcess/WebSession.h', u'Source/WebKit2/WebKit2.xcodeproj/project.pbxproj', '--commit-queue']" exit_code: 1 ERROR: Source/WebKit2/UIProcess/WebSession.h:27: WebSession_h is incorrect. #defined constants should use all uppercase names with words separated by underscores. [readability/naming/define/constants] [4] Total errors found: 1 in 12 files If any of these errors are false positives, please file a bug against check-webkit-style.
Martin Hock
Comment 5 2014-01-08 01:14:36 PST
I don't understand this style error as it seems to follow the style guidelines for header guards. Am I missing something? (In reply to comment #4) > Attachment 220606 [details] did not pass style-queue: > > Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebKit2/ChangeLog', u'Source/WebKit2/Shared/API/c/WKBase.h', u'Source/WebKit2/Shared/API/c/WKSharedAPICast.h', u'Source/WebKit2/Shared/APIObject.h', u'Source/WebKit2/UIProcess/API/C/WKSessionRef.cpp', u'Source/WebKit2/UIProcess/API/C/WKSessionRef.h', u'Source/WebKit2/UIProcess/API/Cocoa/WKSession.h', u'Source/WebKit2/UIProcess/API/Cocoa/WKSession.mm', u'Source/WebKit2/UIProcess/API/Cocoa/WKSessionInternal.h', u'Source/WebKit2/UIProcess/WebSession.cpp', u'Source/WebKit2/UIProcess/WebSession.h', u'Source/WebKit2/WebKit2.xcodeproj/project.pbxproj', '--commit-queue']" exit_code: 1 > ERROR: Source/WebKit2/UIProcess/WebSession.h:27: WebSession_h is incorrect. #defined constants should use all uppercase names with words separated by underscores. [readability/naming/define/constants] [4] > Total errors found: 1 in 12 files > > > If any of these errors are false positives, please file a bug against check-webkit-style.
Alexey Proskuryakov
Comment 6 2014-01-08 09:43:44 PST
> I don't understand this style error as it seems to follow the style guidelines for header guards. Am I missing something? This is a newly introduced mistake in style checker, will roll out in bug 126645.
Sam Weinig
Comment 7 2014-01-08 09:53:31 PST
Comment on attachment 220606 [details] ChangeLog View in context: https://bugs.webkit.org/attachment.cgi?id=220606&action=review With those changes, r=me. > Source/WebKit2/UIProcess/API/Cocoa/WKSession.h:26 > +#include <WebKit2/WKSessionRef.h> This should not be included. It is in some of the objective-c headers as a temporary renaming mitigation. > Source/WebKit2/UIProcess/API/Cocoa/WKSession.h:28 > +#ifdef __OBJC__ This is also not needed. > Source/WebKit2/UIProcess/WebSession.h:37 > + bool getEphemeral(); This should be called either isEphemeral() or just ephemeral() (I prefer the isEphemeral()).
Martin Hock
Comment 8 2014-01-08 10:38:45 PST
Created attachment 220642 [details] address comments
EFL EWS Bot
Comment 9 2014-01-08 10:58:56 PST
Comment on attachment 220642 [details] address comments Attachment 220642 [details] did not pass efl-wk2-ews (efl-wk2): Output: http://webkit-queues.appspot.com/results/5178054582206464
Martin Hock
Comment 10 2014-01-08 11:08:08 PST
Martin Hock
Comment 11 2014-01-08 11:15:59 PST
Created attachment 220645 [details] add reviewer
Anders Carlsson
Comment 12 2014-01-08 11:23:02 PST
Comment on attachment 220645 [details] add reviewer Here are some high-level comments I though of yesterday: - WKSession is a very generic and non-descriptive name. I think it should be named to reflect what type of session it is. - I had to look up what ephemeral meant, and I suspect other developers that aren't fluent in english will have to do so too. Maybe we can come up with a better name? - I think the C++ object should be in the API namespace.
Sam Weinig
Comment 13 2014-01-08 11:31:40 PST
(In reply to comment #12) > (From update of attachment 220645 [details]) > Here are some high-level comments I though of yesterday: > > - WKSession is a very generic and non-descriptive name. I think it should be named to reflect what type of session it is. In the end, I think the WKSession should have all the session specific information: - Cookies - Caches - Local Storage - Databases - Etc. > - I had to look up what ephemeral meant, and I suspect other developers that aren't fluent in english will have to do so too. Maybe we can come up with a better name? - This is the name CFNetwork uses. I think it is quite good :(. > - I think the C++ object should be in the API namespace. Yeah, it should.
Martin Hock
Comment 14 2014-01-08 11:54:53 PST
(In reply to comment #13) > (In reply to comment #12) > > - I think the C++ object should be in the API namespace. > Yeah, it should. So WebSession should be in namespace API instead of namespace WebKit? I'm not sure how this makes sense because API classes tend to be abstract concepts like Array, Number, Object, etc and the names all start with "API". Should I give WebSession the same treatment?
Anders Carlsson
Comment 15 2014-01-08 11:59:27 PST
(In reply to comment #14) > (In reply to comment #13) > > (In reply to comment #12) > > > - I think the C++ object should be in the API namespace. > > Yeah, it should. > > So WebSession should be in namespace API instead of namespace WebKit? I'm not sure how this makes sense because API classes tend to be abstract concepts like Array, Number, Object, etc and the names all start with "API". We've started using the API namespaces for objects that are exposed as API. Right now that means most of the abstract objects but we're moving more of the Web* classes over to API*. > Should I give WebSession the same treatment? Yes.
Martin Hock
Comment 16 2014-01-08 12:32:43 PST
Created attachment 220652 [details] move Session to API namespace
Martin Hock
Comment 17 2014-01-08 12:34:10 PST
WebKit Commit Bot
Comment 18 2014-01-08 19:57:50 PST
Comment on attachment 220653 [details] style Clearing flags on attachment: 220653 Committed r161542: <http://trac.webkit.org/changeset/161542>
WebKit Commit Bot
Comment 19 2014-01-08 19:57:53 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.