Hi, Im replicating the example from the book for better testing:
./modules/mytest.py from gluon import current def ip(): return current.request.client ./controllers/test.py from applications.mdplenus.modules.mytest import ip def index(): return "Your ip is " + mytest.ip() * Same error: ImportError('No module named apptest.modules.mytest',) ______________________ Thanks in advance, El Saturday, July 18, 2020 a la(s) 3:20:28 PM UTC-5, snide...@gmail.com escribió: > > > On Friday, July 17, 2020 at 3:21:27 PM UTC-7, patito feo wrote: > >> Hi, >> >> >> __init__.py file in ./modules >> moduloname.py file in ./modules >> >> But the module still not loade. An error is pop in the web-ide. >> >> [...] >>>>>>>> >>>>>>> failed to reload module because: >>>>>>>> >>>>>>>> ImportError('No module named mdplenus.modules.test', >>>>>>>> >>>>>>>> > Is "mdplenus.py" in ./modules? The name has to match. Is "test" the name > of your application? > > /dps > > > -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/a9c90319-850f-4e31-bba4-48ac3dee4149n%40googlegroups.com.