[web2py] Re: Installing web2py behind IIS (for Massimo Di Pierro)

2019-03-03 Thread Константин Комков
On the download page there is caveats which contein:
>
> Any url /a/b/c maps into a call to application a, controller b.py and 
> function c in that controller.

In ajax call I change  
url: "loadDocs"
to 
url: "hotline/loadDocs"
I don't know why old projects work without app name, but it is so.

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: SQLFORM.smartgrid seems to ignore formargs(separator=':'), whereas SQLFORM.grid obeys it

2019-03-03 Thread junderhill
Thanks, Massimo.  Will this work for multiple tables?  When I write:

formargs={'Wordlist': dict(separator=': '), 'Wordlist2word': dict(separator=': 
')}

this works for the first table, but when I navigate into the second table 
via a linked field, the arguments don't seem to be picked up.  I ask 
because I'd like to set other, table-specific options if possible.


On Sunday, March 3, 2019 at 2:25:43 PM UTC-8, Massimo Di Pierro wrote:
>
> It is not a bug.
>
> The problem is that in smartgrid you have to specify which table the 
> formargs apply to. For example:
> form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=
> 100, formargs={'Wordlist': dict(separator=': ')}, breadcrumbs_class=
> 'breadcrumbs')
>
> I am making a change that will allow:
>
>
> form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=
> 100, formargs={'*': dict(separator=': ')}, breadcrumbs_class='breadcrumbs'
> )
>
> so the formargs apply to all tables. Will be in 2.18.3
>
>
> On Friday, 1 March 2019 23:40:08 UTC-8, junde...@launchpnt.com 
>  wrote:
>>
>> dvdb = setupdb(gethostconfig(servername), getappconfig("devicecontrol"))
>> dvdb.Wordlist.longdescription.widget = SQLFORM.widgets.text.widget
>> form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=
>> 100, formargs=dict(separator=': '), breadcrumbs_class='breadcrumbs')
>>
>> Works, but separator is nowhere in sight.  This, on the other hand,
>>
>> dvdb = setupdb(gethostconfig(servername), getappconfig("devicecontrol"))
>> form = SQLFORM.grid(dvdb[tablename], args=request.args[:2], paginate=100, 
>> formargs=dict(separator=': '))
>>
>> also works, and shows the separator.  We are on:
>>
>> 2.16.1-stable+timestamp.2017.11.14.05.54.25
>> (Running on nginx/1.10.3, Python 2.7.12)
>>
>> John
>>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: mysql import from csv problem

2019-03-03 Thread Paul Ellis
Which python and web2py version are you using?

Do you mean you don't have the csv file anymore?

Do you have a backup of the old database to make another one from?

On Tuesday, 19 February 2019 22:13:24 UTC+1, Andrea Fae' wrote:
>
> Hello, when I import with this procedure 
> https://www.pythonanywhere.com/forums/topic/1288/ from csv to mysql, it 
> alter the ids of some related tables and I have data not corresponding to 
> the original exported csv. What can I do?
> What is my error? is it depending on charset or something related? thank 
> you
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: dict values error in python 3.6

2019-03-03 Thread Paul Ellis
https://github.com/web2py/web2py/issues/2126

done

On Sat, Mar 2, 2019 at 12:16 PM Kevin Keller  wrote:

> Can someone file an issue on github and also attach the solution please?
> Thanks
>
> --
> 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 this message because you are subscribed to a topic in the
> Google Groups "web2py-users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/web2py/KwYsKUWgYnw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] web2py 2.18.3 is OUT

2019-03-03 Thread Massimo Di Pierro
we fixed a number of small issues. please check it out.

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Custom Delimiters Broken in 2.18.1?

2019-03-03 Thread Massimo Di Pierro
Turns out the bug is not in the delimiters but in the import of 
gluon.packages. web2py incorrectly looks for 'yatl' and 'pydal' in globally 
installed packages before looking into gluon.packages. Therefore it picks 
up the wrong version, not most up-to-date. Fixing in 2.18.3

On Saturday, 2 March 2019 23:58:01 UTC-8, Massimo Di Pierro wrote:
>
> thanks for confirming
>
> On Tuesday, 26 February 2019 05:26:49 UTC-8, Tiago Alves wrote:
>>
>> I am using custom delimiters, all working fine...
>>
>> On 26 Feb 2019, at 13:24, Kevin Keller  wrote:
>>
>> Saw a 2.18.2 commit.
>> Was that addressed in thst commit?
>>
>> Thanks!
>>
>>
>>
>> On Mon, 25 Feb 2019, 06:08 Massimo Di Pierro,  
>> wrote:
>>
>>> Damn you are right. I am releasing 2.18.2 with a fix.
>>>
>>> On Sunday, 24 February 2019 18:31:27 UTC-8, Limedrop wrote:


 Hi there,

 I think the custom template delimiters are broken in 2.18.1.  Here's my 
 test code and the exception I'm getting:


 CONTROLLER
 def index():
 response.delimiters = ('') 
 return dict(message=T('Welcome!'))
 
 VIEW - index.html
 {{extend 'layout.html'}}
  Note that each column needs at least {{minCards}} 
 cards.

 EXCEPTION 
 File "\web2py2.18.1\web2py\gluon\restricted.py", line 230, in restricted
 sys.excepthook(etype, evalue, tb) File 
 "c:\Users\Playtech\Documents\Development\web2py2.18.1\web2py\applications\app\views\default\index.html",
  
 line 2, in 
 NameError: name 'minCards' is not defined


 Or have I done something wrong?

 Thanks

 -- 
>>> 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 this message because you are subscribed to the Google 
>>> Groups "web2py-users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to web2py+unsubscr...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> -- 
>> 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 this message because you are subscribed to the Google Groups 
>> "web2py-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to web2py+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: SQLFORM.smartgrid seems to ignore formargs(separator=':'), whereas SQLFORM.grid obeys it

2019-03-03 Thread Massimo Di Pierro
It is not a bug.

The problem is that in smartgrid you have to specify which table the 
formargs apply to. For example:
form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=100, 
formargs={'Wordlist': dict(separator=': ')}, breadcrumbs_class='breadcrumbs'
)

I am making a change that will allow:


form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=100, 
formargs={'*': dict(separator=': ')}, breadcrumbs_class='breadcrumbs')

so the formargs apply to all tables. Will be in 2.18.3


On Friday, 1 March 2019 23:40:08 UTC-8, junderh...@launchpnt.com wrote:
>
> dvdb = setupdb(gethostconfig(servername), getappconfig("devicecontrol"))
> dvdb.Wordlist.longdescription.widget = SQLFORM.widgets.text.widget
> form = SQLFORM.smartgrid(dvdb.Wordlist, args=request.args[:1], paginate=
> 100, formargs=dict(separator=': '), breadcrumbs_class='breadcrumbs')
>
> Works, but separator is nowhere in sight.  This, on the other hand,
>
> dvdb = setupdb(gethostconfig(servername), getappconfig("devicecontrol"))
> form = SQLFORM.grid(dvdb[tablename], args=request.args[:2], paginate=100, 
> formargs=dict(separator=': '))
>
> also works, and shows the separator.  We are on:
>
> 2.16.1-stable+timestamp.2017.11.14.05.54.25
> (Running on nginx/1.10.3, Python 2.7.12)
>
> John
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Web2py version 2.18.2 Communications Error when in Admin.

2019-03-03 Thread Massimo Di Pierro
The problem really is that urlib_quote is never imported from 
gluon._compat. Will push a 2.18.3 today with this and other small fixes.

On Saturday, 2 March 2019 23:57:03 UTC-8, Ricardo Antonio Zarco wrote:
>
> The same, I was using python 2.7.5 In my case was the main.py in gluon. 
> The urllib_quote is not recognized, i change by urllib2.quote
>
> El martes, 26 de febrero de 2019, 19:25:32 (UTC+1), John McMaster escribió:
>>
>> Just installed web2py version 2.18.2 and now I get a communications error 
>> when I save changes in an app.
>>
>> I get nothing in the error logs. 
>>
>> The apps run but when I go to edit them and click the save button at the 
>> top of the lefthand page I  get a red communications error in the field to 
>> the right of "Last saved on:"  <<< here that looks like this:
>> Save file: [save disk icon] Saved file hash:  Last saved on:  toggle 
>> breakpoint
>>
>>
>> I have restarted the uwsgi and checked the logs only to see that all has 
>> run cleanly.  I was getting a message that "probable another instance of 
>> uWSGI is running on the same address (127.0.0.1:9) where 9 is 
>> the port number assigned.
>> I killed all instances and restarted the uWSGI and all is clean.
>>
>> However I still get an comunications error.
>>
>> Any ideas as to where to look for issues / configuration problems?
>>
>> Thank you 
>>
>>
>>
>>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Web2py Windows edition with 3.x Interpreter

2019-03-03 Thread Massimo Di Pierro
Great work. Thanks for this!

On Sunday, 3 March 2019 03:24:38 UTC-8, Nico Zanferrari wrote:
>
> Good morning!
>
> I'm proud to say that I've succeeded in building the Windows 64 bit binary 
> with python 3.7.2 using pyinstaller !  Grab it from 
> https://github.com/nicozanf/web2py-pyinstaller 
>
> There are some little gothas, but it seems to work fine:
> - in the console I've got many errors like 
> 'ERROR:Rocket.Errors.Thread-2:Tried to send "500 Server Error" to client 
> but received socket error'. They disappear as soon as I've disabled IPv6 
> and rebooted. There are users that report also to fix similar problems by 
> adding the hostname on the hosts file
> - psycopg2 is placed in a folder by itself, instead than in the root folder
> - in the currently official binary build (with pyhton 2.7) there are also 
> two binaries: web2py_no_console.exe and web2py_on_gevent.exe. They don't 
> run correctly, and don't seem to be so important for me so I've decided to 
> skip their generation.
> - Macintosh compatibility is needed, but I cannot work on it
>
> Please, help with testing it! I'll make a PR on the official web2py 
> repository after some feedback.
>
> Cheers,
> Nico
>
> Il giorno mer 27 feb 2019 alle ore 12:03 Nico Zanferrari <
> nicoz...@gmail.com> ha scritto:
>
>> Hi,
>>
>> this is a big problem also from my point of view and I've already opened 
>> issue 
>> 2027  . However it's not 
>> so easy to achieve this goal, because you've to switch to 3.x + go 64 bit + 
>> change the *freezer* program (py2exe and bbfreeze do not work with 
>> python >= 3.5). I'm playing with pyinstaller, but I'm not promising 
>> anything. And also a binary Mac version is needed (I only have a Win box), 
>> plus testing everything.
>>
>> Cheers,
>> Nico 
>>
>> Il giorno mer 27 feb 2019 alle ore 11:45 elisha bere <
>> elishabe...@gmail.com> ha scritto:
>>
>>> Hie, 
>>>
>>> Is it possible to change from 2.7 to 3.x in my web2py app
>>>
>>> On 17 Feb 2019 20:57, "Jitun John"  wrote:
>>>
 "It requires Python 2.6 (no more supported), Python 2.7 (stable) or 
 Python 3.5+ (*recommended for new projects*) already installed on your 
 system. 
 There are also *binary packages for Windows* and Mac OS X.* They 
 include the Python 2.7 interpreter* so you do not need to have it 
 pre-installed."

 Sorry for my ignorance, I am assuming "Python 2.7 interpreter" as 
 "python27.dll" and "pywintypes27.dll" files.

 I recently moved my app from 2.x to 3.x using PyCharm IDE and the app 
 works fine when using IDE on 3.7 python.
 But when I try to compile it to .exe (using .iss file + hstart.exe), I 
 cant use the existing web2py_win.zip file.

 Gives me " unsupported pickle protocol: 3"

 As we are recommending new projects on 3.x, Is it possible for the next 
 version to have a 3.x interpreter ?
 or if we have a workaround, I am happy to try it.

 Thanks.

 -- 
 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 this message because you are subscribed to the Google 
 Groups "web2py-users" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to web2py+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

>>> -- 
>>> 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 this message because you are subscribed to the Google 
>>> Groups "web2py-users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to web2py+unsubscr...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Cannot import modules

2019-03-03 Thread Leonel Câmara
There have been a lot of problems due to the compat changes I would test web2py 
with a DAL trunk version

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Cannot import modules

2019-03-03 Thread Ben Duncan
Will do ...
*Ben Duncan*
DBA / Chief Software Architect
Mississippi State Supreme Court
Electronic Filing Division


On Sun, Mar 3, 2019 at 2:06 AM Massimo Di Pierro 
wrote:

> No. this is indeed stange. Can you please open a ticket about this?
>
> On Friday, 1 March 2019 04:30:37 UTC-8, Ben Duncan wrote:
>>
>> Ok further testing* REVELS* that if the module begins with 'test',
>> cutome_import chokes and pukes.
>> Named it to bensmodule and it works ...
>>
>> *Massimo*, is that expected behavior ?
>>
>> *Ben Duncan*
>> DBA / Chief Software Architect
>> Mississippi State Supreme Court
>> Electronic Filing Division
>>
>>
>> On Fri, Mar 1, 2019 at 6:25 AM Ben Duncan  wrote:
>>
>>> Ok, tried the deleting of ALL pyc, even moved the test module to gluon
>>> and tried:
>>>
>>> [web2py@su-postgres-ben-3 Book]$ cp -av modules/testmod/testmod.py
>>> ../../gluon/
>>> `modules/testmod/testmod.py' -> `../../gluon/testmod.py'
>>> [web2py@su-postgres-ben-3 Book]$ ls -la ../../gluon/testmod.py
>>> -rw-rw-r-- 1 web2py web2py 250 Feb 28 13:49 ../../gluon/testmod.py
>>> [web2py@su-postgres-ben-3 Book]$
>>>
>>> And still got:
>>> Seems to me cutom_import is borken.
>>>
>>> Error ticket for "Book" Ticket ID
>>>
>>> 10.13.69.144.2019-03-01.06-22-33.1284ee98-507a-49ff-a358-f3e409dff1fc
>>>  (ImportError('No module named
>>> testmod',), ) Version
>>> web2py™ Version 2.17.2-stable+timestamp.2018.10.06.11.34.06
>>> Python Python 2.7.13: /usr/bin/python (prefix:
>>> /opt/rh/python27/root/usr) Traceback
>>>
>>> 1.
>>> 2.
>>> 3.
>>> 4.
>>> 5.
>>> 6.
>>> 7.
>>> 8.
>>> 9.
>>> 10.
>>> 11.
>>> 12.
>>>
>>> Traceback (most recent call last):
>>>   File "/data/web2py/web2py/gluon/restricted.py", line 219, in restricted
>>> exec(ccode, environment)
>>>   File "/data/web2py/web2py/applications/Book/controllers/default.py" 
>>> , line 
>>> 510, in 
>>>   File "/data/web2py/web2py/gluon/globals.py", line 421, in 
>>> self._caller = lambda f: f()
>>>   File "/data/web2py/web2py/applications/Book/controllers/default.py" 
>>> , line 
>>> 109, in login
>>> from testmod import *
>>>   File "/data/web2py/web2py/gluon/custom_import.py", line 104, in 
>>> custom_importer
>>> raise ImportError(e1, import_tb)  # there an import error in the module
>>> ImportError: (ImportError('No module named testmod',), >> 0x7fc9ff98c560>)
>>>
>>> Error snapshot [image: help]
>>> 
>>>
>>> ((ImportError('No module named
>>> testmod',), ))
>>>
>>> inspect attributes
>>> Frames
>>>
>>>-
>>>
>>>*File /data/web2py/web2py/gluon/restricted.py in restricted at line
>>>219* code arguments variables
>>>-
>>>
>>>*File /data/web2py/web2py/applications/Book/controllers/default.py
>>>in  at line 510* code arguments variables
>>>-
>>>
>>>*File /data/web2py/web2py/gluon/globals.py in  at line 421*
>>>code arguments variables
>>>-
>>>
>>>*File /data/web2py/web2py/applications/Book/controllers/default.py
>>>in login at line 109* code arguments variables
>>>-
>>>
>>>*File /data/web2py/web2py/gluon/custom_import.py in custom_importer
>>>at line 104* code arguments variables
>>>Function argument list
>>>
>>>(name='testmod', globals={'A': , 'ANY_OF':
>>>, 'ASSIGNJS': ,
>>>'AppConfig': , 'B': , 
>>> 'BEAUTIFY':
>>>, 'BODY': , 'BR':
>>>, 'BUTTON': ,
>>>'BytesIO': , ...}, locals={}, 
>>> fromlist=('*',),
>>>level=-1)
>>>Code listing
>>>
>>>99.
>>>100.
>>>101.
>>>102.
>>>103.
>>>104.
>>>105.
>>>106.
>>>107.
>>>108.
>>>
>>>except ImportError as e1:
>>>import_tb = sys.exc_info()[2]
>>>try:
>>>return NATIVE_IMPORTER(name, globals, locals, fromlist, 
>>> level)
>>>except (ImportError, KeyError) as e3:
>>>raise ImportError(e1, import_tb)  # there an import 
>>> error in the module
>>>except Exception as e2:
>>>raise  # there is an error in the module
>>>finally:
>>>if import_tb:
>>>
>>>Variables
>>>builtinImportError 
>>>e1 ImportError('No module named testmod',)
>>>import_tb None
>>>
>>> Context
>>>
>>> locals request session response
>>> In file: /data/web2py/web2py/applications/Book/controllers/default.py
>>>
>>> 1.
>>>
>>>  at 0x7fc9ff98a930, file 
>>> "/data/web2py/web2py/applications/Book/controllers/default.py", line 12>
>>>
>>>
>>> *Ben Duncan*
>>> DBA / Chief Software Architect
>>> Mississippi State Supreme Court
>>> Electronic Filing Division
>>>
>>>
>>> On Fri, Mar 1, 2019 at 6:21 AM Ben Duncan  wrote:
>>>
 Dave: Yes   same level.

 Paul will try deleting the pyc files ...
 *Ben Duncan*
 DBA / 

Re: [web2py] Re: Web2py version 2.18.2 Communications Error when in Admin.

2019-03-03 Thread Kevin Keller
Ricardos change fixes it: 

 main.py in gluon. The urllib_quote is not recognized, i change by 
urllib2.quote

On Sunday, 3 March 2019 11:22:37 UTC+1, Lovedie JC wrote:
>
> Same to me and I have to save se3times and even merge the documents for it 
> ot finally save.
> Regards 
>
> On Sun, 3 Mar 2019, 13:20 Kevin Keller > 
> wrote:
>
>> The same here with python 3.7.1 on Windows10 latest Web2py from git from 
>> this morning. 
>> Pressing the save button twice brings up the merge dialogue, which does 
>> the trick for me for now.. 
>>
>> On Tuesday, 26 February 2019 19:25:32 UTC+1, John McMaster wrote:
>>>
>>> Just installed web2py version 2.18.2 and now I get a communications 
>>> error when I save changes in an app.
>>>
>>> I get nothing in the error logs. 
>>>
>>> The apps run but when I go to edit them and click the save button at the 
>>> top of the lefthand page I  get a red communications error in the field to 
>>> the right of "Last saved on:"  <<< here that looks like this:
>>> Save file: [save disk icon] Saved file hash:  Last saved on:  toggle 
>>> breakpoint
>>>
>>>
>>> I have restarted the uwsgi and checked the logs only to see that all has 
>>> run cleanly.  I was getting a message that "probable another instance of 
>>> uWSGI is running on the same address (127.0.0.1:9) where 9 is 
>>> the port number assigned.
>>> I killed all instances and restarted the uWSGI and all is clean.
>>>
>>> However I still get an comunications error.
>>>
>>> Any ideas as to where to look for issues / configuration problems?
>>>
>>> Thank you 
>>>
>>>
>>>
>>> -- 
>> 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 this message because you are subscribed to the Google Groups 
>> "web2py-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to web2py+un...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] another python 3 minor bug in 2.18.2: b'Logged in'

2019-03-03 Thread Kevin Keller
Changing the logged in message to a custom one did not change the situation 
(see screenshot) nor did trying to fiddle some more with jquery.. I think I 
had a syntax error before.. 

flash.text( flash.text(message).replace('b', '') );

On Sunday, 3 March 2019 13:33:41 UTC+1, Kevin Keller wrote:
>
> Tried flash.text(message).replace('b', '');
> in static web2py.js without success.. 
> any other ideas?
>
> On Saturday, 2 March 2019 19:47:36 UTC+1, Kevin Keller wrote:
>>
>> Tried to fix it in gluon/html.py and gluon/tools.py but can't fix it
>>
>> Would appreciate some help. 
>>
>> It's minor but super annoying. 
>>
>> I also see a big T in front of table names when using app creation 
>> wizard. 
>>
>> Fixed it by renaming the table name labels manually. 
>>
>>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] another python 3 minor bug in 2.18.2: b'Logged in'

2019-03-03 Thread Kevin Keller
Tried flash.text(message).replace('b', '');
in static web2py.js without success.. 
any other ideas?

On Saturday, 2 March 2019 19:47:36 UTC+1, Kevin Keller wrote:
>
> Tried to fix it in gluon/html.py and gluon/tools.py but can't fix it
>
> Would appreciate some help. 
>
> It's minor but super annoying. 
>
> I also see a big T in front of table names when using app creation wizard. 
>
> Fixed it by renaming the table name labels manually. 
>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: how to get username in view html

2019-03-03 Thread Leonel Câmara
You can just do

{{=row.created_by.username}}

It will perform a select and get the auth_user record and give you the 
username. If this is for many rows you probably want to do it differently.

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Web2py Windows edition with 3.x Interpreter

2019-03-03 Thread Nico Zanferrari
Good morning!

I'm proud to say that I've succeeded in building the Windows 64 bit binary
with python 3.7.2 using pyinstaller !  Grab it from
https://github.com/nicozanf/web2py-pyinstaller

There are some little gothas, but it seems to work fine:
- in the console I've got many errors like
'ERROR:Rocket.Errors.Thread-2:Tried to send "500 Server Error" to client
but received socket error'. They disappear as soon as I've disabled IPv6
and rebooted. There are users that report also to fix similar problems by
adding the hostname on the hosts file
- psycopg2 is placed in a folder by itself, instead than in the root folder
- in the currently official binary build (with pyhton 2.7) there are also
two binaries: web2py_no_console.exe and web2py_on_gevent.exe. They don't
run correctly, and don't seem to be so important for me so I've decided to
skip their generation.
- Macintosh compatibility is needed, but I cannot work on it

Please, help with testing it! I'll make a PR on the official web2py
repository after some feedback.

Cheers,
Nico

Il giorno mer 27 feb 2019 alle ore 12:03 Nico Zanferrari 
ha scritto:

> Hi,
>
> this is a big problem also from my point of view and I've already opened issue
> 2027  . However it's not so
> easy to achieve this goal, because you've to switch to 3.x + go 64 bit +
> change the *freezer* program (py2exe and bbfreeze do not work with python
> >= 3.5). I'm playing with pyinstaller, but I'm not promising anything. And
> also a binary Mac version is needed (I only have a Win box), plus testing
> everything.
>
> Cheers,
> Nico
>
> Il giorno mer 27 feb 2019 alle ore 11:45 elisha bere <
> elishabe...@gmail.com> ha scritto:
>
>> Hie,
>>
>> Is it possible to change from 2.7 to 3.x in my web2py app
>>
>> On 17 Feb 2019 20:57, "Jitun John"  wrote:
>>
>>> "It requires Python 2.6 (no more supported), Python 2.7 (stable) or
>>> Python 3.5+ (*recommended for new projects*) already installed on your
>>> system.
>>> There are also *binary packages for Windows* and Mac OS X.* They
>>> include the Python 2.7 interpreter* so you do not need to have it
>>> pre-installed."
>>>
>>> Sorry for my ignorance, I am assuming "Python 2.7 interpreter" as
>>> "python27.dll" and "pywintypes27.dll" files.
>>>
>>> I recently moved my app from 2.x to 3.x using PyCharm IDE and the app
>>> works fine when using IDE on 3.7 python.
>>> But when I try to compile it to .exe (using .iss file + hstart.exe), I
>>> cant use the existing web2py_win.zip file.
>>>
>>> Gives me " unsupported pickle protocol: 3"
>>>
>>> As we are recommending new projects on 3.x, Is it possible for the next
>>> version to have a 3.x interpreter ?
>>> or if we have a workaround, I am happy to try it.
>>>
>>> Thanks.
>>>
>>> --
>>> 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 this message because you are subscribed to the Google
>>> Groups "web2py-users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to web2py+unsubscr...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
>> 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 this message because you are subscribed to the Google Groups
>> "web2py-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to web2py+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Web2py version 2.18.2 Communications Error when in Admin.

2019-03-03 Thread Lovedie JC
Same to me and I have to save se3times and even merge the documents for it
ot finally save.
Regards

On Sun, 3 Mar 2019, 13:20 Kevin Keller  wrote:

> The same here with python 3.7.1 on Windows10 latest Web2py from git from
> this morning.
> Pressing the save button twice brings up the merge dialogue, which does
> the trick for me for now..
>
> On Tuesday, 26 February 2019 19:25:32 UTC+1, John McMaster wrote:
>>
>> Just installed web2py version 2.18.2 and now I get a communications error
>> when I save changes in an app.
>>
>> I get nothing in the error logs.
>>
>> The apps run but when I go to edit them and click the save button at the
>> top of the lefthand page I  get a red communications error in the field to
>> the right of "Last saved on:"  <<< here that looks like this:
>> Save file: [save disk icon] Saved file hash:  Last saved on:  toggle
>> breakpoint
>>
>>
>> I have restarted the uwsgi and checked the logs only to see that all has
>> run cleanly.  I was getting a message that "probable another instance of
>> uWSGI is running on the same address (127.0.0.1:9) where 9 is
>> the port number assigned.
>> I killed all instances and restarted the uWSGI and all is clean.
>>
>> However I still get an comunications error.
>>
>> Any ideas as to where to look for issues / configuration problems?
>>
>> Thank you
>>
>>
>>
>> --
> 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 this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Communication Error when Saving

2019-03-03 Thread Kevin Keller
I have teh same with the latest web2py from git, Python 3.7.1 on Windows 
10. 
Pressing save twice and merging finally saves..  as a workaround

On Sunday, 3 March 2019 08:57:03 UTC+1, Ricardo Antonio Zarco wrote:
>
> Hi,after upgrade to 2.18.2 i get the "Comunnicate error" when saving using 
> web browser/admin , the exception is:
>
> Versión
> web2py™ Version 2.18.2-stable+timestamp.2019.02.26.06.11.06
> Python Python 2.7.5: /usr/bin/uwsgi (prefix: /usr)Rastreo
>
> 1.
> 2.
> 3.
> 4.
> 5.
>
> Traceback (most recent call last):
>   File "/home/ec2-user/myapp/gluon/main.py", line 488, in wsgibase
> urllib_quote(xmlescape(response.flash).replace(b'\n', b''))
> NameError: global name 'urllib_quote' is not defined
>
> Error snapshot [image: help] 
> 
>
> (global name 'urllib_quote' is not defined)
>
>
>
> I think is a problem with de python 3 compatability what can i do? I need 
> to update my python version? Thanks
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: Web2py version 2.18.2 Communications Error when in Admin.

2019-03-03 Thread Kevin Keller
The same here with python 3.7.1 on Windows10 latest Web2py from git from 
this morning. 
Pressing the save button twice brings up the merge dialogue, which does the 
trick for me for now.. 

On Tuesday, 26 February 2019 19:25:32 UTC+1, John McMaster wrote:
>
> Just installed web2py version 2.18.2 and now I get a communications error 
> when I save changes in an app.
>
> I get nothing in the error logs. 
>
> The apps run but when I go to edit them and click the save button at the 
> top of the lefthand page I  get a red communications error in the field to 
> the right of "Last saved on:"  <<< here that looks like this:
> Save file: [save disk icon] Saved file hash:  Last saved on:  toggle 
> breakpoint
>
>
> I have restarted the uwsgi and checked the logs only to see that all has 
> run cleanly.  I was getting a message that "probable another instance of 
> uWSGI is running on the same address (127.0.0.1:9) where 9 is the 
> port number assigned.
> I killed all instances and restarted the uWSGI and all is clean.
>
> However I still get an comunications error.
>
> Any ideas as to where to look for issues / configuration problems?
>
> Thank you 
>
>
>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: update finds previous error in function definition

2019-03-03 Thread Carl Hunter Roach
I've added this as an issue.
https://github.com/web2py/web2py/issues/2122

On Sun, 3 Mar 2019 at 08:05, Massimo Di Pierro 
wrote:

> Can you please open a ticket about this?
>
> On Friday, 1 March 2019 04:07:28 UTC-8, Carl Hunter Roach wrote:
>>
>> I've been remiss and skipped too may Web2py updates.
>>
>> I've now updated from web2py v2.14.6 to web2py v2.18.2
>>
>> db.py
>>
>> openings_service = Service()
>>
>> controller.py
>>
>> @openings_service.json
>> def submit_openings():
>> ...
>>
>>
>> An external program calls my Web2py service and the function
>> submit_openings()
>> The caller has passed in a parameter and even though my `def` doesn't
>> define a parameter I was able to access the required parameter via `request`
>>
>> After the update to Web2py 2.18.2 the call no longer succeeds.
>>
>> TypeError: submit_openings() takes no arguments (1 given)
>>
>> I can see why this no longer works and the fix is simple; redefine the
>> `def` in my code as:
>>
>> @openings_service.json
>> def submit_openings(openings):
>>
>>
>> But I'd like to know what changed in Web2py? Mainly to confirm that I am
>> using Web2py correctly.
>>
>> --
> 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 this message because you are subscribed to a topic in the
> Google Groups "web2py-users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/web2py/G-_M0yNe5wc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>


-- 
Carl Hunter Roach
Bisham Barn Owl Group 
Runnymede Ringing Group 

Founder of Midnight 30 
Download Great Careers app

Jobs at great companies you can commute to.

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: retrieving json field from db (GAE)

2019-03-03 Thread Massimo Di Pierro
if we broke this, it was not intentional. Please open a ticket about this 
so we can track it. It will be fixed asap

On Friday, 1 March 2019 04:17:44 UTC-8, Carl Hunter Roach wrote:
>
> In a db table I have:
>
> Field('address', 'json', custom_qualifier={'indexed':False}
>
> I retrieve an entry thus:
>
> geo_address_row = db(db.geo_address.latlonkey == latlonkey).select(db.
> geo_address.latlonkey).first()
>
>
> I could access the json data via `geo_address_row.address` as a dict.
>
> but then I updated from web2py v2.14.6 to v2.18.2
>
> and `geo_address_row.address` is now a str rather than a dict and I need 
> to wrap it thus: `json.loads(geo_address_row.address)`
>
> I suspect I've been living with an error that has, by undefined chance, 
> worked; and that Web2py has now closed that bug and caught me out.
>
> Have I given enough information for anyone to provide an insight?
>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: Cannot import modules

2019-03-03 Thread Massimo Di Pierro
No. this is indeed stange. Can you please open a ticket about this?

On Friday, 1 March 2019 04:30:37 UTC-8, Ben Duncan wrote:
>
> Ok further testing* REVELS* that if the module begins with 'test', 
> cutome_import chokes and pukes.
> Named it to bensmodule and it works ...
>
> *Massimo*, is that expected behavior ?
>
> *Ben Duncan*
> DBA / Chief Software Architect 
> Mississippi State Supreme Court
> Electronic Filing Division
>
>
> On Fri, Mar 1, 2019 at 6:25 AM Ben Duncan  wrote:
>
>> Ok, tried the deleting of ALL pyc, even moved the test module to gluon 
>> and tried:
>>
>> [web2py@su-postgres-ben-3 Book]$ cp -av modules/testmod/testmod.py 
>> ../../gluon/
>> `modules/testmod/testmod.py' -> `../../gluon/testmod.py'
>> [web2py@su-postgres-ben-3 Book]$ ls -la ../../gluon/testmod.py
>> -rw-rw-r-- 1 web2py web2py 250 Feb 28 13:49 ../../gluon/testmod.py
>> [web2py@su-postgres-ben-3 Book]$
>>
>> And still got:
>> Seems to me cutom_import is borken.
>>
>> Error ticket for "Book" Ticket ID 
>>
>> 10.13.69.144.2019-03-01.06-22-33.1284ee98-507a-49ff-a358-f3e409dff1fc
>>  (ImportError('No module named testmod',), 
>> ) Version 
>> web2py™ Version 2.17.2-stable+timestamp.2018.10.06.11.34.06 
>> Python Python 2.7.13: /usr/bin/python (prefix: /opt/rh/python27/root/usr) 
>> Traceback 
>>
>> 1.
>> 2.
>> 3.
>> 4.
>> 5.
>> 6.
>> 7.
>> 8.
>> 9.
>> 10.
>> 11.
>> 12.
>>
>> Traceback (most recent call last):
>>   File "/data/web2py/web2py/gluon/restricted.py", line 219, in restricted
>> exec(ccode, environment)
>>   File "/data/web2py/web2py/applications/Book/controllers/default.py" 
>> , line 
>> 510, in 
>>   File "/data/web2py/web2py/gluon/globals.py", line 421, in 
>> self._caller = lambda f: f()
>>   File "/data/web2py/web2py/applications/Book/controllers/default.py" 
>> , line 
>> 109, in login
>> from testmod import *
>>   File "/data/web2py/web2py/gluon/custom_import.py", line 104, in 
>> custom_importer
>> raise ImportError(e1, import_tb)  # there an import error in the module
>> ImportError: (ImportError('No module named testmod',), > 0x7fc9ff98c560>)
>>
>> Error snapshot [image: help] 
>> 
>>  
>>
>> ((ImportError('No module named testmod',), 
>> )) 
>>
>> inspect attributes 
>> Frames 
>>
>>- 
>>
>>*File /data/web2py/web2py/gluon/restricted.py in restricted at line 
>>219* code arguments variables 
>>- 
>>
>>*File /data/web2py/web2py/applications/Book/controllers/default.py in 
>> at line 510* code arguments variables 
>>- 
>>
>>*File /data/web2py/web2py/gluon/globals.py in  at line 421* 
>>code arguments variables 
>>- 
>>
>>*File /data/web2py/web2py/applications/Book/controllers/default.py in 
>>login at line 109* code arguments variables 
>>- 
>>
>>*File /data/web2py/web2py/gluon/custom_import.py in custom_importer 
>>at line 104* code arguments variables 
>>Function argument list 
>>
>>(name='testmod', globals={'A': , 'ANY_OF': 
>>, 'ASSIGNJS': , 
>>'AppConfig': , 'B': , 
>> 'BEAUTIFY': 
>>, 'BODY': , 'BR': 
>>, 'BUTTON': , 
>>'BytesIO': , ...}, locals={}, 
>> fromlist=('*',), 
>>level=-1)
>>Code listing 
>>
>>99.
>>100.
>>101.
>>102.
>>103.
>>104.
>>105.
>>106.
>>107.
>>108.
>>
>>except ImportError as e1:
>>import_tb = sys.exc_info()[2]
>>try:
>>return NATIVE_IMPORTER(name, globals, locals, fromlist, 
>> level)
>>except (ImportError, KeyError) as e3:
>>raise ImportError(e1, import_tb)  # there an import error 
>> in the module
>>except Exception as e2:
>>raise  # there is an error in the module
>>finally:
>>if import_tb:
>>
>>Variables 
>>builtinImportError  
>>e1 ImportError('No module named testmod',) 
>>import_tb None 
>>
>> Context 
>>
>> locals request session response 
>> In file: /data/web2py/web2py/applications/Book/controllers/default.py 
>>
>> 1.
>>
>>  at 0x7fc9ff98a930, file 
>> "/data/web2py/web2py/applications/Book/controllers/default.py", line 12>
>>
>>
>> *Ben Duncan*
>> DBA / Chief Software Architect 
>> Mississippi State Supreme Court
>> Electronic Filing Division
>>
>>
>> On Fri, Mar 1, 2019 at 6:21 AM Ben Duncan  wrote:
>>
>>> Dave: Yes   same level.
>>>
>>> Paul will try deleting the pyc files ...
>>> *Ben Duncan*
>>> DBA / Chief Software Architect 
>>> Mississippi State Supreme Court
>>> Electronic Filing Division
>>>
>>>
>>> On Fri, Mar 1, 2019 at 12:26 AM Paul Ellis  
>>> wrote:
>>>
 I know this sounds odd. But this worked for me recently. It can be 
 caused by 

[web2py] Re: update finds previous error in function definition

2019-03-03 Thread Massimo Di Pierro
Can you please open a ticket about this?

On Friday, 1 March 2019 04:07:28 UTC-8, Carl Hunter Roach wrote:
>
> I've been remiss and skipped too may Web2py updates.
>
> I've now updated from web2py v2.14.6 to web2py v2.18.2
>
> db.py
>
> openings_service = Service()
>
> controller.py
>
> @openings_service.json
> def submit_openings():
> ...
>
>
> An external program calls my Web2py service and the function 
> submit_openings()
> The caller has passed in a parameter and even though my `def` doesn't 
> define a parameter I was able to access the required parameter via `request`
>
> After the update to Web2py 2.18.2 the call no longer succeeds.
>
> TypeError: submit_openings() takes no arguments (1 given)
>
> I can see why this no longer works and the fix is simple; redefine the 
> `def` in my code as:
>
> @openings_service.json
> def submit_openings(openings):
>
>
> But I'd like to know what changed in Web2py? Mainly to confirm that I am 
> using Web2py correctly.
>
>

-- 
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 this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.