[web2py] Controller to view: a baffling situtation.

2013-12-10 Thread Johann Spies
I have a controller defining a few buttons. I have changed the ' return' part as commented below just to see whether it makes a difference. But it does not. Using this controller and view (index.html) results in an error: File

Re: [web2py] Re: web2py 2.8.1 is OUT

2013-12-10 Thread Martin Weissenboeck
I try: *- virtual fields in grid* My model: db.define_table(test, Field(person,integer), #Field.Virtual(doublep, lambda r: r.person*2), ) My function: def index(): return dict(grid=SQLFORM.grid(db.test.id0)) No problem without the virtual

[web2py] Re: SQLite Integrity error after update to 2.8.2. = Widget problem?

2013-12-10 Thread Loïc
I'm still trying to understand this issue, as it is related to my custom widget (does not occurs when I use the default reference list widget) I try to set some breakpoints for example in accepts method of FORM class but I can't make it work. If I add dbg.set_trace(),the program breaks several

[web2py] Re: Controller to view: a baffling situtation.

2013-12-10 Thread Leonel Câmara
You really shouldn't use a controller just to return you a bunch of buttons, it's not very respectful to MVC. That said, My guess is that you have another def index(): in your default.py that is shadowing this one. Hence when you change the name it starts working. -- Resources: -

Re: [web2py] Re: Controller to view: a baffling situtation.

2013-12-10 Thread Johann Spies
On 10 December 2013 14:03, Leonel Câmara leonelcam...@gmail.com wrote: That said, My guess is that you have another def index(): in your default.py that is shadowing this one. Hence when you change the name it starts working. Bingo! Thanks. I forgot that I copied an older version of

[web2py] Re: SQLite Integrity error after update to 2.8.2. = Widget problem?

2013-12-10 Thread Loïc
Finally, I managed to make it work The solution was to* pass the validator of the table field to the SELECT helper of the widget* : In HierarchicalSelect class, I replaced opt=[OPTION(name, _value=key) for key,name in self.options] sel = SELECT(opt,_id=%s_%s % (self.tablename,

[web2py] Re: new feature in trunk: TODO panel in admin editor

2013-12-10 Thread Gael Princivalle
Hi Paolo. Sorry, where is this TODO panel ? Regards. Il giorno domenica 8 dicembre 2013 10:36:00 UTC+1, Paolo Valleri ha scritto: Dear all, the online editor has got a new TODO panel in which are listed all TODO you might have in the current application. For the time being it highlights

Re: [web2py] Re: new feature in trunk: TODO panel in admin editor

2013-12-10 Thread paolo.vall...@gmail.com
Hi, At the moment it is placed in the admin editor. Have a look there,in the footer there is a button called “todo“ ,click there :-P Il giorno 10/dic/2013 15:02, Gael Princivalle gaelprinciva...@gmail.com ha scritto: Hi Paolo. Sorry, where is this TODO panel ? Regards. Il giorno domenica 8

Re: [web2py] reference field or add if not in db

2013-12-10 Thread Richard Vézina
You will have to show some code to have me helping, because for now I can't say notting about what going on... It could be caused by requires that is missing. list:reference works out of the box most of the time, but there is situation where it failed and you need your own requires that will

Re: [web2py] reference field or add if not in db

2013-12-10 Thread Paolo Caruccio
If you define the referenced table before the table having the list:reference field the form widget should be a multiple dropbox (see http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer?search=list#list:type,-and-contains ) Example from the book:

Re: [web2py] Re: Proposal for big but simple improvement: [add view] in IDE view

2013-12-10 Thread Mika Sjöman
Wow that is wonderful! Web2py development will really become way smoother with this! I actually really enjoy the online IDE and not working with external apps. Fantastic to read that you took this suggestion so seriously and started working to implement it. I knew this was not that easy the

[web2py] Re: how to send data to the server with web2py_websocket

2013-12-10 Thread Peter
Hello Lyn2py, I ran into the same problem as you did and couldn't quite figure out what caused it. The JS function 'web2py_websocket' is described in /static/js/web2py.js. The file web2py.js was given a makeover in Web2py 2.6.1 as changelog suggests: *For pre 2.6 applications to work with

[web2py] Records refusing to update when using web2py-haystack

2013-12-10 Thread Alex Bush
Hello all, I have an issue when using web2py-haystack and I hope somebody here will be able to help me. I understand that this plugin is an experimental plugin, but I am using this plugin in its simplest form (without an external search backend) and unmodified. The issue appears when I

[web2py] ADD two gluon.dal.Field items in a query Web2py 2.8.1

2013-12-10 Thread Boris Aguilar
Hi, using Web2py 2.8.1 and doing a query where you need to for example add two values of a table to query data such as: table1 - id | field1 | fIeld2 - 1 | 1 | 2 2 | 3 | 5 ... so i wanted to have all rows that (db.table1.field1 +

[web2py] Re: how to send data to the server with web2py_websocket

2013-12-10 Thread Niphlod
sent the PR https://github.com/web2py/web2py/pull/325 Thanks for the patch. On Tuesday, December 10, 2013 5:57:37 PM UTC+1, Peter Govers wrote: Hello Lyn2py, I ran into the same problem as you did and couldn't quite figure out what caused it. The JS function 'web2py_websocket' is described

Re: [web2py] urlify - no char mapping

2013-12-10 Thread Niphlod
no, we didn't: too dispersive and hard to maintain. On Monday, December 9, 2013 10:25:24 PM UTC+1, Richard wrote: Hello, What's happen with this? Is unidecode been added to contrib? Thanks Richard Le lundi 19 août 2013 14:35:12 UTC-4, Niphlod a écrit : it would be the first time we

Re: [web2py] urlify - no char mapping

2013-12-10 Thread Richard Vézina
Ok, thanks... It was not working with typeahead anyway... :) Richard On Tue, Dec 10, 2013 at 3:13 PM, Niphlod niph...@gmail.com wrote: no, we didn't: too dispersive and hard to maintain. On Monday, December 9, 2013 10:25:24 PM UTC+1, Richard wrote: Hello, What's happen with this?

[web2py] Re: login crash under 2.8.2

2013-12-10 Thread Leonel Câmara
Never mind my previous response, I'm getting the exact same error on apache using mod_wsgi on microsoft windows 2012. I guess I will try to find out what's wrong because this is really annoying. The error seems to go away if you delete sessions, but it comes back seemingly randomly.

[web2py] Re: Can't edit default.py after upgrade to 2.8.2

2013-12-10 Thread Richard Brown
Sorry, the message image did not display in my last post, I've attached it as a file. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received

[web2py] Re: login crash under 2.8.2

2013-12-10 Thread Leonel Câmara
I've found the problem, Session in globals.py constantly tries to pickle itself forgetting to convert to a dict first. As it should if you look at storage.py save_storage. I guess I can make a patch for this. Terça-feira, 3 de Dezembro de 2013 11:59:11 UTC, lucas escreveu: hey everyone,

[web2py] Re: login crash under 2.8.2

2013-12-10 Thread Leonel Câmara
Of course we can always just remove __getstate__ = lambda self: None from Storage However I think that's there to force the use of save_storage which does the proper file locking. I can understand Session not having the dict conversion since it isn't needed by FastStorage but in the mean time

[web2py] Re: apk for web2py application

2013-12-10 Thread Vinhthuy
appsgeyser is really nice. You give it a URL and it gives you an Android app. It would be very nice if web2py can package an app directly to an Android app. That would be very nice. On Thursday, December 5, 2013 7:35:35 PM UTC-6, 黄祥 wrote: hi, i'm interested in web2py apk like on

[web2py] Re: Fail to recognize json payload in a content-type: application/json POST request

2013-12-10 Thread Vincent Audebert
Trying to catch up on this issue. Has it been fixed on trunk? Also when is forecasted the next released? At the moment, I just hacked main.py by replacing http_content_type with content_type. Does it sound ok ? Cheers. Vincent. On Thursday, August 1, 2013 6:53:09 PM UTC+12, Ray (a.k.a.

[web2py] Can't read SQLFORM.grid div with hidden inputs

2013-12-10 Thread Francisco
Hello guys. I'm doing this: grid=SQLFORM.grid(db.mytable) but since I wanted to use a prettier form I created it in the view. It is now complete but it won't let me submit it till I send the _formkey and _formname values, but I can't read them from the grid object. If I do: print grid I

[web2py] Re: login crash under 2.8.2

2013-12-10 Thread Leonel Câmara
Ignore, my patch still sees other bugs, such as trying to pickle lock objects, I have to examine this more carefully. This is a particularly interesting bug. In the mean time, as a workaround, I haven't been able (yet) to see the issue using the db to store the cookies session.connect(request,