[web2py] web2py 2.3.1 is out
Web2py 2.3.1 is out! - new virtual fields syntax: ``db.define_table('person',Field('name'),Field.Virtual('namey',lambda row: ro\ w.person.name+'y'))`` - db.thing(name='Cohen',_orderby=db.thing.name), thanks Yair - made many modules Python 3.3 friendly (compile but not tested) - better welcome css, thanks Paolo - jQuery 1.8.3 - Bootstrap 2.2.2 - Modernizr 2.6.2 (custom full options) - integration with analyitics.js (0.2.0) - better scheduler, thanks Niphlod - page and media preview in wiki, thanks Niphlod - create new auth.wiki page from slug model, thanks Nico - conditional menus with auth.wiki(menugroups=['wiki_editor']) - better security in grid/smartgrid - allow LOADing multiple grids, thanks Niphlod - auth.settings.login_onfail, thanks Yair - better handling of session files for speed - added heroku support (experimental) - added rocket support for IPV6, thanks Chirs Winebrinner - more customizable menus with MENU(li_first, li_last..) - added support for paymentech (gluon/contrib/paymentech.py) - fixed broken cron - fixed possible xss with share.js - many bug fixes. Closed more than 50 tickets since 2.2.1 = IMPORTANT SECURITY ALERT = After upgrade you should run cp applications/welcome/static/js/share.js applications/yourapp/static/js/share.js for any one of yourapps using share.js for social bookmarking. The js contains a bug which may be exploited for xss. This is a minor xss issue and no malicious data reaches the web2py server but nevertheless I strongly suggest you fix it. I sincerely thank JPCERT Coordination Center for reporting this issue. === --
Re: [web2py] web2py 2.3.1?
Just tested all four applications with nightly build and all works as expected. If we upgrade production, break it and start losing orders, it will be brutal here, but I'll scream for help... ;) On Tue, Dec 4, 2012 at 2:26 AM, Nico Zanferrari nicoz...@gmail.com wrote: I've notice yesterday that the DEBUG button on the admin interface has problems: it always gives just the error invalid view (debug/interact.html). 2012/12/4 rif feric...@gmail.com I've been using trunk for the last three weeks and I didn't notice any problems. -rif -- -- --
Re: [web2py] web2py 2.3.1?
Can you try again. The file is there but looks like it was not committed to git. Did you get from github? On Tuesday, 4 December 2012 01:26:45 UTC-6, Nico Zanferrari wrote: I've notice yesterday that the DEBUG button on the admin interface has problems: it always gives just the error invalid view (debug/interact.html). 2012/12/4 rif feri...@gmail.com javascript: I've been using trunk for the last three weeks and I didn't notice any problems. -rif -- --
Re: [web2py] web2py 2.3.1?
This is the right attitude! On Tuesday, 4 December 2012 07:05:02 UTC-6, Adi wrote: Just tested all four applications with nightly build and all works as expected. If we upgrade production, break it and start losing orders, it will be brutal here, but I'll scream for help... ;) On Tue, Dec 4, 2012 at 2:26 AM, Nico Zanferrari nico...@gmail.comjavascript: wrote: I've notice yesterday that the DEBUG button on the admin interface has problems: it always gives just the error invalid view (debug/interact.html). 2012/12/4 rif feri...@gmail.com javascript: I've been using trunk for the last three weeks and I didn't notice any problems. -rif -- -- --
Re: [web2py] web2py 2.3.1?
Hello, I just check the trunk and don't see any improvement at the dropmenu script level. I appreciate the little script to allow the bootstrap menu to works as superfish use to work, but actually they are pretty not usable in production. I explained, it may be possible that the problem I face have be not notice by someone who not use the welcome layout or use it with the default bootstrap top nav bar color (black). But the hover of the main entry of the top navbar are not working properly and it can be appreciate when use navbar inverse bootstrap class. The hover sometimes stick other time disappear, etc. Also, when you quit the main entry to go in the submenu, sometime they just close baldly. I try to tweak the script, but I don't understand it pretty well. I will try again. Maybe the one that implement that could have look at it. I think it is Paolo, but I am not sure. Thanks. Richard On Tue, Dec 4, 2012 at 9:56 AM, Massimo Di Pierro massimo.dipie...@gmail.com wrote: he file is there but looks like it was not committed to git. Did you get from github? --
Re: [web2py] web2py 2.3.1?
I found that just replacing delay() and fade*() by show() and hide() solve most problem. Here the code : // this code improves bootstrap menus and adds dropdown support jQuery(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').length) jQuery(this).addClass('dropdown-submenu'); }); function hoverMenu(){ var wid = document.documentElement.clientWidth; //faster than $(window).width() and cross browser if (wid=980){ jQuery('ul.nav a.dropdown-toggle').parent().hover(function(){ mi = jQuery(this).addClass('open'); mi.children('.dropdown-menu').stop(true, true).show(); }, function(){ mi = jQuery(this); mi.children('.dropdown-menu').stop(true, true).hide(0, function(){mi.removeClass('open')}); }); }; } hoverMenu(); // first page load jQuery(window).resize(hoverMenu); // on resize event jQuery('ul.nav li.dropdown a').click(function(){window.location=jQuery(this).attr('href');}); // make all buttons bootstrap buttons jQuery('button, form input[type=submit], form input[type=button]').addClass('btn'); }); Richard On Tue, Dec 4, 2012 at 1:03 PM, Richard Vézina ml.richard.vez...@gmail.comwrote: Hello, I just check the trunk and don't see any improvement at the dropmenu script level. I appreciate the little script to allow the bootstrap menu to works as superfish use to work, but actually they are pretty not usable in production. I explained, it may be possible that the problem I face have be not notice by someone who not use the welcome layout or use it with the default bootstrap top nav bar color (black). But the hover of the main entry of the top navbar are not working properly and it can be appreciate when use navbar inverse bootstrap class. The hover sometimes stick other time disappear, etc. Also, when you quit the main entry to go in the submenu, sometime they just close baldly. I try to tweak the script, but I don't understand it pretty well. I will try again. Maybe the one that implement that could have look at it. I think it is Paolo, but I am not sure. Thanks. Richard On Tue, Dec 4, 2012 at 9:56 AM, Massimo Di Pierro massimo.dipie...@gmail.com wrote: he file is there but looks like it was not committed to git. Did you get from github? --
Re: [web2py] web2py 2.3.1?
This could be interesting add on : http://cherne.net/brian/resources/jquery.hoverIntent.html Richard On Tue, Dec 4, 2012 at 1:43 PM, Richard Vézina ml.richard.vez...@gmail.comwrote: I found that just replacing delay() and fade*() by show() and hide() solve most problem. Here the code : // this code improves bootstrap menus and adds dropdown support jQuery(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').length) jQuery(this).addClass('dropdown-submenu'); }); function hoverMenu(){ var wid = document.documentElement.clientWidth; //faster than $(window).width() and cross browser if (wid=980){ jQuery('ul.nav a.dropdown-toggle').parent().hover(function(){ mi = jQuery(this).addClass('open'); mi.children('.dropdown-menu').stop(true, true).show(); }, function(){ mi = jQuery(this); mi.children('.dropdown-menu').stop(true, true).hide(0, function(){mi.removeClass('open')}); }); }; } hoverMenu(); // first page load jQuery(window).resize(hoverMenu); // on resize event jQuery('ul.nav li.dropdown a').click(function(){window.location=jQuery(this).attr('href');}); // make all buttons bootstrap buttons jQuery('button, form input[type=submit], form input[type=button]').addClass('btn'); }); Richard On Tue, Dec 4, 2012 at 1:03 PM, Richard Vézina ml.richard.vez...@gmail.com wrote: Hello, I just check the trunk and don't see any improvement at the dropmenu script level. I appreciate the little script to allow the bootstrap menu to works as superfish use to work, but actually they are pretty not usable in production. I explained, it may be possible that the problem I face have be not notice by someone who not use the welcome layout or use it with the default bootstrap top nav bar color (black). But the hover of the main entry of the top navbar are not working properly and it can be appreciate when use navbar inverse bootstrap class. The hover sometimes stick other time disappear, etc. Also, when you quit the main entry to go in the submenu, sometime they just close baldly. I try to tweak the script, but I don't understand it pretty well. I will try again. Maybe the one that implement that could have look at it. I think it is Paolo, but I am not sure. Thanks. Richard On Tue, Dec 4, 2012 at 9:56 AM, Massimo Di Pierro massimo.dipie...@gmail.com wrote: he file is there but looks like it was not committed to git. Did you get from github? --
Re: [web2py] web2py 2.3.1?
On Tuesday, December 4, 2012 1:49:24 PM UTC-5, Richard wrote: This could be interesting add on : http://cherne.net/brian/resources/jquery.hoverIntent.html Yes, that was used with the Superfish menu ( http://users.tpg.com.au/j_birch/plugins/superfish/#faq) -- makes a big difference. Anthony --
Re: [web2py] web2py 2.3.1?
I'm not the creator of the code in web2py_bootstrap.js that manages the dropdown behavior, I only added the code to adjust it on resize event. Originally the bootstrap dropdown hasn't a hover event (in this article the reasons explained http://markdotto.com/2012/02/27/bootstrap-explained-dropdowns/) The code in web2py makes possible to show/hide - with a fade effect - the dropdown main container, while the menu and submenus items navigation is provided by bootstrap itself. That said, I don't think that the odd behavior noticed by you is due to js code. I didn't have any notice of that (actually topbar has class nav-inverse) in IE9, IE8, FF last versions, OP last versions and CH last versions on windows7. Only in IE7 web2py dropdown has some showing issue but I have already submitted a patch. Could you delete following rule in web2py_bootstrap.css (in other rules section row 178) and see if your issue disappears? .navbar-inner{ position:relative; /*unnecessary ??*/ } Anyway if you are interested, there is a small snippet in order to use hoverintent with bootstrap dropdown herehttp://stackoverflow.com/a/12960711 Il giorno martedì 4 dicembre 2012 19:49:24 UTC+1, Richard ha scritto: This could be interesting add on : http://cherne.net/brian/resources/jquery.hoverIntent.html Richard On Tue, Dec 4, 2012 at 1:43 PM, Richard Vézina ml.richa...@gmail.comjavascript: wrote: I found that just replacing delay() and fade*() by show() and hide() solve most problem. Here the code : // this code improves bootstrap menus and adds dropdown support jQuery(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').length) jQuery(this).addClass('dropdown-submenu'); }); function hoverMenu(){ var wid = document.documentElement.clientWidth; //faster than $(window).width() and cross browser if (wid=980){ jQuery('ul.nav a.dropdown-toggle').parent().hover(function(){ mi = jQuery(this).addClass('open'); mi.children('.dropdown-menu').stop(true, true).show(); }, function(){ mi = jQuery(this); mi.children('.dropdown-menu').stop(true, true).hide(0, function(){mi.removeClass('open')}); }); }; } hoverMenu(); // first page load jQuery(window).resize(hoverMenu); // on resize event jQuery('ul.nav li.dropdown a').click(function(){window.location=jQuery(this).attr('href');}); // make all buttons bootstrap buttons jQuery('button, form input[type=submit], form input[type=button]').addClass('btn'); }); Richard On Tue, Dec 4, 2012 at 1:03 PM, Richard Vézina ml.richa...@gmail.comjavascript: wrote: Hello, I just check the trunk and don't see any improvement at the dropmenu script level. I appreciate the little script to allow the bootstrap menu to works as superfish use to work, but actually they are pretty not usable in production. I explained, it may be possible that the problem I face have be not notice by someone who not use the welcome layout or use it with the default bootstrap top nav bar color (black). But the hover of the main entry of the top navbar are not working properly and it can be appreciate when use navbar inverse bootstrap class. The hover sometimes stick other time disappear, etc. Also, when you quit the main entry to go in the submenu, sometime they just close baldly. I try to tweak the script, but I don't understand it pretty well. I will try again. Maybe the one that implement that could have look at it. I think it is Paolo, but I am not sure. Thanks. Richard On Tue, Dec 4, 2012 at 9:56 AM, Massimo Di Pierro massimo@gmail.comjavascript: wrote: he file is there but looks like it was not committed to git. Did you get from github? --
Re: [web2py] web2py 2.3.1?
I didn't check carefully how to integrate it. Does it as simple as just add a js file?? Richard On Tue, Dec 4, 2012 at 2:25 PM, Anthony abasta...@gmail.com wrote: On Tuesday, December 4, 2012 1:49:24 PM UTC-5, Richard wrote: This could be interesting add on : http://cherne.net/brian/**resources/jquery.hoverIntent.**htmlhttp://cherne.net/brian/resources/jquery.hoverIntent.html Yes, that was used with the Superfish menu ( http://users.tpg.com.au/j_birch/plugins/superfish/#faq) -- makes a big difference. Anthony -- --
Re: [web2py] web2py 2.3.1?
So, I did that in layout.html and it improves thing. The only little glitch is that subSubMenu are not displaying at the rigth place, they just show below the actual a hover element, they should appear beside this element. I try to figure out which piece of web2py_bootstrap.js is responsible of that behavior : script src={{=URL('static','js/jquery.hoverIntent.minified.js')}}/script script type=text/javascript language=javascript charset=utf-8 // ![CDATA[ $(document).ready(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); var config = { over: showBootrapSubmenu, timeout: 300, out: hideBootrapSubmenu }; function showBootrapSubmenu(){ $(this).addClass('open'); } function hideBootrapSubmenu(){ $(this).removeClass('open'); } //Hover intent for Submenus $(.dropdown).hoverIntent(config); }); // ]] /script To get the minified version of hoverIntent v6 : http://cherne.net/brian/resources/jquery.hoverIntent.minified.js Richard On Tue, Dec 4, 2012 at 3:25 PM, Paolo Caruccio paolo.carucci...@gmail.comwrote: I'm not the creator of the code in web2py_bootstrap.js that manages the dropdown behavior, I only added the code to adjust it on resize event. Originally the bootstrap dropdown hasn't a hover event (in this article the reasons explained http://markdotto.com/2012/02/27/bootstrap-explained-dropdowns/) The code in web2py makes possible to show/hide - with a fade effect - the dropdown main container, while the menu and submenus items navigation is provided by bootstrap itself. That said, I don't think that the odd behavior noticed by you is due to js code. I didn't have any notice of that (actually topbar has class nav-inverse) in IE9, IE8, FF last versions, OP last versions and CH last versions on windows7. Only in IE7 web2py dropdown has some showing issue but I have already submitted a patch. Could you delete following rule in web2py_bootstrap.css (in other rules section row 178) and see if your issue disappears? .navbar-inner{ position:relative; /*unnecessary ??*/ } Anyway if you are interested, there is a small snippet in order to use hoverintent with bootstrap dropdown herehttp://stackoverflow.com/a/12960711 Il giorno martedì 4 dicembre 2012 19:49:24 UTC+1, Richard ha scritto: This could be interesting add on : http://cherne.net/brian/**resources/jquery.hoverIntent.**htmlhttp://cherne.net/brian/resources/jquery.hoverIntent.html Richard On Tue, Dec 4, 2012 at 1:43 PM, Richard Vézina ml.richa...@gmail.comwrote: I found that just replacing delay() and fade*() by show() and hide() solve most problem. Here the code : // this code improves bootstrap menus and adds dropdown support jQuery(function(){ jQuery('.navlia').each(**function(){ if(jQuery(this).parent().find(**'ul').length) jQuery(this).attr({'class':'**dropdown-toggle','data-toggle'**:'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').**length) jQuery(this).addClass('**dropdown-submenu'); }); function hoverMenu(){ var wid = document.documentElement.**clientWidth; //faster than $(window).width() and cross browser if (wid=980){ jQuery('ul.nav a.dropdown-toggle').parent().**hover(function(){ mi = jQuery(this).addClass('open'); mi.children('.dropdown-menu').**stop(true, true).show(); }, function(){ mi = jQuery(this); mi.children('.dropdown-menu').**stop(true, true).hide(0, function(){mi.removeClass('**open')}); }); }; } hoverMenu(); // first page load jQuery(window).resize(**hoverMenu); // on resize event jQuery('ul.nav li.dropdown a').click(function(){window.** location=jQuery(this).attr('**href');}); // make all buttons bootstrap buttons jQuery('button, form input[type=submit], form input[type=button]'). **addClass('btn'); }); Richard On Tue, Dec 4, 2012 at 1:03 PM, Richard Vézina ml.richa...@gmail.comwrote: Hello, I just check the trunk and don't see any improvement at the dropmenu script level. I appreciate the little script to allow the bootstrap menu to works as superfish use to work, but actually they are pretty not usable in production. I explained, it may be possible that the problem I face have be not notice by someone who not use the welcome layout or use it with the default bootstrap top nav bar color (black). But the hover of the main entry of the top navbar are not working properly and it can be appreciate when use navbar inverse bootstrap class. The hover sometimes stick other time disappear, etc. Also, when you quit the main entry to go in
Re: [web2py] web2py 2.3.1?
Got it! script src={{=URL('static','js/jquery.hoverIntent.minified.js')}}/script script type=text/javascript language=javascript charset=utf-8 // ![CDATA[ $(document).ready(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').length) jQuery(this).addClass('dropdown-submenu'); }); var config = { over: showBootrapSubmenu, timeout: 300, out: hideBootrapSubmenu }; function showBootrapSubmenu(){ $(this).addClass('open'); } function hideBootrapSubmenu(){ $(this).removeClass('open'); } //Hover intent for Submenus $(.dropdown).hoverIntent(config); }); // ]] /script The only remaining issue I see, is that there is no line return for the loo menu entry... Richard On Tue, Dec 4, 2012 at 4:13 PM, Richard Vézina ml.richard.vez...@gmail.comwrote: So, I did that in layout.html and it improves thing. The only little glitch is that subSubMenu are not displaying at the rigth place, they just show below the actual a hover element, they should appear beside this element. I try to figure out which piece of web2py_bootstrap.js is responsible of that behavior : script src={{=URL('static','js/jquery.hoverIntent.minified.js')}}/script script type=text/javascript language=javascript charset=utf-8 // ![CDATA[ $(document).ready(function(){ jQuery('.navlia').each(function(){ if(jQuery(this).parent().find('ul').length) jQuery(this).attr({'class':'dropdown-toggle','data-toggle':'dropdown'}).append('b class=caret/b'); }); var config = { over: showBootrapSubmenu, timeout: 300, out: hideBootrapSubmenu }; function showBootrapSubmenu(){ $(this).addClass('open'); } function hideBootrapSubmenu(){ $(this).removeClass('open'); } //Hover intent for Submenus $(.dropdown).hoverIntent(config); }); // ]] /script To get the minified version of hoverIntent v6 : http://cherne.net/brian/resources/jquery.hoverIntent.minified.js Richard On Tue, Dec 4, 2012 at 3:25 PM, Paolo Caruccio paolo.carucci...@gmail.com wrote: I'm not the creator of the code in web2py_bootstrap.js that manages the dropdown behavior, I only added the code to adjust it on resize event. Originally the bootstrap dropdown hasn't a hover event (in this article the reasons explained http://markdotto.com/2012/02/27/bootstrap-explained-dropdowns/) The code in web2py makes possible to show/hide - with a fade effect - the dropdown main container, while the menu and submenus items navigation is provided by bootstrap itself. That said, I don't think that the odd behavior noticed by you is due to js code. I didn't have any notice of that (actually topbar has class nav-inverse) in IE9, IE8, FF last versions, OP last versions and CH last versions on windows7. Only in IE7 web2py dropdown has some showing issue but I have already submitted a patch. Could you delete following rule in web2py_bootstrap.css (in other rules section row 178) and see if your issue disappears? .navbar-inner{ position:relative; /*unnecessary ??*/ } Anyway if you are interested, there is a small snippet in order to use hoverintent with bootstrap dropdown herehttp://stackoverflow.com/a/12960711 Il giorno martedì 4 dicembre 2012 19:49:24 UTC+1, Richard ha scritto: This could be interesting add on : http://cherne.net/brian/**resources/jquery.hoverIntent.**htmlhttp://cherne.net/brian/resources/jquery.hoverIntent.html Richard On Tue, Dec 4, 2012 at 1:43 PM, Richard Vézina ml.richa...@gmail.comwrote: I found that just replacing delay() and fade*() by show() and hide() solve most problem. Here the code : // this code improves bootstrap menus and adds dropdown support jQuery(function(){ jQuery('.navlia').each(**function(){ if(jQuery(this).parent().find(**'ul').length) jQuery(this).attr({'class':'**dropdown-toggle','data-toggle'**:'dropdown'}).append('b class=caret/b'); }); jQuery('.nav li li').each(function(){ if(jQuery(this).find('ul').**length) jQuery(this).addClass('**dropdown-submenu'); }); function hoverMenu(){ var wid = document.documentElement.**clientWidth; //faster than $(window).width() and cross browser if (wid=980){ jQuery('ul.nav a.dropdown-toggle').parent().**hover(function(){ mi = jQuery(this).addClass('open'); mi.children('.dropdown-menu').**stop(true, true).show(); }, function(){ mi =
Re: [web2py] web2py 2.3.1?
Il giorno martedì 4 dicembre 2012 15:56:31 UTC+1, Massimo Di Pierro ha scritto: Can you try again. The file is there but looks like it was not committed to git. Did you get from github? Yes, I've got it from github. And YES, it's already fixed. Sometimes I think you own a magic glass sphere... ^_^ Thank you, Nico --
[web2py] web2py 2.3.1?
Please check the nightly build. I would like to release 2.3.1 asap, later this week. Massimo --
Re: [web2py] web2py 2.3.1?
I would check this now because I am preparing a talk and material for new students. There are any key feature or change that we need to look? --
Re: [web2py] web2py 2.3.1?
It is mostly lots of bug fixes. More wiki and grid options. On Monday, December 3, 2012 6:50:42 PM UTC-6, rochacbruno wrote: I would check this now because I am preparing a talk and material for new students. There are any key feature or change that we need to look? --
Re: [web2py] web2py 2.3.1?
I've been using trunk for the last three weeks and I didn't notice any problems. -rif --
Re: [web2py] web2py 2.3.1?
I've notice yesterday that the DEBUG button on the admin interface has problems: it always gives just the error invalid view (debug/interact.html). 2012/12/4 rif feric...@gmail.com I've been using trunk for the last three weeks and I didn't notice any problems. -rif -- --