Re: [DISCUSSION] WICKET-6544 mobile browser detection
+1 remove it Martijn On Sat, Jun 23, 2018 at 3:07 PM Martin Grigorov wrote: > > Then maybe we should deprecate the user agent related code in Wicket 8/9 > and drop it later ? > ... and show the users how they can use 3rd party libs like this one for > such needs. > > On Sat, Jun 23, 2018 at 3:57 PM Sven Meier wrote: > > > Hi, > > > > my stance hasn't changed: > > > > I'm not in favor to add a dependency to a library which > > > > - updates frequently to adjust to browser developments > > - introduces a singleton bottleneck > > - can't be excluded from dependencies > > - is hidden behind an age-old API Wicket API (UserAgent) ... > > - ... which won't be sufficient to many people anyways > > > > .. just to save someone a single line of code passing the user agent > > string to the library himself. > > > > Have fun > > Sven > > > > > > Am 22.06.2018 um 14:37 schrieb Tobias Soloschenko: > > > I think we should turn off the gatherExtendedBrowserInformation by > > default and give a hint that there is a synchronisation point of 0,011 ms > > when turned on, but the detection is much more reliable with the new > > implementation. > > > > > > kind regards > > > > > > Tobias > > > > > >> Am 22.06.2018 um 11:49 schrieb Maxim Solodovnik : > > >> > > >> Is it time to resume this discussion? > > >> We still have PR unmerged, and don't have agreement what to do next :( > > >> > > >> On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < > > >> tobiassolosche...@googlemail.com> wrote: > > >> > > >>> :-D > > >>> > > >>> kind regards > > >>> > > >>> Tobias > > >>> > > Am 09.04.2018 um 19:14 schrieb Sven Meier : > > > > bike shed :P > > > > Sven > > > > > > > Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: > > > This topic is more active than the release one :) > > > > > > On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko > > > wrote: > > >> -1 for dropping agent detection > > >> +1 for adding a dependency to an external library (because of the > > big > > >>> pool of browsers - which might increase in future) > > >> kind regards > > >> > > >> Tobias > > >> > > >>> Am 05.04.2018 um 13:44 schrieb Sven Meier : > > >>> > > >>> +0 for dropping agent detection (3) > > >>> -1 for adding a dependency to an external library > > >>> > > >>> Sven > > >>> > > >>> Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < > > >>> solomax...@gmail.com>: > > It seems the discussion is spread between this thread and the JIRA > > > > >>> > > https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > > As far as I can see we don't have consensus if this feature should > > 1) remain as is (drop PR) > > 2) be improved (merge PR and/or enhance detection) > > 3) browser detection should be dropped? > > > > I would vote for option 2+ :) > > > > On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < > > >>> mgrigo...@apache.org> > > wrote: > > > > > On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < > > > korbinian.ba...@whiskyworld.de> wrote: > > > > > >> - Ursprüngliche Mail - > > even in 2009 it was considered bad: > > https://www.sitepoint.com/why- > > browser-sniffing-stinks/ > > and in case that is not enough, read what the guy that > > invented > > >> modernizr > > has to say: > > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > > how-i-learned-whats-so-bad-about-browser-sniffing/ > > > > > > >>> I do not trust anyone who says "don't do it this way" but > > doesn't > > say > > > how > > >>> to do it! > > >>> > > >>> There are several of "if (isBrowserX()) {...} else {...}" in > > Wicket JS > > >> code > > >>> and they served well for the last decade. > > >>> Since there are several other *Java* libraries for user agent > > detection > > >>> this means that someone still finds them useful despite what > > other > > > people > > >>> claim. > > >> unreliable things wont get reliably by pointing into the past > > and > > then > > >> telling that your fater did it the same way > > >> > > >> nowadays you would use feature detection, see: > > >> > > >> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > > >> testing/Cross_browser_testing/Feature_detection > > > Korbinian, > > > > > > The PR by Maxim is about the User-Agent detection at the *server* > > side, > > > i.e. in the *Java* code. It reads the request header and tells
Re: [DISCUSSION] WICKET-6544 mobile browser detection
okay no problem - lets set it to deprecated. +1 kind regards Tobias > Am 23.06.2018 um 18:11 schrieb Maxim Solodovnik : > > +1 for deprecating > > On Sat, Jun 23, 2018 at 8:07 PM Martin Grigorov > wrote: > >> Then maybe we should deprecate the user agent related code in Wicket 8/9 >> and drop it later ? >> ... and show the users how they can use 3rd party libs like this one for >> such needs. >> >>> On Sat, Jun 23, 2018 at 3:57 PM Sven Meier wrote: >>> >>> Hi, >>> >>> my stance hasn't changed: >>> >>> I'm not in favor to add a dependency to a library which >>> >>> - updates frequently to adjust to browser developments >>> - introduces a singleton bottleneck >>> - can't be excluded from dependencies >>> - is hidden behind an age-old API Wicket API (UserAgent) ... >>> - ... which won't be sufficient to many people anyways >>> >>> .. just to save someone a single line of code passing the user agent >>> string to the library himself. >>> >>> Have fun >>> Sven >>> >>> Am 22.06.2018 um 14:37 schrieb Tobias Soloschenko: I think we should turn off the gatherExtendedBrowserInformation by >>> default and give a hint that there is a synchronisation point of 0,011 ms >>> when turned on, but the detection is much more reliable with the new >>> implementation. kind regards Tobias > Am 22.06.2018 um 11:49 schrieb Maxim Solodovnik >> : > > Is it time to resume this discussion? > We still have PR unmerged, and don't have agreement what to do next :( > > On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < > tobiassolosche...@googlemail.com> wrote: > >> :-D >> >> kind regards >> >> Tobias >> >>> Am 09.04.2018 um 19:14 schrieb Sven Meier : >>> >>> bike shed :P >>> >>> Sven >>> >>> Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: This topic is more active than the release one :) On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko wrote: > -1 for dropping agent detection > +1 for adding a dependency to an external library (because of the >>> big >> pool of browsers - which might increase in future) > kind regards > > Tobias > >> Am 05.04.2018 um 13:44 schrieb Sven Meier : >> >> +0 for dropping agent detection (3) >> -1 for adding a dependency to an external library >> >> Sven >> >> Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < >> solomax...@gmail.com>: >>> It seems the discussion is spread between this thread and the >> JIRA >>> >> >>> >> https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 >>> As far as I can see we don't have consensus if this feature >> should >>> 1) remain as is (drop PR) >>> 2) be improved (merge PR and/or enhance detection) >>> 3) browser detection should be dropped? >>> >>> I would vote for option 2+ :) >>> >>> On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < >> mgrigo...@apache.org> >>> wrote: >>> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: > - Ursprüngliche Mail - >>> even in 2009 it was considered bad: >>> https://www.sitepoint.com/why- >>> browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that >>> invented > modernizr >>> has to say: >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >> I do not trust anyone who says "don't do it this way" but >>> doesn't >>> say how >> to do it! >> >> There are several of "if (isBrowserX()) {...} else {...}" in >>> Wicket JS > code >> and they served well for the last decade. >> Since there are several other *Java* libraries for user agent >>> detection >> this means that someone still finds them useful despite what >>> other people >> claim. > unreliable things wont get reliably by pointing into the past >>> and >>> then > telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the >> *server*
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Then maybe we should deprecate the user agent related code in Wicket 8/9 and drop it later ? ... and show the users how they can use 3rd party libs like this one for such needs. On Sat, Jun 23, 2018 at 3:57 PM Sven Meier wrote: > Hi, > > my stance hasn't changed: > > I'm not in favor to add a dependency to a library which > > - updates frequently to adjust to browser developments > - introduces a singleton bottleneck > - can't be excluded from dependencies > - is hidden behind an age-old API Wicket API (UserAgent) ... > - ... which won't be sufficient to many people anyways > > .. just to save someone a single line of code passing the user agent > string to the library himself. > > Have fun > Sven > > > Am 22.06.2018 um 14:37 schrieb Tobias Soloschenko: > > I think we should turn off the gatherExtendedBrowserInformation by > default and give a hint that there is a synchronisation point of 0,011 ms > when turned on, but the detection is much more reliable with the new > implementation. > > > > kind regards > > > > Tobias > > > >> Am 22.06.2018 um 11:49 schrieb Maxim Solodovnik : > >> > >> Is it time to resume this discussion? > >> We still have PR unmerged, and don't have agreement what to do next :( > >> > >> On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < > >> tobiassolosche...@googlemail.com> wrote: > >> > >>> :-D > >>> > >>> kind regards > >>> > >>> Tobias > >>> > Am 09.04.2018 um 19:14 schrieb Sven Meier : > > bike shed :P > > Sven > > > > Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: > > This topic is more active than the release one :) > > > > On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko > > wrote: > >> -1 for dropping agent detection > >> +1 for adding a dependency to an external library (because of the > big > >>> pool of browsers - which might increase in future) > >> kind regards > >> > >> Tobias > >> > >>> Am 05.04.2018 um 13:44 schrieb Sven Meier : > >>> > >>> +0 for dropping agent detection (3) > >>> -1 for adding a dependency to an external library > >>> > >>> Sven > >>> > >>> Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < > >>> solomax...@gmail.com>: > It seems the discussion is spread between this thread and the JIRA > > >>> > https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > As far as I can see we don't have consensus if this feature should > 1) remain as is (drop PR) > 2) be improved (merge PR and/or enhance detection) > 3) browser detection should be dropped? > > I would vote for option 2+ :) > > On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < > >>> mgrigo...@apache.org> > wrote: > > > On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < > > korbinian.ba...@whiskyworld.de> wrote: > > > >> - Ursprüngliche Mail - > even in 2009 it was considered bad: > https://www.sitepoint.com/why- > browser-sniffing-stinks/ > and in case that is not enough, read what the guy that > invented > >> modernizr > has to say: > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > how-i-learned-whats-so-bad-about-browser-sniffing/ > > > >>> I do not trust anyone who says "don't do it this way" but > doesn't > say > > how > >>> to do it! > >>> > >>> There are several of "if (isBrowserX()) {...} else {...}" in > Wicket JS > >> code > >>> and they served well for the last decade. > >>> Since there are several other *Java* libraries for user agent > detection > >>> this means that someone still finds them useful despite what > other > > people > >>> claim. > >> unreliable things wont get reliably by pointing into the past > and > then > >> telling that your fater did it the same way > >> > >> nowadays you would use feature detection, see: > >> > >> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > >> testing/Cross_browser_testing/Feature_detection > > Korbinian, > > > > The PR by Maxim is about the User-Agent detection at the *server* > side, > > i.e. in the *Java* code. It reads the request header and tells > you > what the > > browser is. > > The JS feature detection is only client side. You will need Ajax > behaviors > > to send the ourcome to the server to be able to use it there. > Wicket > does > > this with (Web)ClientInfo related classes. > > > > I'll be VERY glad to see your
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Hi, my stance hasn't changed: I'm not in favor to add a dependency to a library which - updates frequently to adjust to browser developments - introduces a singleton bottleneck - can't be excluded from dependencies - is hidden behind an age-old API Wicket API (UserAgent) ... - ... which won't be sufficient to many people anyways .. just to save someone a single line of code passing the user agent string to the library himself. Have fun Sven Am 22.06.2018 um 14:37 schrieb Tobias Soloschenko: I think we should turn off the gatherExtendedBrowserInformation by default and give a hint that there is a synchronisation point of 0,011 ms when turned on, but the detection is much more reliable with the new implementation. kind regards Tobias Am 22.06.2018 um 11:49 schrieb Maxim Solodovnik : Is it time to resume this discussion? We still have PR unmerged, and don't have agreement what to do next :( On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < tobiassolosche...@googlemail.com> wrote: :-D kind regards Tobias Am 09.04.2018 um 19:14 schrieb Sven Meier : bike shed :P Sven Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: This topic is more active than the release one :) On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko wrote: -1 for dropping agent detection +1 for adding a dependency to an external library (because of the big pool of browsers - which might increase in future) kind regards Tobias Am 05.04.2018 um 13:44 schrieb Sven Meier : +0 for dropping agent detection (3) -1 for adding a dependency to an external library Sven Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < solomax...@gmail.com>: It seems the discussion is spread between this thread and the JIRA https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 As far as I can see we don't have consensus if this feature should 1) remain as is (drop PR) 2) be improved (merge PR and/or enhance detection) 3) browser detection should be dropped? I would vote for option 2+ :) On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < mgrigo...@apache.org> wrote: On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: - Ursprüngliche Mail - even in 2009 it was considered bad: https://www.sitepoint.com/why- browser-sniffing-stinks/ and in case that is not enough, read what the guy that invented modernizr has to say: http://farukat.es/journal/2011/02/499-lest-we-forget-or- how-i-learned-whats-so-bad-about-browser-sniffing/ I do not trust anyone who says "don't do it this way" but doesn't say how to do it! There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS code and they served well for the last decade. Since there are several other *Java* libraries for user agent detection this means that someone still finds them useful despite what other people claim. unreliable things wont get reliably by pointing into the past and then telling that your fater did it the same way nowadays you would use feature detection, see: https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the *server* side, i.e. in the *Java* code. It reads the request header and tells you what the browser is. The JS feature detection is only client side. You will need Ajax behaviors to send the ourcome to the server to be able to use it there. Wicket does this with (Web)ClientInfo related classes. I'll be VERY glad to see your PR that uses modern ways to redo the current checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap uses this information to decide whether to render respond.js! Until then please do not make such bold statements. It is easy to read an article and say "this is the [new] silver bullet". Until you get your hands dirty you never know what kind of problems you will face! btw: https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess why... https://github.com/pieroxy/java-user-agent-detection/releases -> last release from september 2017... Sep 2017 is like yesterday (all only MAJOR releases!) 28. September 2017 - Firefox 56 14. November 2017 - Firefox 57 Quantum 23. Januar 2018 - Firefox 58 13. März 2018 - Firefox 59 2017-09-05 - Chrome 61.0.3163 2017-10-17 - Chrome 62.0.3202 2017-12-05 - Chrome 63.0.3239 2018-01-23 - Chrome 64.0.3282 2018-03-06 - Chrome 65.0.3325 and this is just 2 desktop ones! I dont want to talk about the loads of updates my android device got in that time (firefox mobile, chrome and samsung internet!) - oh, and btw: they still lie about the user agent all time dont get me wrong, but sep 17 is freaking old in case you need to reliably detect the browser! Yes, and all of them are properly parsed by the same code that has been used
Re: [DISCUSSION] WICKET-6544 mobile browser detection
I think we should turn off the gatherExtendedBrowserInformation by default and give a hint that there is a synchronisation point of 0,011 ms when turned on, but the detection is much more reliable with the new implementation. kind regards Tobias > Am 22.06.2018 um 11:49 schrieb Maxim Solodovnik : > > Is it time to resume this discussion? > We still have PR unmerged, and don't have agreement what to do next :( > > On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < > tobiassolosche...@googlemail.com> wrote: > >> :-D >> >> kind regards >> >> Tobias >> >>> Am 09.04.2018 um 19:14 schrieb Sven Meier : >>> >>> bike shed :P >>> >>> Sven >>> >>> Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: This topic is more active than the release one :) On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko wrote: > -1 for dropping agent detection > +1 for adding a dependency to an external library (because of the big >> pool of browsers - which might increase in future) > > kind regards > > Tobias > >> Am 05.04.2018 um 13:44 schrieb Sven Meier : >> >> +0 for dropping agent detection (3) >> -1 for adding a dependency to an external library >> >> Sven >> >> Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < >> solomax...@gmail.com>: >>> It seems the discussion is spread between this thread and the JIRA >>> >> https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 >>> >>> As far as I can see we don't have consensus if this feature should >>> 1) remain as is (drop PR) >>> 2) be improved (merge PR and/or enhance detection) >>> 3) browser detection should be dropped? >>> >>> I would vote for option 2+ :) >>> >>> On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < >> mgrigo...@apache.org> >>> wrote: >>> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: > > - Ursprüngliche Mail - >>> even in 2009 it was considered bad: >>> https://www.sitepoint.com/why- >>> browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that invented > modernizr >>> has to say: >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >> I do not trust anyone who says "don't do it this way" but doesn't >>> say how >> to do it! >> >> There are several of "if (isBrowserX()) {...} else {...}" in >>> Wicket JS > code >> and they served well for the last decade. >> Since there are several other *Java* libraries for user agent >>> detection >> this means that someone still finds them useful despite what >>> other people >> claim. > unreliable things wont get reliably by pointing into the past and >>> then > telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the *server* >>> side, i.e. in the *Java* code. It reads the request header and tells you >>> what the browser is. The JS feature detection is only client side. You will need Ajax >>> behaviors to send the ourcome to the server to be able to use it there. Wicket >>> does this with (Web)ClientInfo related classes. I'll be VERY glad to see your PR that uses modern ways to redo the >>> current checks in wicket-ajax.js or in the server code, e.g. Wicket >> Bootstrap >>> uses this information to decide whether to render respond.js! Until then please do not make such bold statements. It is easy to >>> read an article and say "this is the [new] silver bullet". Until you get >> your >>> hands dirty you never know what kind of problems you will face! > >> >>> btw: >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >>> why... >>> https://github.com/pieroxy/java-user-agent-detection/releases -> >>> last >>> release from september 2017... >>> >>> >> Sep 2017 is like yesterday > (all only MAJOR releases!) > > 28. September 2017 - Firefox 56 > 14. November 2017 - Firefox 57 Quantum > 23. Januar 2018 - Firefox 58 > 13. März 2018 - Firefox 59 >
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Is it time to resume this discussion? We still have PR unmerged, and don't have agreement what to do next :( On Tue, Apr 10, 2018 at 3:08 AM Tobias Soloschenko < tobiassolosche...@googlemail.com> wrote: > :-D > > kind regards > > Tobias > > > Am 09.04.2018 um 19:14 schrieb Sven Meier : > > > > bike shed :P > > > > Sven > > > > > >> Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: > >> This topic is more active than the release one :) > >> > >> On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko > >> wrote: > >>> -1 for dropping agent detection > >>> +1 for adding a dependency to an external library (because of the big > pool of browsers - which might increase in future) > >>> > >>> kind regards > >>> > >>> Tobias > >>> > Am 05.04.2018 um 13:44 schrieb Sven Meier : > > +0 for dropping agent detection (3) > -1 for adding a dependency to an external library > > Sven > > Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik < > solomax...@gmail.com>: > > It seems the discussion is spread between this thread and the JIRA > > > https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > > > > As far as I can see we don't have consensus if this feature should > > 1) remain as is (drop PR) > > 2) be improved (merge PR and/or enhance detection) > > 3) browser detection should be dropped? > > > > I would vote for option 2+ :) > > > > On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov < > mgrigo...@apache.org> > > wrote: > > > >> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < > >> korbinian.ba...@whiskyworld.de> wrote: > >> > >>> > >>> - Ursprüngliche Mail - > > even in 2009 it was considered bad: > > https://www.sitepoint.com/why- > > browser-sniffing-stinks/ > > and in case that is not enough, read what the guy that invented > >>> modernizr > > has to say: > > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > > how-i-learned-whats-so-bad-about-browser-sniffing/ > > > > > I do not trust anyone who says "don't do it this way" but doesn't > > say > >> how > to do it! > > There are several of "if (isBrowserX()) {...} else {...}" in > > Wicket JS > >>> code > and they served well for the last decade. > Since there are several other *Java* libraries for user agent > > detection > this means that someone still finds them useful despite what > > other > >> people > claim. > >>> unreliable things wont get reliably by pointing into the past and > > then > >>> telling that your fater did it the same way > >>> > >>> nowadays you would use feature detection, see: > >>> > >>> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > >>> testing/Cross_browser_testing/Feature_detection > >> > >> Korbinian, > >> > >> The PR by Maxim is about the User-Agent detection at the *server* > > side, > >> i.e. in the *Java* code. It reads the request header and tells you > > what the > >> browser is. > >> The JS feature detection is only client side. You will need Ajax > > behaviors > >> to send the ourcome to the server to be able to use it there. Wicket > > does > >> this with (Web)ClientInfo related classes. > >> > >> I'll be VERY glad to see your PR that uses modern ways to redo the > > current > >> checks in wicket-ajax.js or in the server code, e.g. Wicket > Bootstrap > > uses > >> this information to decide whether to render respond.js! > >> Until then please do not make such bold statements. It is easy to > > read an > >> article and say "this is the [new] silver bullet". Until you get > your > > hands > >> dirty you never know what kind of problems you will face! > >> > >> > >>> > > > btw: > > https://github.com/HaraldWalker/user-agent-utils -> this is EOL, > >> guess > > why... > > https://github.com/pieroxy/java-user-agent-detection/releases -> > > last > > release from september 2017... > > > > > Sep 2017 is like yesterday > >>> (all only MAJOR releases!) > >>> > >>> 28. September 2017 - Firefox 56 > >>> 14. November 2017 - Firefox 57 Quantum > >>> 23. Januar 2018 - Firefox 58 > >>> 13. März 2018 - Firefox 59 > >>> > >>> 2017-09-05 - Chrome 61.0.3163 > >>> 2017-10-17 - Chrome 62.0.3202 > >>> 2017-12-05 - Chrome 63.0.3239 > >>> 2018-01-23 - Chrome 64.0.3282 > >>> 2018-03-06 - Chrome 65.0.3325 > >>> > >>> and this is just 2 desktop ones! I dont want to talk about the > > loads of > >>> updates my android device got in that time (firefox
Re: [DISCUSSION] WICKET-6544 mobile browser detection
:-D kind regards Tobias > Am 09.04.2018 um 19:14 schrieb Sven Meier: > > bike shed :P > > Sven > > >> Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: >> This topic is more active than the release one :) >> >> On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenko >> wrote: >>> -1 for dropping agent detection >>> +1 for adding a dependency to an external library (because of the big pool >>> of browsers - which might increase in future) >>> >>> kind regards >>> >>> Tobias >>> Am 05.04.2018 um 13:44 schrieb Sven Meier : +0 for dropping agent detection (3) -1 for adding a dependency to an external library Sven Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik : > It seems the discussion is spread between this thread and the JIRA > https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > > As far as I can see we don't have consensus if this feature should > 1) remain as is (drop PR) > 2) be improved (merge PR and/or enhance detection) > 3) browser detection should be dropped? > > I would vote for option 2+ :) > > On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov > wrote: > >> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < >> korbinian.ba...@whiskyworld.de> wrote: >> >>> >>> - Ursprüngliche Mail - > even in 2009 it was considered bad: > https://www.sitepoint.com/why- > browser-sniffing-stinks/ > and in case that is not enough, read what the guy that invented >>> modernizr > has to say: > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > how-i-learned-whats-so-bad-about-browser-sniffing/ > > I do not trust anyone who says "don't do it this way" but doesn't > say >> how to do it! There are several of "if (isBrowserX()) {...} else {...}" in > Wicket JS >>> code and they served well for the last decade. Since there are several other *Java* libraries for user agent > detection this means that someone still finds them useful despite what > other >> people claim. >>> unreliable things wont get reliably by pointing into the past and > then >>> telling that your fater did it the same way >>> >>> nowadays you would use feature detection, see: >>> >>> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ >>> testing/Cross_browser_testing/Feature_detection >> >> Korbinian, >> >> The PR by Maxim is about the User-Agent detection at the *server* > side, >> i.e. in the *Java* code. It reads the request header and tells you > what the >> browser is. >> The JS feature detection is only client side. You will need Ajax > behaviors >> to send the ourcome to the server to be able to use it there. Wicket > does >> this with (Web)ClientInfo related classes. >> >> I'll be VERY glad to see your PR that uses modern ways to redo the > current >> checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap > uses >> this information to decide whether to render respond.js! >> Until then please do not make such bold statements. It is easy to > read an >> article and say "this is the [new] silver bullet". Until you get your > hands >> dirty you never know what kind of problems you will face! >> >> >>> > btw: > https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >> guess > why... > https://github.com/pieroxy/java-user-agent-detection/releases -> > last > release from september 2017... > > Sep 2017 is like yesterday >>> (all only MAJOR releases!) >>> >>> 28. September 2017 - Firefox 56 >>> 14. November 2017 - Firefox 57 Quantum >>> 23. Januar 2018 - Firefox 58 >>> 13. März 2018 - Firefox 59 >>> >>> 2017-09-05 - Chrome 61.0.3163 >>> 2017-10-17 - Chrome 62.0.3202 >>> 2017-12-05 - Chrome 63.0.3239 >>> 2018-01-23 - Chrome 64.0.3282 >>> 2018-03-06 - Chrome 65.0.3325 >>> >>> and this is just 2 desktop ones! I dont want to talk about the > loads of >>> updates my android device got in that time (firefox mobile, chrome > and >>> samsung internet!) - oh, and btw: they still lie about the user > agent all >>> time dont get me wrong, but sep 17 is freaking old in case you > need >> to >>> reliably detect the browser! >>> >> Yes, and all of them are properly parsed by the same code that has > been >> used in the last decade! >> The
Re: [DISCUSSION] WICKET-6544 mobile browser detection
bike shed :P Sven Am 09.04.2018 um 18:12 schrieb Maxim Solodovnik: This topic is more active than the release one :) On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenkowrote: -1 for dropping agent detection +1 for adding a dependency to an external library (because of the big pool of browsers - which might increase in future) kind regards Tobias Am 05.04.2018 um 13:44 schrieb Sven Meier : +0 for dropping agent detection (3) -1 for adding a dependency to an external library Sven Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik : It seems the discussion is spread between this thread and the JIRA https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 As far as I can see we don't have consensus if this feature should 1) remain as is (drop PR) 2) be improved (merge PR and/or enhance detection) 3) browser detection should be dropped? I would vote for option 2+ :) On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov wrote: On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: - Ursprüngliche Mail - even in 2009 it was considered bad: https://www.sitepoint.com/why- browser-sniffing-stinks/ and in case that is not enough, read what the guy that invented modernizr has to say: http://farukat.es/journal/2011/02/499-lest-we-forget-or- how-i-learned-whats-so-bad-about-browser-sniffing/ I do not trust anyone who says "don't do it this way" but doesn't say how to do it! There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS code and they served well for the last decade. Since there are several other *Java* libraries for user agent detection this means that someone still finds them useful despite what other people claim. unreliable things wont get reliably by pointing into the past and then telling that your fater did it the same way nowadays you would use feature detection, see: https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the *server* side, i.e. in the *Java* code. It reads the request header and tells you what the browser is. The JS feature detection is only client side. You will need Ajax behaviors to send the ourcome to the server to be able to use it there. Wicket does this with (Web)ClientInfo related classes. I'll be VERY glad to see your PR that uses modern ways to redo the current checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap uses this information to decide whether to render respond.js! Until then please do not make such bold statements. It is easy to read an article and say "this is the [new] silver bullet". Until you get your hands dirty you never know what kind of problems you will face! btw: https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess why... https://github.com/pieroxy/java-user-agent-detection/releases -> last release from september 2017... Sep 2017 is like yesterday (all only MAJOR releases!) 28. September 2017 - Firefox 56 14. November 2017 - Firefox 57 Quantum 23. Januar 2018 - Firefox 58 13. März 2018 - Firefox 59 2017-09-05 - Chrome 61.0.3163 2017-10-17 - Chrome 62.0.3202 2017-12-05 - Chrome 63.0.3239 2018-01-23 - Chrome 64.0.3282 2018-03-06 - Chrome 65.0.3325 and this is just 2 desktop ones! I dont want to talk about the loads of updates my android device got in that time (firefox mobile, chrome and samsung internet!) - oh, and btw: they still lie about the user agent all time dont get me wrong, but sep 17 is freaking old in case you need to reliably detect the browser! Yes, and all of them are properly parsed by the same code that has been used in the last decade! The browser vendors have no reason to change their syntax of user agent. Believe me they do know that this piece of information *is being* used in the wild! -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
This topic is more active than the release one :) On Thu, Apr 5, 2018 at 7:22 PM, Tobias Soloschenkowrote: > -1 for dropping agent detection > +1 for adding a dependency to an external library (because of the big pool of > browsers - which might increase in future) > > kind regards > > Tobias > >> Am 05.04.2018 um 13:44 schrieb Sven Meier : >> >> +0 for dropping agent detection (3) >> -1 for adding a dependency to an external library >> >> Sven >> >> Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik >> : >>> It seems the discussion is spread between this thread and the JIRA >>> https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 >>> >>> As far as I can see we don't have consensus if this feature should >>> 1) remain as is (drop PR) >>> 2) be improved (merge PR and/or enhance detection) >>> 3) browser detection should be dropped? >>> >>> I would vote for option 2+ :) >>> >>> On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov >>> wrote: >>> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: > > > - Ursprüngliche Mail - >>> even in 2009 it was considered bad: >>> https://www.sitepoint.com/why- >>> browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that invented > modernizr >>> has to say: >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >> I do not trust anyone who says "don't do it this way" but doesn't >>> say how >> to do it! >> >> There are several of "if (isBrowserX()) {...} else {...}" in >>> Wicket JS > code >> and they served well for the last decade. >> Since there are several other *Java* libraries for user agent >>> detection >> this means that someone still finds them useful despite what >>> other people >> claim. > > unreliable things wont get reliably by pointing into the past and >>> then > telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the *server* >>> side, i.e. in the *Java* code. It reads the request header and tells you >>> what the browser is. The JS feature detection is only client side. You will need Ajax >>> behaviors to send the ourcome to the server to be able to use it there. Wicket >>> does this with (Web)ClientInfo related classes. I'll be VERY glad to see your PR that uses modern ways to redo the >>> current checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap >>> uses this information to decide whether to render respond.js! Until then please do not make such bold statements. It is easy to >>> read an article and say "this is the [new] silver bullet". Until you get your >>> hands dirty you never know what kind of problems you will face! > > >> >> >>> btw: >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >>> why... >>> https://github.com/pieroxy/java-user-agent-detection/releases -> >>> last >>> release from september 2017... >>> >>> >> Sep 2017 is like yesterday > > (all only MAJOR releases!) > > 28. September 2017 - Firefox 56 > 14. November 2017 - Firefox 57 Quantum > 23. Januar 2018 - Firefox 58 > 13. März 2018 - Firefox 59 > > 2017-09-05 - Chrome 61.0.3163 > 2017-10-17 - Chrome 62.0.3202 > 2017-12-05 - Chrome 63.0.3239 > 2018-01-23 - Chrome 64.0.3282 > 2018-03-06 - Chrome 65.0.3325 > > and this is just 2 desktop ones! I dont want to talk about the >>> loads of > updates my android device got in that time (firefox mobile, chrome >>> and > samsung internet!) - oh, and btw: they still lie about the user >>> agent all > time dont get me wrong, but sep 17 is freaking old in case you >>> need to > reliably detect the browser! > Yes, and all of them are properly parsed by the same code that has >>> been used in the last decade! The browser vendors have no reason to change their syntax of user >>> agent. Believe me they do know that this piece of information *is being* >>> used in the wild! >>> >>> >>> >>> -- >>> WBR >>> Maxim aka solomax -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
-1 for dropping agent detection +1 for adding a dependency to an external library (because of the big pool of browsers - which might increase in future) kind regards Tobias > Am 05.04.2018 um 13:44 schrieb Sven Meier: > > +0 for dropping agent detection (3) > -1 for adding a dependency to an external library > > Sven > > Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik > : >> It seems the discussion is spread between this thread and the JIRA >> https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 >> >> As far as I can see we don't have consensus if this feature should >> 1) remain as is (drop PR) >> 2) be improved (merge PR and/or enhance detection) >> 3) browser detection should be dropped? >> >> I would vote for option 2+ :) >> >> On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov >> wrote: >> >>> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < >>> korbinian.ba...@whiskyworld.de> wrote: >>> - Ursprüngliche Mail - >> even in 2009 it was considered bad: >> https://www.sitepoint.com/why- >> browser-sniffing-stinks/ >> and in case that is not enough, read what the guy that invented modernizr >> has to say: >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >> how-i-learned-whats-so-bad-about-browser-sniffing/ >> >> > I do not trust anyone who says "don't do it this way" but doesn't >> say >>> how > to do it! > > There are several of "if (isBrowserX()) {...} else {...}" in >> Wicket JS code > and they served well for the last decade. > Since there are several other *Java* libraries for user agent >> detection > this means that someone still finds them useful despite what >> other >>> people > claim. unreliable things wont get reliably by pointing into the past and >> then telling that your fater did it the same way nowadays you would use feature detection, see: https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ testing/Cross_browser_testing/Feature_detection >>> >>> >>> Korbinian, >>> >>> The PR by Maxim is about the User-Agent detection at the *server* >> side, >>> i.e. in the *Java* code. It reads the request header and tells you >> what the >>> browser is. >>> The JS feature detection is only client side. You will need Ajax >> behaviors >>> to send the ourcome to the server to be able to use it there. Wicket >> does >>> this with (Web)ClientInfo related classes. >>> >>> I'll be VERY glad to see your PR that uses modern ways to redo the >> current >>> checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap >> uses >>> this information to decide whether to render respond.js! >>> Until then please do not make such bold statements. It is easy to >> read an >>> article and say "this is the [new] silver bullet". Until you get your >> hands >>> dirty you never know what kind of problems you will face! >>> >>> > > >> btw: >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >>> guess >> why... >> https://github.com/pieroxy/java-user-agent-detection/releases -> >> last >> release from september 2017... >> >> > Sep 2017 is like yesterday (all only MAJOR releases!) 28. September 2017 - Firefox 56 14. November 2017 - Firefox 57 Quantum 23. Januar 2018 - Firefox 58 13. März 2018 - Firefox 59 2017-09-05 - Chrome 61.0.3163 2017-10-17 - Chrome 62.0.3202 2017-12-05 - Chrome 63.0.3239 2018-01-23 - Chrome 64.0.3282 2018-03-06 - Chrome 65.0.3325 and this is just 2 desktop ones! I dont want to talk about the >> loads of updates my android device got in that time (firefox mobile, chrome >> and samsung internet!) - oh, and btw: they still lie about the user >> agent all time dont get me wrong, but sep 17 is freaking old in case you >> need >>> to reliably detect the browser! >>> >>> Yes, and all of them are properly parsed by the same code that has >> been >>> used in the last decade! >>> The browser vendors have no reason to change their syntax of user >> agent. >>> Believe me they do know that this piece of information *is being* >> used in >>> the wild! >>> >> >> >> >> -- >> WBR >> Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
+0 for dropping agent detection (3) -1 for adding a dependency to an external library Sven Am 3. April 2018 16:34:15 MESZ schrieb Maxim Solodovnik: >It seems the discussion is spread between this thread and the JIRA >https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > >As far as I can see we don't have consensus if this feature should >1) remain as is (drop PR) >2) be improved (merge PR and/or enhance detection) >3) browser detection should be dropped? > >I would vote for option 2+ :) > >On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov >wrote: > >> On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < >> korbinian.ba...@whiskyworld.de> wrote: >> >> > >> > >> > - Ursprüngliche Mail - >> > >> even in 2009 it was considered bad: >https://www.sitepoint.com/why- >> > >> browser-sniffing-stinks/ >> > >> and in case that is not enough, read what the guy that invented >> > modernizr >> > >> has to say: >> > >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >> > >> how-i-learned-whats-so-bad-about-browser-sniffing/ >> > >> >> > >> >> > > I do not trust anyone who says "don't do it this way" but doesn't >say >> how >> > > to do it! >> > > >> > > There are several of "if (isBrowserX()) {...} else {...}" in >Wicket JS >> > code >> > > and they served well for the last decade. >> > > Since there are several other *Java* libraries for user agent >detection >> > > this means that someone still finds them useful despite what >other >> people >> > > claim. >> > >> > unreliable things wont get reliably by pointing into the past and >then >> > telling that your fater did it the same way >> > >> > nowadays you would use feature detection, see: >> > >> > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ >> > testing/Cross_browser_testing/Feature_detection >> >> >> Korbinian, >> >> The PR by Maxim is about the User-Agent detection at the *server* >side, >> i.e. in the *Java* code. It reads the request header and tells you >what the >> browser is. >> The JS feature detection is only client side. You will need Ajax >behaviors >> to send the ourcome to the server to be able to use it there. Wicket >does >> this with (Web)ClientInfo related classes. >> >> I'll be VERY glad to see your PR that uses modern ways to redo the >current >> checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap >uses >> this information to decide whether to render respond.js! >> Until then please do not make such bold statements. It is easy to >read an >> article and say "this is the [new] silver bullet". Until you get your >hands >> dirty you never know what kind of problems you will face! >> >> >> > >> > >> > > >> > > >> > >> btw: >> > >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >> guess >> > >> why... >> > >> https://github.com/pieroxy/java-user-agent-detection/releases -> >last >> > >> release from september 2017... >> > >> >> > >> >> > > Sep 2017 is like yesterday >> > >> > (all only MAJOR releases!) >> > >> > 28. September 2017 - Firefox 56 >> > 14. November 2017 - Firefox 57 Quantum >> > 23. Januar 2018 - Firefox 58 >> > 13. März 2018 - Firefox 59 >> > >> > 2017-09-05 - Chrome 61.0.3163 >> > 2017-10-17 - Chrome 62.0.3202 >> > 2017-12-05 - Chrome 63.0.3239 >> > 2018-01-23 - Chrome 64.0.3282 >> > 2018-03-06 - Chrome 65.0.3325 >> > >> > and this is just 2 desktop ones! I dont want to talk about the >loads of >> > updates my android device got in that time (firefox mobile, chrome >and >> > samsung internet!) - oh, and btw: they still lie about the user >agent all >> > time dont get me wrong, but sep 17 is freaking old in case you >need >> to >> > reliably detect the browser! >> > >> >> Yes, and all of them are properly parsed by the same code that has >been >> used in the last decade! >> The browser vendors have no reason to change their syntax of user >agent. >> Believe me they do know that this piece of information *is being* >used in >> the wild! >> > > > >-- >WBR >Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
+1 for 2) from me Martin Grigorov Wicket Training and Consulting Looking for a remote position with Wicket ? Contact me! https://twitter.com/mtgrigorov On Tue, Apr 3, 2018 at 5:34 PM, Maxim Solodovnikwrote: > It seems the discussion is spread between this thread and the JIRA > https://issues.apache.org/jira/browse/WICKET-6544? > focusedCommentId=16423835=com.atlassian.jira. > plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 > > As far as I can see we don't have consensus if this feature should > 1) remain as is (drop PR) > 2) be improved (merge PR and/or enhance detection) > 3) browser detection should be dropped? > > I would vote for option 2+ :) > > On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorov > wrote: > > > On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < > > korbinian.ba...@whiskyworld.de> wrote: > > > > > > > > > > > - Ursprüngliche Mail - > > > >> even in 2009 it was considered bad: https://www.sitepoint.com/why- > > > >> browser-sniffing-stinks/ > > > >> and in case that is not enough, read what the guy that invented > > > modernizr > > > >> has to say: > > > >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- > > > >> how-i-learned-whats-so-bad-about-browser-sniffing/ > > > >> > > > >> > > > > I do not trust anyone who says "don't do it this way" but doesn't say > > how > > > > to do it! > > > > > > > > There are several of "if (isBrowserX()) {...} else {...}" in Wicket > JS > > > code > > > > and they served well for the last decade. > > > > Since there are several other *Java* libraries for user agent > detection > > > > this means that someone still finds them useful despite what other > > people > > > > claim. > > > > > > unreliable things wont get reliably by pointing into the past and then > > > telling that your fater did it the same way > > > > > > nowadays you would use feature detection, see: > > > > > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > > > testing/Cross_browser_testing/Feature_detection > > > > > > Korbinian, > > > > The PR by Maxim is about the User-Agent detection at the *server* side, > > i.e. in the *Java* code. It reads the request header and tells you what > the > > browser is. > > The JS feature detection is only client side. You will need Ajax > behaviors > > to send the ourcome to the server to be able to use it there. Wicket does > > this with (Web)ClientInfo related classes. > > > > I'll be VERY glad to see your PR that uses modern ways to redo the > current > > checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap > uses > > this information to decide whether to render respond.js! > > Until then please do not make such bold statements. It is easy to read an > > article and say "this is the [new] silver bullet". Until you get your > hands > > dirty you never know what kind of problems you will face! > > > > > > > > > > > > > > > > > > > > > >> btw: > > > >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, > > guess > > > >> why... > > > >> https://github.com/pieroxy/java-user-agent-detection/releases -> > last > > > >> release from september 2017... > > > >> > > > >> > > > > Sep 2017 is like yesterday > > > > > > (all only MAJOR releases!) > > > > > > 28. September 2017 - Firefox 56 > > > 14. November 2017 - Firefox 57 Quantum > > > 23. Januar 2018 - Firefox 58 > > > 13. März 2018 - Firefox 59 > > > > > > 2017-09-05 - Chrome 61.0.3163 > > > 2017-10-17 - Chrome 62.0.3202 > > > 2017-12-05 - Chrome 63.0.3239 > > > 2018-01-23 - Chrome 64.0.3282 > > > 2018-03-06 - Chrome 65.0.3325 > > > > > > and this is just 2 desktop ones! I dont want to talk about the loads of > > > updates my android device got in that time (firefox mobile, chrome and > > > samsung internet!) - oh, and btw: they still lie about the user agent > all > > > time dont get me wrong, but sep 17 is freaking old in case you need > > to > > > reliably detect the browser! > > > > > > > Yes, and all of them are properly parsed by the same code that has been > > used in the last decade! > > The browser vendors have no reason to change their syntax of user agent. > > Believe me they do know that this piece of information *is being* used in > > the wild! > > > > > > -- > WBR > Maxim aka solomax >
Re: [DISCUSSION] WICKET-6544 mobile browser detection
It seems the discussion is spread between this thread and the JIRA https://issues.apache.org/jira/browse/WICKET-6544?focusedCommentId=16423835=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16423835 As far as I can see we don't have consensus if this feature should 1) remain as is (drop PR) 2) be improved (merge PR and/or enhance detection) 3) browser detection should be dropped? I would vote for option 2+ :) On Mon, Apr 2, 2018 at 5:11 AM, Martin Grigorovwrote: > On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < > korbinian.ba...@whiskyworld.de> wrote: > > > > > > > - Ursprüngliche Mail - > > >> even in 2009 it was considered bad: https://www.sitepoint.com/why- > > >> browser-sniffing-stinks/ > > >> and in case that is not enough, read what the guy that invented > > modernizr > > >> has to say: > > >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- > > >> how-i-learned-whats-so-bad-about-browser-sniffing/ > > >> > > >> > > > I do not trust anyone who says "don't do it this way" but doesn't say > how > > > to do it! > > > > > > There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS > > code > > > and they served well for the last decade. > > > Since there are several other *Java* libraries for user agent detection > > > this means that someone still finds them useful despite what other > people > > > claim. > > > > unreliable things wont get reliably by pointing into the past and then > > telling that your fater did it the same way > > > > nowadays you would use feature detection, see: > > > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > > testing/Cross_browser_testing/Feature_detection > > > Korbinian, > > The PR by Maxim is about the User-Agent detection at the *server* side, > i.e. in the *Java* code. It reads the request header and tells you what the > browser is. > The JS feature detection is only client side. You will need Ajax behaviors > to send the ourcome to the server to be able to use it there. Wicket does > this with (Web)ClientInfo related classes. > > I'll be VERY glad to see your PR that uses modern ways to redo the current > checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap uses > this information to decide whether to render respond.js! > Until then please do not make such bold statements. It is easy to read an > article and say "this is the [new] silver bullet". Until you get your hands > dirty you never know what kind of problems you will face! > > > > > > > > > > > > > > >> btw: > > >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, > guess > > >> why... > > >> https://github.com/pieroxy/java-user-agent-detection/releases -> last > > >> release from september 2017... > > >> > > >> > > > Sep 2017 is like yesterday > > > > (all only MAJOR releases!) > > > > 28. September 2017 - Firefox 56 > > 14. November 2017 - Firefox 57 Quantum > > 23. Januar 2018 - Firefox 58 > > 13. März 2018 - Firefox 59 > > > > 2017-09-05 - Chrome 61.0.3163 > > 2017-10-17 - Chrome 62.0.3202 > > 2017-12-05 - Chrome 63.0.3239 > > 2018-01-23 - Chrome 64.0.3282 > > 2018-03-06 - Chrome 65.0.3325 > > > > and this is just 2 desktop ones! I dont want to talk about the loads of > > updates my android device got in that time (firefox mobile, chrome and > > samsung internet!) - oh, and btw: they still lie about the user agent all > > time dont get me wrong, but sep 17 is freaking old in case you need > to > > reliably detect the browser! > > > > Yes, and all of them are properly parsed by the same code that has been > used in the last decade! > The browser vendors have no reason to change their syntax of user agent. > Believe me they do know that this piece of information *is being* used in > the wild! > -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
On Thu, Mar 29, 2018 at 1:31 AM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: > > > - Ursprüngliche Mail - > >> even in 2009 it was considered bad: https://www.sitepoint.com/why- > >> browser-sniffing-stinks/ > >> and in case that is not enough, read what the guy that invented > modernizr > >> has to say: > >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- > >> how-i-learned-whats-so-bad-about-browser-sniffing/ > >> > >> > > I do not trust anyone who says "don't do it this way" but doesn't say how > > to do it! > > > > There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS > code > > and they served well for the last decade. > > Since there are several other *Java* libraries for user agent detection > > this means that someone still finds them useful despite what other people > > claim. > > unreliable things wont get reliably by pointing into the past and then > telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_ > testing/Cross_browser_testing/Feature_detection Korbinian, The PR by Maxim is about the User-Agent detection at the *server* side, i.e. in the *Java* code. It reads the request header and tells you what the browser is. The JS feature detection is only client side. You will need Ajax behaviors to send the ourcome to the server to be able to use it there. Wicket does this with (Web)ClientInfo related classes. I'll be VERY glad to see your PR that uses modern ways to redo the current checks in wicket-ajax.js or in the server code, e.g. Wicket Bootstrap uses this information to decide whether to render respond.js! Until then please do not make such bold statements. It is easy to read an article and say "this is the [new] silver bullet". Until you get your hands dirty you never know what kind of problems you will face! > > > > > > > >> btw: > >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess > >> why... > >> https://github.com/pieroxy/java-user-agent-detection/releases -> last > >> release from september 2017... > >> > >> > > Sep 2017 is like yesterday > > (all only MAJOR releases!) > > 28. September 2017 - Firefox 56 > 14. November 2017 - Firefox 57 Quantum > 23. Januar 2018 - Firefox 58 > 13. März 2018 - Firefox 59 > > 2017-09-05 - Chrome 61.0.3163 > 2017-10-17 - Chrome 62.0.3202 > 2017-12-05 - Chrome 63.0.3239 > 2018-01-23 - Chrome 64.0.3282 > 2018-03-06 - Chrome 65.0.3325 > > and this is just 2 desktop ones! I dont want to talk about the loads of > updates my android device got in that time (firefox mobile, chrome and > samsung internet!) - oh, and btw: they still lie about the user agent all > time dont get me wrong, but sep 17 is freaking old in case you need to > reliably detect the browser! > Yes, and all of them are properly parsed by the same code that has been used in the last decade! The browser vendors have no reason to change their syntax of user agent. Believe me they do know that this piece of information *is being* used in the wild!
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Just have checked All previous tests works as before On Thu, Mar 29, 2018 at 9:01 PM, Maxim Solodovnikwrote: > I'll better double-check > Tests were slightly changed. > > WBR, Maxim > (from mobile, sorry for the typos) > > On Thu, Mar 29, 2018, 20:59 Maxim Solodovnik wrote: >> >> All tests are passed >> So I believe so >> >> WBR, Maxim >> (from mobile, sorry for the typos) >> >> On Thu, Mar 29, 2018, 20:55 Sven Meier wrote: >>> >>> Let's keep this topics separate. >>> >>> Any improvements to browser detection would be backwards compatible, >>> right? >>> >>> Sven >>> >>> Am 29. März 2018 11:10:55 MESZ schrieb Maxim Solodovnik >>> : >>> >Should I close my PR and start new discussion? :)) >>> > >>> >On Thu, Mar 29, 2018 at 12:52 PM, Sven Meier wrote: >>> >> BTW I'd rather keep the current solution as it is and discuss >>> >releasing Wicket 8 :) >>> >> >>> >> Sven >>> >> >>> >> Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier : >>> >>>It's perfectly fine to use whatever tool gets the job done. People >>> >say >>> >>>how to do it instead, but no one has to follow the advice. >>> >>> >>> >>>IMHO it's something different for a framework to offer an API on top >>> >of >>> >>>a something that doesn't even work reliably: >>> >>>Wicket's browser detection is using regex-matching on identifiers >>> >>>generated by browsers to make it difficult to be detected :P. >>> >>> >>> >>>Regarding integrating of mentioned libraries: >>> >>> >>> >>> LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() >>> >>> >>> >>>I don't see a benefit of having that in Wicket or wicketstuff. >>> >>>Integrating modernizr might be more interesting, but I doubt many >>> >>>people need browser detection on the server. >>> >>> >>> >>>Have fun >>> >>>Sven >>> >>> >>> >>> >>> >>> >>> >>>Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik >>> >>> : >>> "you would use feature detection" - unfortunately it doesn't work >>> Good real-life example is WebRtc: you can check it is supported, >>> then you need to know which browser your client is using (Plan >>> >A, >>> Plan B, Universal, "Safari way") >>> >>> Another example wmode for , FF acts differently, >>> >>> so I really miss "which-browser" feature detection >>> >>> On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl >>> wrote: >>> > >>> > >>> > - Ursprüngliche Mail - >>> >>> even in 2009 it was considered bad: >>> >https://www.sitepoint.com/why- >>> >>> browser-sniffing-stinks/ >>> >>> and in case that is not enough, read what the guy that invented >>> modernizr >>> >>> has to say: >>> >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >>> >>> >>> >> I do not trust anyone who says "don't do it this way" but doesn't >>> say how >>> >> to do it! >>> >> >>> >> There are several of "if (isBrowserX()) {...} else {...}" in >>> >Wicket >>> JS code >>> >> and they served well for the last decade. >>> >> Since there are several other *Java* libraries for user agent >>> detection >>> >> this means that someone still finds them useful despite what >>> >other >>> people >>> >> claim. >>> > >>> > unreliable things wont get reliably by pointing into the past and >>> then telling that your fater did it the same way >>> > >>> > nowadays you would use feature detection, see: >>> > >>> > >>> >>> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection >>> > >>> >> >>> >> >>> >>> btw: >>> >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >>> guess >>> >>> why... >>> >>> https://github.com/pieroxy/java-user-agent-detection/releases -> >>> last >>> >>> release from september 2017... >>> >>> >>> >>> >>> >> Sep 2017 is like yesterday >>> > >>> > (all only MAJOR releases!) >>> > >>> > 28. September 2017 - Firefox 56 >>> > 14. November 2017 - Firefox 57 Quantum >>> > 23. Januar 2018 - Firefox 58 >>> > 13. März 2018 - Firefox 59 >>> > >>> > 2017-09-05 - Chrome 61.0.3163 >>> > 2017-10-17 - Chrome 62.0.3202 >>> > 2017-12-05 - Chrome 63.0.3239 >>> > 2018-01-23 - Chrome 64.0.3282 >>> > 2018-03-06 - Chrome 65.0.3325 >>> > >>> > and this is just 2 desktop ones! I dont want to talk about the >>> >loads >>> of updates my android device got in that time (firefox mobile, >>> >chrome >>> and samsung internet!) - oh, and btw: they still lie about the user >>> agent all time dont get me wrong, but sep 17 is freaking old in >>> case you need to reliably detect the browser! >>> >>>
Re: [DISCUSSION] WICKET-6544 mobile browser detection
I'll better double-check Tests were slightly changed. WBR, Maxim (from mobile, sorry for the typos) On Thu, Mar 29, 2018, 20:59 Maxim Solodovnikwrote: > All tests are passed > So I believe so > > WBR, Maxim > (from mobile, sorry for the typos) > > On Thu, Mar 29, 2018, 20:55 Sven Meier wrote: > >> Let's keep this topics separate. >> >> Any improvements to browser detection would be backwards compatible, >> right? >> >> Sven >> >> Am 29. März 2018 11:10:55 MESZ schrieb Maxim Solodovnik < >> solomax...@gmail.com>: >> >Should I close my PR and start new discussion? :)) >> > >> >On Thu, Mar 29, 2018 at 12:52 PM, Sven Meier wrote: >> >> BTW I'd rather keep the current solution as it is and discuss >> >releasing Wicket 8 :) >> >> >> >> Sven >> >> >> >> Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier : >> >>>It's perfectly fine to use whatever tool gets the job done. People >> >say >> >>>how to do it instead, but no one has to follow the advice. >> >>> >> >>>IMHO it's something different for a framework to offer an API on top >> >of >> >>>a something that doesn't even work reliably: >> >>>Wicket's browser detection is using regex-matching on identifiers >> >>>generated by browsers to make it difficult to be detected :P. >> >>> >> >>>Regarding integrating of mentioned libraries: >> >>> >> >>> LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() >> >>> >> >>>I don't see a benefit of having that in Wicket or wicketstuff. >> >>>Integrating modernizr might be more interesting, but I doubt many >> >>>people need browser detection on the server. >> >>> >> >>>Have fun >> >>>Sven >> >>> >> >>> >> >>> >> >>>Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik >> >>> : >> "you would use feature detection" - unfortunately it doesn't work >> Good real-life example is WebRtc: you can check it is supported, >> then you need to know which browser your client is using (Plan >> >A, >> Plan B, Universal, "Safari way") >> >> Another example wmode for , FF acts differently, >> >> so I really miss "which-browser" feature detection >> >> On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl >> wrote: >> > >> > >> > - Ursprüngliche Mail - >> >>> even in 2009 it was considered bad: >> >https://www.sitepoint.com/why- >> >>> browser-sniffing-stinks/ >> >>> and in case that is not enough, read what the guy that invented >> modernizr >> >>> has to say: >> >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >> >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >> >>> >> >>> >> >> I do not trust anyone who says "don't do it this way" but doesn't >> say how >> >> to do it! >> >> >> >> There are several of "if (isBrowserX()) {...} else {...}" in >> >Wicket >> JS code >> >> and they served well for the last decade. >> >> Since there are several other *Java* libraries for user agent >> detection >> >> this means that someone still finds them useful despite what >> >other >> people >> >> claim. >> > >> > unreliable things wont get reliably by pointing into the past and >> then telling that your fater did it the same way >> > >> > nowadays you would use feature detection, see: >> > >> > >> >> https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection >> > >> >> >> >> >> >>> btw: >> >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >> guess >> >>> why... >> >>> https://github.com/pieroxy/java-user-agent-detection/releases -> >> last >> >>> release from september 2017... >> >>> >> >>> >> >> Sep 2017 is like yesterday >> > >> > (all only MAJOR releases!) >> > >> > 28. September 2017 - Firefox 56 >> > 14. November 2017 - Firefox 57 Quantum >> > 23. Januar 2018 - Firefox 58 >> > 13. März 2018 - Firefox 59 >> > >> > 2017-09-05 - Chrome 61.0.3163 >> > 2017-10-17 - Chrome 62.0.3202 >> > 2017-12-05 - Chrome 63.0.3239 >> > 2018-01-23 - Chrome 64.0.3282 >> > 2018-03-06 - Chrome 65.0.3325 >> > >> > and this is just 2 desktop ones! I dont want to talk about the >> >loads >> of updates my android device got in that time (firefox mobile, >> >chrome >> and samsung internet!) - oh, and btw: they still lie about the user >> agent all time dont get me wrong, but sep 17 is freaking old in >> case you need to reliably detect the browser! >> >> >> >> -- >> WBR >> Maxim aka solomax >> > >> > >> > >> >-- >> >WBR >> >Maxim aka solomax >> >
Re: [DISCUSSION] WICKET-6544 mobile browser detection
All tests are passed So I believe so WBR, Maxim (from mobile, sorry for the typos) On Thu, Mar 29, 2018, 20:55 Sven Meierwrote: > Let's keep this topics separate. > > Any improvements to browser detection would be backwards compatible, right? > > Sven > > Am 29. März 2018 11:10:55 MESZ schrieb Maxim Solodovnik < > solomax...@gmail.com>: > >Should I close my PR and start new discussion? :)) > > > >On Thu, Mar 29, 2018 at 12:52 PM, Sven Meier wrote: > >> BTW I'd rather keep the current solution as it is and discuss > >releasing Wicket 8 :) > >> > >> Sven > >> > >> Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier : > >>>It's perfectly fine to use whatever tool gets the job done. People > >say > >>>how to do it instead, but no one has to follow the advice. > >>> > >>>IMHO it's something different for a framework to offer an API on top > >of > >>>a something that doesn't even work reliably: > >>>Wicket's browser detection is using regex-matching on identifiers > >>>generated by browsers to make it difficult to be detected :P. > >>> > >>>Regarding integrating of mentioned libraries: > >>> > >>> LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() > >>> > >>>I don't see a benefit of having that in Wicket or wicketstuff. > >>>Integrating modernizr might be more interesting, but I doubt many > >>>people need browser detection on the server. > >>> > >>>Have fun > >>>Sven > >>> > >>> > >>> > >>>Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik > >>> : > "you would use feature detection" - unfortunately it doesn't work > Good real-life example is WebRtc: you can check it is supported, > then you need to know which browser your client is using (Plan > >A, > Plan B, Universal, "Safari way") > > Another example wmode for , FF acts differently, > > so I really miss "which-browser" feature detection > > On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl > wrote: > > > > > > - Ursprüngliche Mail - > >>> even in 2009 it was considered bad: > >https://www.sitepoint.com/why- > >>> browser-sniffing-stinks/ > >>> and in case that is not enough, read what the guy that invented > modernizr > >>> has to say: > >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- > >>> how-i-learned-whats-so-bad-about-browser-sniffing/ > >>> > >>> > >> I do not trust anyone who says "don't do it this way" but doesn't > say how > >> to do it! > >> > >> There are several of "if (isBrowserX()) {...} else {...}" in > >Wicket > JS code > >> and they served well for the last decade. > >> Since there are several other *Java* libraries for user agent > detection > >> this means that someone still finds them useful despite what > >other > people > >> claim. > > > > unreliable things wont get reliably by pointing into the past and > then telling that your fater did it the same way > > > > nowadays you would use feature detection, see: > > > > > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection > > > >> > >> > >>> btw: > >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, > guess > >>> why... > >>> https://github.com/pieroxy/java-user-agent-detection/releases -> > last > >>> release from september 2017... > >>> > >>> > >> Sep 2017 is like yesterday > > > > (all only MAJOR releases!) > > > > 28. September 2017 - Firefox 56 > > 14. November 2017 - Firefox 57 Quantum > > 23. Januar 2018 - Firefox 58 > > 13. März 2018 - Firefox 59 > > > > 2017-09-05 - Chrome 61.0.3163 > > 2017-10-17 - Chrome 62.0.3202 > > 2017-12-05 - Chrome 63.0.3239 > > 2018-01-23 - Chrome 64.0.3282 > > 2018-03-06 - Chrome 65.0.3325 > > > > and this is just 2 desktop ones! I dont want to talk about the > >loads > of updates my android device got in that time (firefox mobile, > >chrome > and samsung internet!) - oh, and btw: they still lie about the user > agent all time dont get me wrong, but sep 17 is freaking old in > case you need to reliably detect the browser! > > > > -- > WBR > Maxim aka solomax > > > > > > > >-- > >WBR > >Maxim aka solomax >
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Let's keep this topics separate. Any improvements to browser detection would be backwards compatible, right? Sven Am 29. März 2018 11:10:55 MESZ schrieb Maxim Solodovnik: >Should I close my PR and start new discussion? :)) > >On Thu, Mar 29, 2018 at 12:52 PM, Sven Meier wrote: >> BTW I'd rather keep the current solution as it is and discuss >releasing Wicket 8 :) >> >> Sven >> >> Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier : >>>It's perfectly fine to use whatever tool gets the job done. People >say >>>how to do it instead, but no one has to follow the advice. >>> >>>IMHO it's something different for a framework to offer an API on top >of >>>a something that doesn't even work reliably: >>>Wicket's browser detection is using regex-matching on identifiers >>>generated by browsers to make it difficult to be detected :P. >>> >>>Regarding integrating of mentioned libraries: >>> >>> LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() >>> >>>I don't see a benefit of having that in Wicket or wicketstuff. >>>Integrating modernizr might be more interesting, but I doubt many >>>people need browser detection on the server. >>> >>>Have fun >>>Sven >>> >>> >>> >>>Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik >>> : "you would use feature detection" - unfortunately it doesn't work Good real-life example is WebRtc: you can check it is supported, then you need to know which browser your client is using (Plan >A, Plan B, Universal, "Safari way") Another example wmode for , FF acts differently, so I really miss "which-browser" feature detection On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl wrote: > > > - Ursprüngliche Mail - >>> even in 2009 it was considered bad: >https://www.sitepoint.com/why- >>> browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that invented modernizr >>> has to say: >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >> I do not trust anyone who says "don't do it this way" but doesn't say how >> to do it! >> >> There are several of "if (isBrowserX()) {...} else {...}" in >Wicket JS code >> and they served well for the last decade. >> Since there are several other *Java* libraries for user agent detection >> this means that someone still finds them useful despite what >other people >> claim. > > unreliable things wont get reliably by pointing into the past and then telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection > >> >> >>> btw: >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >>> why... >>> https://github.com/pieroxy/java-user-agent-detection/releases -> last >>> release from september 2017... >>> >>> >> Sep 2017 is like yesterday > > (all only MAJOR releases!) > > 28. September 2017 - Firefox 56 > 14. November 2017 - Firefox 57 Quantum > 23. Januar 2018 - Firefox 58 > 13. März 2018 - Firefox 59 > > 2017-09-05 - Chrome 61.0.3163 > 2017-10-17 - Chrome 62.0.3202 > 2017-12-05 - Chrome 63.0.3239 > 2018-01-23 - Chrome 64.0.3282 > 2018-03-06 - Chrome 65.0.3325 > > and this is just 2 desktop ones! I dont want to talk about the >loads of updates my android device got in that time (firefox mobile, >chrome and samsung internet!) - oh, and btw: they still lie about the user agent all time dont get me wrong, but sep 17 is freaking old in case you need to reliably detect the browser! -- WBR Maxim aka solomax > > > >-- >WBR >Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
Should I close my PR and start new discussion? :)) On Thu, Mar 29, 2018 at 12:52 PM, Sven Meierwrote: > BTW I'd rather keep the current solution as it is and discuss releasing > Wicket 8 :) > > Sven > > Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier : >>It's perfectly fine to use whatever tool gets the job done. People say >>how to do it instead, but no one has to follow the advice. >> >>IMHO it's something different for a framework to offer an API on top of >>a something that doesn't even work reliably: >>Wicket's browser detection is using regex-matching on identifiers >>generated by browsers to make it difficult to be detected :P. >> >>Regarding integrating of mentioned libraries: >> >> LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() >> >>I don't see a benefit of having that in Wicket or wicketstuff. >>Integrating modernizr might be more interesting, but I doubt many >>people need browser detection on the server. >> >>Have fun >>Sven >> >> >> >>Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik >> : >>>"you would use feature detection" - unfortunately it doesn't work >>>Good real-life example is WebRtc: you can check it is supported, >>>then you need to know which browser your client is using (Plan A, >>>Plan B, Universal, "Safari way") >>> >>>Another example wmode for , FF acts differently, >>> >>>so I really miss "which-browser" feature detection >>> >>>On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl >>> wrote: - Ursprüngliche Mail - >> even in 2009 it was considered bad: https://www.sitepoint.com/why- >> browser-sniffing-stinks/ >> and in case that is not enough, read what the guy that invented >>>modernizr >> has to say: >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >> how-i-learned-whats-so-bad-about-browser-sniffing/ >> >> > I do not trust anyone who says "don't do it this way" but doesn't >>>say how > to do it! > > There are several of "if (isBrowserX()) {...} else {...}" in Wicket >>>JS code > and they served well for the last decade. > Since there are several other *Java* libraries for user agent >>>detection > this means that someone still finds them useful despite what other >>>people > claim. unreliable things wont get reliably by pointing into the past and >>>then telling that your fater did it the same way nowadays you would use feature detection, see: >>>https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection > > >> btw: >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >>>guess >> why... >> https://github.com/pieroxy/java-user-agent-detection/releases -> >>>last >> release from september 2017... >> >> > Sep 2017 is like yesterday (all only MAJOR releases!) 28. September 2017 - Firefox 56 14. November 2017 - Firefox 57 Quantum 23. Januar 2018 - Firefox 58 13. März 2018 - Firefox 59 2017-09-05 - Chrome 61.0.3163 2017-10-17 - Chrome 62.0.3202 2017-12-05 - Chrome 63.0.3239 2018-01-23 - Chrome 64.0.3282 2018-03-06 - Chrome 65.0.3325 and this is just 2 desktop ones! I dont want to talk about the loads >>>of updates my android device got in that time (firefox mobile, chrome >>>and samsung internet!) - oh, and btw: they still lie about the user >>>agent all time dont get me wrong, but sep 17 is freaking old in >>>case you need to reliably detect the browser! >>> >>> >>> >>>-- >>>WBR >>>Maxim aka solomax -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
BTW I'd rather keep the current solution as it is and discuss releasing Wicket 8 :) Sven Am 29. März 2018 07:49:02 MESZ schrieb Sven Meier: >It's perfectly fine to use whatever tool gets the job done. People say >how to do it instead, but no one has to follow the advice. > >IMHO it's something different for a framework to offer an API on top of >a something that doesn't even work reliably: >Wicket's browser detection is using regex-matching on identifiers >generated by browsers to make it difficult to be detected :P. > >Regarding integrating of mentioned libraries: > > LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() > >I don't see a benefit of having that in Wicket or wicketstuff. >Integrating modernizr might be more interesting, but I doubt many >people need browser detection on the server. > >Have fun >Sven > > > >Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik > : >>"you would use feature detection" - unfortunately it doesn't work >>Good real-life example is WebRtc: you can check it is supported, >>then you need to know which browser your client is using (Plan A, >>Plan B, Universal, "Safari way") >> >>Another example wmode for , FF acts differently, >> >>so I really miss "which-browser" feature detection >> >>On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl >> wrote: >>> >>> >>> - Ursprüngliche Mail - > even in 2009 it was considered bad: https://www.sitepoint.com/why- > browser-sniffing-stinks/ > and in case that is not enough, read what the guy that invented >>modernizr > has to say: > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > how-i-learned-whats-so-bad-about-browser-sniffing/ > > I do not trust anyone who says "don't do it this way" but doesn't >>say how to do it! There are several of "if (isBrowserX()) {...} else {...}" in Wicket >>JS code and they served well for the last decade. Since there are several other *Java* libraries for user agent >>detection this means that someone still finds them useful despite what other >>people claim. >>> >>> unreliable things wont get reliably by pointing into the past and >>then telling that your fater did it the same way >>> >>> nowadays you would use feature detection, see: >>> >>> >>https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection >>> > btw: > https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >>guess > why... > https://github.com/pieroxy/java-user-agent-detection/releases -> >>last > release from september 2017... > > Sep 2017 is like yesterday >>> >>> (all only MAJOR releases!) >>> >>> 28. September 2017 - Firefox 56 >>> 14. November 2017 - Firefox 57 Quantum >>> 23. Januar 2018 - Firefox 58 >>> 13. März 2018 - Firefox 59 >>> >>> 2017-09-05 - Chrome 61.0.3163 >>> 2017-10-17 - Chrome 62.0.3202 >>> 2017-12-05 - Chrome 63.0.3239 >>> 2018-01-23 - Chrome 64.0.3282 >>> 2018-03-06 - Chrome 65.0.3325 >>> >>> and this is just 2 desktop ones! I dont want to talk about the loads >>of updates my android device got in that time (firefox mobile, chrome >>and samsung internet!) - oh, and btw: they still lie about the user >>agent all time dont get me wrong, but sep 17 is freaking old in >>case you need to reliably detect the browser! >> >> >> >>-- >>WBR >>Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
It's perfectly fine to use whatever tool gets the job done. People say how to do it instead, but no one has to follow the advice. IMHO it's something different for a framework to offer an API on top of a something that doesn't even work reliably: Wicket's browser detection is using regex-matching on identifiers generated by browsers to make it difficult to be detected :P. Regarding integrating of mentioned libraries: LibraryXY.browser(clientInfo.getUserAgent()).supportsZ() I don't see a benefit of having that in Wicket or wicketstuff. Integrating modernizr might be more interesting, but I doubt many people need browser detection on the server. Have fun Sven Am 29. März 2018 04:34:00 MESZ schrieb Maxim Solodovnik: >"you would use feature detection" - unfortunately it doesn't work >Good real-life example is WebRtc: you can check it is supported, >then you need to know which browser your client is using (Plan A, >Plan B, Universal, "Safari way") > >Another example wmode for , FF acts differently, > >so I really miss "which-browser" feature detection > >On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachl > wrote: >> >> >> - Ursprüngliche Mail - even in 2009 it was considered bad: https://www.sitepoint.com/why- browser-sniffing-stinks/ and in case that is not enough, read what the guy that invented >modernizr has to say: http://farukat.es/journal/2011/02/499-lest-we-forget-or- how-i-learned-whats-so-bad-about-browser-sniffing/ >>> I do not trust anyone who says "don't do it this way" but doesn't >say how >>> to do it! >>> >>> There are several of "if (isBrowserX()) {...} else {...}" in Wicket >JS code >>> and they served well for the last decade. >>> Since there are several other *Java* libraries for user agent >detection >>> this means that someone still finds them useful despite what other >people >>> claim. >> >> unreliable things wont get reliably by pointing into the past and >then telling that your fater did it the same way >> >> nowadays you would use feature detection, see: >> >> >https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection >> >>> >>> btw: https://github.com/HaraldWalker/user-agent-utils -> this is EOL, >guess why... https://github.com/pieroxy/java-user-agent-detection/releases -> >last release from september 2017... >>> Sep 2017 is like yesterday >> >> (all only MAJOR releases!) >> >> 28. September 2017 - Firefox 56 >> 14. November 2017 - Firefox 57 Quantum >> 23. Januar 2018 - Firefox 58 >> 13. März 2018 - Firefox 59 >> >> 2017-09-05 - Chrome 61.0.3163 >> 2017-10-17 - Chrome 62.0.3202 >> 2017-12-05 - Chrome 63.0.3239 >> 2018-01-23 - Chrome 64.0.3282 >> 2018-03-06 - Chrome 65.0.3325 >> >> and this is just 2 desktop ones! I dont want to talk about the loads >of updates my android device got in that time (firefox mobile, chrome >and samsung internet!) - oh, and btw: they still lie about the user >agent all time dont get me wrong, but sep 17 is freaking old in >case you need to reliably detect the browser! > > > >-- >WBR >Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
"you would use feature detection" - unfortunately it doesn't work Good real-life example is WebRtc: you can check it is supported, then you need to know which browser your client is using (Plan A, Plan B, Universal, "Safari way") Another example wmode for , FF acts differently, so I really miss "which-browser" feature detection On Thu, Mar 29, 2018 at 5:31 AM, Korbinian Bachlwrote: > > > - Ursprüngliche Mail - >>> even in 2009 it was considered bad: https://www.sitepoint.com/why- >>> browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that invented modernizr >>> has to say: >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >>> how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >> I do not trust anyone who says "don't do it this way" but doesn't say how >> to do it! >> >> There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS code >> and they served well for the last decade. >> Since there are several other *Java* libraries for user agent detection >> this means that someone still finds them useful despite what other people >> claim. > > unreliable things wont get reliably by pointing into the past and then > telling that your fater did it the same way > > nowadays you would use feature detection, see: > > https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection > >> >> >>> btw: >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >>> why... >>> https://github.com/pieroxy/java-user-agent-detection/releases -> last >>> release from september 2017... >>> >>> >> Sep 2017 is like yesterday > > (all only MAJOR releases!) > > 28. September 2017 - Firefox 56 > 14. November 2017 - Firefox 57 Quantum > 23. Januar 2018 - Firefox 58 > 13. März 2018 - Firefox 59 > > 2017-09-05 - Chrome 61.0.3163 > 2017-10-17 - Chrome 62.0.3202 > 2017-12-05 - Chrome 63.0.3239 > 2018-01-23 - Chrome 64.0.3282 > 2018-03-06 - Chrome 65.0.3325 > > and this is just 2 desktop ones! I dont want to talk about the loads of > updates my android device got in that time (firefox mobile, chrome and > samsung internet!) - oh, and btw: they still lie about the user agent all > time dont get me wrong, but sep 17 is freaking old in case you need to > reliably detect the browser! -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
- Ursprüngliche Mail - >> even in 2009 it was considered bad: https://www.sitepoint.com/why- >> browser-sniffing-stinks/ >> and in case that is not enough, read what the guy that invented modernizr >> has to say: >> http://farukat.es/journal/2011/02/499-lest-we-forget-or- >> how-i-learned-whats-so-bad-about-browser-sniffing/ >> >> > I do not trust anyone who says "don't do it this way" but doesn't say how > to do it! > > There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS code > and they served well for the last decade. > Since there are several other *Java* libraries for user agent detection > this means that someone still finds them useful despite what other people > claim. unreliable things wont get reliably by pointing into the past and then telling that your fater did it the same way nowadays you would use feature detection, see: https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection > > >> btw: >> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >> why... >> https://github.com/pieroxy/java-user-agent-detection/releases -> last >> release from september 2017... >> >> > Sep 2017 is like yesterday (all only MAJOR releases!) 28. September 2017 - Firefox 56 14. November 2017 - Firefox 57 Quantum 23. Januar 2018 - Firefox 58 13. März 2018 - Firefox 59 2017-09-05 - Chrome 61.0.3163 2017-10-17 - Chrome 62.0.3202 2017-12-05 - Chrome 63.0.3239 2018-01-23 - Chrome 64.0.3282 2018-03-06 - Chrome 65.0.3325 and this is just 2 desktop ones! I dont want to talk about the loads of updates my android device got in that time (firefox mobile, chrome and samsung internet!) - oh, and btw: they still lie about the user agent all time dont get me wrong, but sep 17 is freaking old in case you need to reliably detect the browser!
Re: [DISCUSSION] WICKET-6544 mobile browser detection
On Wed, Mar 28, 2018 at 7:19 PM, Korbinian Bachl < korbinian.ba...@whiskyworld.de> wrote: > IMHO: its 2018 and any browser sniffing has to be dropped at all, as it > has no use anyway and its not working reliable... what for do we need this > at all? > > even in 2009 it was considered bad: https://www.sitepoint.com/why- > browser-sniffing-stinks/ > and in case that is not enough, read what the guy that invented modernizr > has to say: > http://farukat.es/journal/2011/02/499-lest-we-forget-or- > how-i-learned-whats-so-bad-about-browser-sniffing/ > > I do not trust anyone who says "don't do it this way" but doesn't say how to do it! There are several of "if (isBrowserX()) {...} else {...}" in Wicket JS code and they served well for the last decade. Since there are several other *Java* libraries for user agent detection this means that someone still finds them useful despite what other people claim. > btw: > https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess > why... > https://github.com/pieroxy/java-user-agent-detection/releases -> last > release from september 2017... > > Sep 2017 is like yesterday > > - Ursprüngliche Mail - > > Von: "Maxim Solodovnik" <solomax...@gmail.com> > > An: dev@wicket.apache.org > > Gesendet: Mittwoch, 28. März 2018 18:04:03 > > Betreff: [DISCUSSION] WICKET-6544 mobile browser detection > > > Hello All, > > > > While reviewing WICKET-6544 Martin propose to use JS library for this > task > > Here are some examples: > > https://github.com/pieroxy/java-user-agent-detection or > > https://github.com/HaraldWalker/user-agent-utils > > > > WDYT > > > > -- > > WBR > > Maxim aka solomax >
Re: [DISCUSSION] WICKET-6544 mobile browser detection
It is always good to know you are working with IE :))) I would review detected browser list (for ex. to match this list: https://developer.mozilla.org/en-US/docs/Web/API/AudioNode#Browser_compatibility) It always can be implemented as tiny module at wicketstuff On Thu, Mar 29, 2018 at 12:16 AM, Sven Meier <s...@meiers.net> wrote: > I agree with Korbinian: IMHO we should drop that feature. > > Sven > > > > Am 28.03.2018 um 18:35 schrieb Maxim Solodovnik: >> >> I also noticed all libraries are old :( >> >> Not sure "Drop this feature" is great idea >> Some users (including me) might find it useful :)) >> >> BTW why do we have both? >> isBrowserMozilla()) >> isBrowserMozillaFirefox() >> >> On Wed, Mar 28, 2018 at 11:19 PM, Korbinian Bachl >> <korbinian.ba...@whiskyworld.de> wrote: >>> >>> IMHO: its 2018 and any browser sniffing has to be dropped at all, as it >>> has no use anyway and its not working reliable... what for do we need this >>> at all? >>> >>> even in 2009 it was considered bad: >>> https://www.sitepoint.com/why-browser-sniffing-stinks/ >>> and in case that is not enough, read what the guy that invented modernizr >>> has to say: >>> >>> http://farukat.es/journal/2011/02/499-lest-we-forget-or-how-i-learned-whats-so-bad-about-browser-sniffing/ >>> >>> >>> btw: >>> https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess >>> why... >>> https://github.com/pieroxy/java-user-agent-detection/releases -> last >>> release from september 2017... >>> >>> >>> - Ursprüngliche Mail - >>>> >>>> Von: "Maxim Solodovnik" <solomax...@gmail.com> >>>> An: dev@wicket.apache.org >>>> Gesendet: Mittwoch, 28. März 2018 18:04:03 >>>> Betreff: [DISCUSSION] WICKET-6544 mobile browser detection >>>> Hello All, >>>> >>>> While reviewing WICKET-6544 Martin propose to use JS library for this >>>> task >>>> Here are some examples: >>>> https://github.com/pieroxy/java-user-agent-detection or >>>> https://github.com/HaraldWalker/user-agent-utils >>>> >>>> WDYT >>>> >>>> -- >>>> WBR >>>> Maxim aka solomax >> >> >> > -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
I agree with Korbinian: IMHO we should drop that feature. Sven Am 28.03.2018 um 18:35 schrieb Maxim Solodovnik: I also noticed all libraries are old :( Not sure "Drop this feature" is great idea Some users (including me) might find it useful :)) BTW why do we have both? isBrowserMozilla()) isBrowserMozillaFirefox() On Wed, Mar 28, 2018 at 11:19 PM, Korbinian Bachl <korbinian.ba...@whiskyworld.de> wrote: IMHO: its 2018 and any browser sniffing has to be dropped at all, as it has no use anyway and its not working reliable... what for do we need this at all? even in 2009 it was considered bad: https://www.sitepoint.com/why-browser-sniffing-stinks/ and in case that is not enough, read what the guy that invented modernizr has to say: http://farukat.es/journal/2011/02/499-lest-we-forget-or-how-i-learned-whats-so-bad-about-browser-sniffing/ btw: https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess why... https://github.com/pieroxy/java-user-agent-detection/releases -> last release from september 2017... - Ursprüngliche Mail - Von: "Maxim Solodovnik" <solomax...@gmail.com> An: dev@wicket.apache.org Gesendet: Mittwoch, 28. März 2018 18:04:03 Betreff: [DISCUSSION] WICKET-6544 mobile browser detection Hello All, While reviewing WICKET-6544 Martin propose to use JS library for this task Here are some examples: https://github.com/pieroxy/java-user-agent-detection or https://github.com/HaraldWalker/user-agent-utils WDYT -- WBR Maxim aka solomax
Re: [DISCUSSION] WICKET-6544 mobile browser detection
I also noticed all libraries are old :( Not sure "Drop this feature" is great idea Some users (including me) might find it useful :)) BTW why do we have both? isBrowserMozilla()) isBrowserMozillaFirefox() On Wed, Mar 28, 2018 at 11:19 PM, Korbinian Bachl <korbinian.ba...@whiskyworld.de> wrote: > IMHO: its 2018 and any browser sniffing has to be dropped at all, as it has > no use anyway and its not working reliable... what for do we need this at all? > > even in 2009 it was considered bad: > https://www.sitepoint.com/why-browser-sniffing-stinks/ > and in case that is not enough, read what the guy that invented modernizr has > to say: > http://farukat.es/journal/2011/02/499-lest-we-forget-or-how-i-learned-whats-so-bad-about-browser-sniffing/ > > > btw: > https://github.com/HaraldWalker/user-agent-utils -> this is EOL, guess why... > https://github.com/pieroxy/java-user-agent-detection/releases -> last release > from september 2017... > > > - Ursprüngliche Mail - >> Von: "Maxim Solodovnik" <solomax...@gmail.com> >> An: dev@wicket.apache.org >> Gesendet: Mittwoch, 28. März 2018 18:04:03 >> Betreff: [DISCUSSION] WICKET-6544 mobile browser detection > >> Hello All, >> >> While reviewing WICKET-6544 Martin propose to use JS library for this task >> Here are some examples: >> https://github.com/pieroxy/java-user-agent-detection or >> https://github.com/HaraldWalker/user-agent-utils >> >> WDYT >> >> -- >> WBR >> Maxim aka solomax -- WBR Maxim aka solomax