Like massimo said there was a dicussion before and a poll. If you are
talking about to change try, except logic, this is one of the things that
the develpers want to change, that makes the code hard to follow and ugly.
2011/5/14 Ross Peoples ross.peop...@gmail.com
I am developing a web2py app
1) when and why to user current
I don't be sure I understand, user current, current is the object you can
access from the module instead of passing globals
2) where to put imports. since in Python we've always been told to put
them at top of file. But it looks like they need to go in the def
Hi All,
db.define_table('dog',
Field('owner',db.auth_user))
wont allows me to select an empty user
adding
db.dog.owner.requires = [IS_EMPTY_OR(IS_IN_DB(db,'auth_user.id'))]
would make the drop down menu disappear...
any ideas ?
thanks
--
Sebastian E. Ovide
On Saturday, May 14, 2011 8:51:40 AM UTC-4, sebastian wrote:
db.dog.owner.requires = [IS_EMPTY_OR(IS_IN_DB(db,'auth_user.id'))]
would make the drop down menu disappear...
Do you get the drop down menu back if you take the validator out of the
list:
db.dog.owner.requires =
yes, it did work !
why ?
On Sat, May 14, 2011 at 2:09 PM, Anthony abasta...@gmail.com wrote:
On Saturday, May 14, 2011 8:51:40 AM UTC-4, sebastian wrote:
db.dog.owner.requires = [IS_EMPTY_OR(IS_IN_DB(db,'auth_user.id'))]
would make the drop down menu disappear...
Do you get the drop
I think 2.4 is getting old. Why now update the module you use to
version 2.5 instead?
If webp2y is too obsess with backward compatibility, new developers
will now be interested in the project.
I don't think supporting version 2.4 is a good thing.
On 14 mai, 01:14, Ross Peoples
On Saturday, May 14, 2011 9:27:35 AM UTC-4, sebastian wrote:
yes, it did work !
why ?
According to the book:
If you want the field validated, but you do not want a dropbox, you must put
the validator in a list.
1.
db.dog.owner.requires = [IS_IN_DB
The problem is that our app is using an API as a frontend to a third party
application. The Python API available to talk to this product only works in
Python 2.4.4. I have been successfully using Web2py 1.95.1 on Python 2.4.4
without any issues. It was only after I updated to the trunk version
On May 14, 2011, at 6:54 AM, Ross Peoples wrote:
The problem is that our app is using an API as a frontend to a third party
application. The Python API available to talk to this product only works in
Python 2.4.4. I have been successfully using Web2py 1.95.1 on Python 2.4.4
without any
First of all, I would like to thank Massimo Di Pierro and other
developers for the excellent framework!
I have several questions:
1. Is it possible to create class-based controllers instead of
function-based? The class will expose their public methods for calling
like functions. I want to make a
I don't suppose there's a way to run this module under Python 2.4.4 and run
web2py under 2.5 is there? The API is bytecompiled and has to run 2.4.4 (and
actually the API installs it own custom Python 2.4.4 instance). Is there any
way to do this? This would solve the web2py dependence on Python
This article should be useful for someone...
Batman is fast. Nginx is fast. Batman fights crime. Nginx fights wasted CPU
cycles and memory leaks. Batman performs well under pressure. Nginx, for its
part, excels under heavy server loads.
http://www.evanmiller.org/nginx-modules-guide.html
--
I think you might be on to something with the separate Python versions.
Perhaps with virtualenv or #!/usr/bin/env python2.4 ?
Thank you I was able to figure it out *cheers
On Fri, May 13, 2011 at 8:05 PM, pbreit pbreitenb...@gmail.com wrote:
I think this will do it:
def add_task():
form = SQLFORM(db.tasks)
form.vars.project_id = request.args(0)
if form.accepts(request.vars, session):
...
You can kind of get that type of structure with components and LOAD():
http://web2py.com/book/default/chapter/13?search=load%28#Components
Since the import wizard is primarily for newer users, I think the t_ and f_
are important to avoid reserved word conflicts. If you still want to use it,
you
-F profiler.log
works for me. Which python version? which os?
On May 13, 6:45 pm, Philip philip.el...@gmail.com wrote:
I am trying to use the web2py profiler (which I haven't used before).
I tried starting web2py with the -F option and a filename, and I get
the following error:
ImportError:
I spent about 45 minutes hashing this out over the phone and I think the
best solution (at least for our needs) is to make a lightweight JSON-RPC
server that talks directly with the third-party API running in Python 2.4.4.
Then we can run web2py on whatever Python version we want and just make
On Saturday, May 14, 2011 8:53:25 AM UTC-4, Dmitriy wrote:
2. Is it possible to remove 'T_' and 'F_' prefixes from the 'New
application wizard'? They are really not needed in real tables and
fields.
If you really don't want them, you could probably edit the make_table()
function in
On May 14, 7:53 am, Dmitriy partsyr...@gmail.com wrote:
First of all, I would like to thank Massimo Di Pierro and other
developers for the excellent framework!
I have several questions:
1. Is it possible to create class-based controllers instead of
function-based? The class will expose
No and it will not.
That does not mean there will not a web3py that is not backward
compatible and has major redesign. No hurry anyway.
On May 13, 12:37 pm, Ross Peoples ross.peop...@gmail.com wrote:
Does web2py support Python 3?
Web2py 1.95.1. :-)
I had thought about that and just using the builtin Rocket server to host
the service. That might be the best way to go.
Hello!
do you think hostgator is a bad hosting provider? I've development
joomla applications and they works well and the support system is very
good.
pity that site hostgator.web2py.es doesn't works to learn how deploy
my application
Anybody has another answer?
Thanks
python 2.6.5 running on Linux (ubuntu) using current web2py src. Does
the profiler require 2.7?
Thanks,
Philip
On May 14, 1:22 pm, Massimo Di Pierro massimo.dipie...@gmail.com
wrote:
-F profiler.log
works for me. Which python version? which os?
On May 13, 6:45 pm, Philip
Hello I have a table
db.define_table('comments',
Field('userinfo', db.auth_user, default=auth.user_id, readable=False,
writable=False),
Field('project_id', db.project, requires = IS_IN_DB(db, db.project.id,
'%(project_title)s'), readable=False, writable=False),
Field('isReply',
Never mind I just figured out what I needed to do *cheers
Thank You
On Sat, May 14, 2011 at 9:53 AM, Dmitriy partsyr...@gmail.com wrote:
The class will expose their public methods for calling
like functions. I want to make a controllers hierarchy. This will give
a possibility to inherit methods from ancestors following the DRY
principle :)
As I know (and as
I am running it with 2.5
On May 14, 3:11 pm, Philip philip.el...@gmail.com wrote:
python 2.6.5 running on Linux (ubuntu) using current web2py src. Does
the profiler require 2.7?
Thanks,
Philip
On May 14, 1:22 pm, Massimo Di Pierro massimo.dipie...@gmail.com
wrote:
-F profiler.log
http://web2py.com/plugins/plugin_jqmobile/about
Please send us comments and suggestions
hi,
is it possible to use 2 or more query on db?
i just tried on http://web2py.com/book/default/chapter/03#Adding-CRUD
e.g.
comments = db(db.comment.image_id == image.id and db.comment.is_active
== True).select(orderby = ~db_comment.id)
my question is when i put db.comment.is_active the page
:) NIce! I am testing it today on my Android.
Very nice design on the plugin page
(web2py keeps improving every two weeks)
--
Bruno Rocha
[ About me: http://zerp.ly/rochacbruno ]
On Sat, May 14, 2011 at 5:57 PM, Massimo Di Pierro
massimo.dipie...@gmail.com wrote:
i hope there are a lots of examples on the next book version. e.g. class
implement on models, modules, controllers. because people learned from the
book and sharpened it through testing and experience, especially when an
error occured. lol.
thank you so much.
comments = db( (db.comment.image_id == image.id) (db.comment.is_active==
True) ).select(orderby = ~db_comment.id)
thank you so much for your replied vasile, but, unfortunately is not going
to work because the syntax error related with
e.g. like this is return an error
comments = db(db.comment.image_id == image.id ** db.comment.is_active
== True).select(orderby = ~db_comment.id)
comments =
pardon me, it's my fault, i didn't realized the brackets, thank you so much.
it's solved now.
Shortcuts
http://on.fb.me/web2py
http://on.fb.me/web2pyslices
--
Bruno Rocha
[ About me: http://zerp.ly/rochacbruno ]
hi,
is there anyone can explain about the usage of default?
e.g. on http://web2py.com/book/default/chapter/03#Adding-CRUD
db.comment.image_id.default = image.id
thank you so much before
Excellent!
Note, the demo page doesn't render properly in IE:
https://lh3.googleusercontent.com/_GVRmxvNFHpo/Tc74DbV3suI/A8I/2_6fmO4Nuto/plugin_jqmobile.png
It looks fine in Chrome and Firefox, but what is the demo supposed to do? In
Firefox, when I click on any buttons, it says
On Saturday, May 14, 2011 5:37:39 PM UTC-4, 黄祥 wrote:
hi,
is there anyone can explain about the usage of default?
e.g. on http://web2py.com/book/default/chapter/03#Adding-CRUD
db.comment.image_id.default = image.id
You can read about it here:
web2py Plugin for jQuery Mobile:
http://web2py.com/plugins/plugin_jqmobile/about
I love it! Talk about bootstrapping app development! :-)
I tried it against my app and also the welcome app with the same
results.
The menus do not behave as expected. Most of the time (tested in
Chrome 11, Firefox 4, and Safari) the clicking a menu item results in
a Loading box with nothing
i'm understand right now, thank you so much for your detail explaination.
On Sun, May 15, 2011 at 5:02 AM, Anthony abasta...@gmail.com wrote:
On Saturday, May 14, 2011 5:37:39 PM UTC-4, 黄祥 wrote:
hi,
is there anyone can explain about the usage of default?
e.g. on
If they link a page that does not use the plugin_jqmobile/layout.html
(or return an invalid request, including an error), it hangs. If is a
jquery.mobile feature. I wish there was a way to disable. I have not
found it so far.
On May 14, 5:26 pm, Nite nitese...@gmail.com wrote:
I love it! Talk
Interesting... I am able to confirm by building out static menus on
the welcome app, but my more complex app is going to be more difficult
to change. Add to that the desire to have 2 layouts one for mobiles
and one for larger computer based browsers.
What's the best way to handle the complex
Just to give an update, I have successfully split this off into two web2py
instances: one running under Python 2.4.4 that only acts as a JSON-RPC
server, and a second web2py instance running on 2.6.1 that is using the
trunk version of web2py. After banging my head against a wall with regards
Hi,
One of the recent changes in Storage.__setattr__ is [ if value == None: ].
Shouldn't we always use is instead of == for all singletons like None?.
For reference in the particular case of Storage.__setattr__ with a Row
object as the value (using the current == instead of is), it will
On 05/14/2011 11:57 PM, Massimo Di Pierro wrote:
http://web2py.com/plugins/plugin_jqmobile/about
Please send us comments and suggestions
Excited to give it a try in some of my apps. Though I should probably
complete the apps first for normal browsers. :D
BR,
Jason Brower
I still don't understand Record Representation. Is there a plain english
description or, better, examples of what it actually does?
I'm going to try this out to reduce the risk of a security breach:
in a model:
def is_localhost():
import socket
http_host = request.env.http_host.split(':')[0]
try:
hosts = (http_host, socket.gethostname(),
socket.gethostbyname(http_host),
I find that designing the app for mobile first forces to keep
navigation simple and that is good.
On May 14, 10:23 pm, Jason Brower encomp...@gmail.com wrote:
On 05/14/2011 11:57 PM, Massimo Di Pierro
wrote:http://web2py.com/plugins/plugin_jqmobile/about
Please send us comments and
50 matches
Mail list logo