[web2py] Re: web shell says admin disabled because unable to access password file

2011-04-03 Thread CVstash dot com
Thanks Christian. I'm not really pulling PIL to use it directly, just a way to make pyfpdf to work. If PIL won't work in GAE, then probably I shouldn't bother with the pyfpdf approach at all. On Apr 4, 5:44 am, howesc wrote: > Arbie, > > Is PIL pure python?  i'm not sure you can use it with GAE a

Re: [web2py] Re: Making my own decorator...

2011-04-03 Thread Jason (spot) Brower
Yes, I wouldn't use that decorator on index like that, if it were in default.py's index it is actually in conference.py index and jumps to the defaults index. But it is good to point out. BR, Jason Brower On Sun, Apr 3, 2011 at 11:09 PM, Anthony wrote: > Yes, I think a decorator is supposed to

[web2py] extra element in form toggles automatically

2011-04-03 Thread Rohan
I am creating an extra element in form as per guide http://web2py.com/book/default/chapter/07#Adding-extra-form-elements-to-SQLFORM here is the code controller settings_form = SQLFORM(db.auth_user, record, fields = ['first_name', 'email'], labels = {'first_name' : 'Full Name', 'email': 'Email Add

[web2py] Re: vote for Pycharm support for Web2py

2011-04-03 Thread mikech
IDE talk at Pycon2011. At 13:39 the PyCharm rep shows the Django support, which should give you some idea of what might be done with PyCharm and Web2py, so vote up support at the link mentioned above

[web2py] New b2b site using web2py

2011-04-03 Thread JimK
Hello Everyone! I've been working on a business for some time and have finally launched it! The web server for the main app and CAS are running on appengine using the web2py framework. Please check it out and let me know what you think. The url is www.qakit.com and you can register for a free 2

[web2py] router change: map_hyphen default

2011-04-03 Thread Jonathan Lundell
The default setting for map_hyphen in the parametric router has been changed from True to False in the trunk, and will show up in the next stable release. This is to make the default setting the same as having no router at all. If you're using URL hyphen mapping now, just add map_hyphen=True to

[web2py] Re: fetch("http://74.125.226.80") not working

2011-04-03 Thread pbreit
Or cookies.

[web2py] add / remove form field

2011-04-03 Thread 黄祥
hello, i want to input many data simutanously in web2py to database. did anyone knows how to add / remove form field in web2py and then input it on database? thank you so much and best regards, stifan

[web2py] Re: fetch("http://74.125.226.80") not working

2011-04-03 Thread pbreit
What is the difference? Could be that the web server sends a different response based on something like the USER-AGENT.

[web2py] a few comments on session handling

2011-04-03 Thread VP
i'm making a few observations as i'm debugging my app. They might reflect my lack of understanding of how web2py works. Anyway, a few thoughts + It appears session.forget() (as mentioned numerous times in the book) should be session.forget(response). I have used session.forget() for a long time,

[web2py] Re: fetch("http://74.125.226.80") not working

2011-04-03 Thread ionel
However, The result of http://184.82.233.163/phpbb/index.html is not the same with the result of fetch("http://184.82.233.163/phpbb/ index.html") I don't know why. On Apr 3, 10:17 pm, ionel wrote: > You are right. It works. It was my server. It is mis > configured:http://184.82.233.163 > >

[web2py] Re: fetch("http://74.125.226.80") not working

2011-04-03 Thread ionel
You are right. It works. It was my server. It is mis configured: http://184.82.233.163 Thanks. On Apr 3, 10:05 pm, Massimo Di Pierro wrote: > It works for me. Are you running on GAE? > > On Apr 3, 8:35 pm, ionel wrote: > > > Hello, > > > I need to fetch an IP but > > > from gluon.tools import

[web2py] Re: fetch("http://74.125.226.80") not working

2011-04-03 Thread Massimo Di Pierro
It works for me. Are you running on GAE? On Apr 3, 8:35 pm, ionel wrote: > Hello, > > I need to fetch an IP but > > from gluon.tools import fetch > html = fetch("http://74.125.226.80";) > > doesn't work. > > Thanks > > i.a.

[web2py] fetch("http://74.125.226.80") not working

2011-04-03 Thread ionel
Hello, I need to fetch an IP but from gluon.tools import fetch html = fetch("http://74.125.226.80";) doesn't work. Thanks i.a.

[web2py] Re: Field 'time' and standard time

2011-04-03 Thread pbreit
How about: import datetime db.define_table('register_time', Field('name'), Field('hour', 'time', default=request.now.strftime('%H')))

[web2py] Re: mod_wsgi + CentOS + web2py in subdirectory => possible?

2011-04-03 Thread Alex Quinn
> Have you checked out the fedora script? Not to use but to > observe some of the steps and configs? This looks promising. Thanks! Until now, I didn't realize CentOS and Fedora were closely related. I'll see if there are any configurations in there that can solve this. Thank you for the tip!

Re: [web2py] Re: Congratulations to this mailing list

2011-04-03 Thread Esteban Ordano
Congratulations! I'm really fond of the web2py framework. In fact, after having used both web2py and django, I am very biased towards web2py. I think that you simply *get* it, and you did a excellent job, and you keep on doing great work. But I think that this has to be taken with extreme caution

[web2py] Re: mod_wsgi + CentOS + web2py in subdirectory => possible?

2011-04-03 Thread Alex Quinn
> There nothing wrong in principle with your configuration and we know > of users who use it in a similar configurations. Thank you for the quick reply. It is good to know that this *can* work. I saw one post elsewhere where someone said web2py *can't* be used in a subdirectory with mod_wsgi due

[web2py] Re: Congratulations to this mailing list

2011-04-03 Thread Massimo Di Pierro
Here is another plot adding Ruby on Rails data (rubyonrails-talk) http://i.imgur.com/sPLzH.png we passed them too as messages/month since Dec 2010. According to this (http://rubyonrails.org/community) rubyonrails-talk is the main Rails list for users. Massimo On Apr 3, 7:08 pm, Anthony wrote:

[web2py] Re: Congratulations to this mailing list

2011-04-03 Thread Anthony
I don't have exact numbers, but over the past 11 months, I think the web2py Google Group membership has grown by over 50%. By contrast, it appears the Django Google Group membership has grown by only about 10%-15%. I guess there's a reason there were three April Fools jokes on Reddit targeting

[web2py] Re: Congratulations to this mailing list

2011-04-03 Thread Pystar
significative??? On Apr 4, 12:53 am, Massimo Di Pierro wrote: > I mined some data from: > > http://groups.google.com/group/web2py/abouthttp://groups.google.com/group/django-users/about > > This web2py users group had 56,283 messages posted since 1/1/2009. The > Django-users list had 51,119 over t

[web2py] Congratulations to this mailing list

2011-04-03 Thread Massimo Di Pierro
I mined some data from: http://groups.google.com/group/web2py/about http://groups.google.com/group/django-users/about This web2py users group had 56,283 messages posted since 1/1/2009. The Django-users list had 51,119 over the same time period. Here is a plot showing the messages/month in the tw

Re: [web2py] Re: jquery mobile, google maps and routes.py

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 4:01 PM, ChrisM wrote: > > I was trying to get around the fact that jquery inserts the # into the > url, so the > correct html template is not loaded, this does not happen if you use > multi page > html file - oh yes, this is for a jquery mobile page. The hash URL never gets to

[web2py] Field 'time' and standard time

2011-04-03 Thread Bruno Barbosa
Hello, how do I set the default time in 'time' field? ex: db.define_table('register_time', Field('name'), Field('hour', 'time', default=*???*)) obs: I do not want to use the field type 'datetime'. thanks. # --- # Bruno Barbosa

[web2py] Re: jquery mobile, google maps and routes.py

2011-04-03 Thread ChrisM
I was trying to get around the fact that jquery inserts the # into the url, so the correct html template is not loaded, this does not happen if you use multi page html file - oh yes, this is for a jquery mobile page. On Apr 3, 3:54 pm, Jonathan Lundell wrote: > On Apr 3, 2011, at 4:58 AM, ChrisM

[web2py] Re: JSON and HTTP status codes. Specifically 400s

2011-04-03 Thread Matt
Thanks Massimo :) Works fine now. Matt On Apr 4, 10:30 am, Massimo Di Pierro wrote: > fixed now in trunk, please check it. Thanks for reporting the problem > > On Apr 3, 5:03 pm, Matt wrote: > > > > > > > > > Hi there, > > > When I try and send "JSON" responses with HTTP status codes in the 400

[web2py] Re: JSON and HTTP status codes. Specifically 400s

2011-04-03 Thread Massimo Di Pierro
fixed now in trunk, please check it. Thanks for reporting the problem On Apr 3, 5:03 pm, Matt wrote: > Hi there, > > When I try and send "JSON" responses with HTTP status codes in the 400 > range I get the following "IE 512 byte bugfix" inserted into my > response. > > http://localhost:8000/test.

[web2py] JSON and HTTP status codes. Specifically 400s

2011-04-03 Thread Matt
Hi there, When I try and send "JSON" responses with HTTP status codes in the 400 range I get the following "IE 512 byte bugfix" inserted into my response. http://localhost:8000/test.json def test(): response.status = 400 d = dict() d['hello'] = 'world' return dict(object=d) {"ob

[web2py] Re: web shell says admin disabled because unable to access password file

2011-04-03 Thread howesc
Arbie, Is PIL pure python? i'm not sure you can use it with GAE as it is C based (i think), though GAE does provide it's own image manipulation library. for pure python packages you don't need the web shell to install them, just copy their python files to web2py/site-packages and restart GAE.

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 2:22 PM, pbreit wrote: > > Oh right, cuz login is going to be /user/login ? Well, that too, but simply setting default_application (without any routing) will never suppress the application unless it's also suppressing the controller and function.

[web2py] mod_wsgi + CentOS + web2py in subdirectory => possible?

2011-04-03 Thread pbreit
Have you checked out the fedora script? Not to use but to observe some of the steps and configs? http://code.google.com/p/web2py/source/browse/scripts/setup-web2py-fedora.sh Are you able to get it working *not* in a sub-directory? I looked at centos initially but went elsewhere pretty quick. Ubu

[web2py] attention moderator

2011-04-03 Thread Massimo Di Pierro
Somebody has figured out how to post spam by responding to legit posts. That means spam now comes in with legit subjects. Please check content before approving new users. Massimo

Re: [web2py] url rewriting

2011-04-03 Thread pbreit
Oh right, cuz login is going to be /user/login ?

[web2py] Another beginner looking for AJAX-y help

2011-04-03 Thread pbreit
The tricky part is going to be the controller logic and how to process a second taster if one exists. I would suggest getting that working first with a static form. You're going to need to insert a custom ield and then do a db insert if it is populated. Then, it's just a matter of showing and h

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 2:11 PM, pbreit wrote: > Setting the default_application works really well. Would actual re-writing > need to be performed by the server? That will interpret / as /init/default/index, but it won't help for /login

Re: [web2py] url rewriting

2011-04-03 Thread pbreit
Setting the default_application works really well. Would actual re-writing need to be performed by the server?

Re: [web2py] url rewriting

2011-04-03 Thread Ahmed Sharkawy
*I want url rewriting not changing the default route * On 3 April 2011 18:40, Jonathan Lundell wrote: > On Apr 3, 2011, at 9:01 AM, Shark wrote: > > > > Hello > > > > I am asking about url rewriting in web2py withGAE > > > > I want to make our site page > > www.site.com/init/login > > > > to > >

[web2py] Another beginner looking for AJAX-y help

2011-04-03 Thread Kevin Cole
Hi, I'm trying to design an application to manage a wine-tasting party. Each invitee can bring guests. They're in a "tasters" table. Each invitee and guest(s) brings a bottle of wine. The details of each wine are in a "wines" table. Many tasters to one wine. And finally a "scores" table with

[web2py] Re: Help need on links

2011-04-03 Thread Pystar
Thanks for your responses to my question. Like I suspected, it was the Blueprint CSS framework in my app that was the cause of the error, i.e. the print.css file. I swiped it out and my links look and act according to expectations. Thanks Pystar On Apr 2, 10:25 pm, Pystar wrote: > @pbreit > Links

[web2py] Re: Making my own decorator...

2011-04-03 Thread Anthony
Yes, I think a decorator is supposed to take a function (or callable) as an argument and return a callable. In general, you should be able to chain decorators. Also, I assume you don't actually want to decorate your 'index' function with your 'is_in_conference' decorator -- otherwise, it looks

[web2py] Re: mod_wsgi + CentOS + web2py in subdirectory => possible?

2011-04-03 Thread Massimo Di Pierro
There nothing wrong in principle with your configuration and we know of users who use it in a similar configurations. two things can be wrong: permissions, url rewriting. When you say it does not work, what do you see? What kind of problems do you experience? Massimo On Apr 3, 10:14 am, Alex Qui

[web2py] Re: PostgreSQL Error "SELECT DISTINCT, ORDER BY expressions must appear in select list"

2011-04-03 Thread Massimo Di Pierro
Can you show us the web2py dal expression that caused the invalid query? Thanks! On Apr 3, 8:19 am, fuga wrote: > web2py generate SQL that PostgreSQL doesn't accept. > > For instance, > > SELECT DISTINCT a.id, a.uid, a.name FROM a, b WHERE a.deleted <> > 'T') AND (a.id > 0)) AND (((b.deleted

Re: [web2py] Re: Making my own decorator...

2011-04-03 Thread Jason Brower
Thanks... that cleared some things up. :) BR, Jason On 04/03/2011 10:48 PM, Massimo Di Pierro wrote: I think you want: def is_in_conference(f): if not session.current_conference: redirect(URL('default', 'index')) return f @is_in_conference() def index(): """ I

[web2py] Re: IS_IN_DB no dropdown list

2011-04-03 Thread Kevin Cole
Ah. My misreading. You said "cookbook" and I read it as "book". I thought you were saying your examples in your book were out of date, which seemed odd. In the immortal words of Emily Litella, "Oh... Never mind..." [1] 1. http://en.wikipedia.org/wiki/Emily_Litella

[web2py] Re: Making my own decorator...

2011-04-03 Thread Massimo Di Pierro
I think you want: def is_in_conference(f): if not session.current_conference: redirect(URL('default', 'index')) return f @is_in_conference() def index(): """ INFO: This page takes all the various things of the conference on to one page. """ return dict() On

[web2py] Re: web2py joins Pylons project

2011-04-03 Thread Massimo Di Pierro
I have run some tests and reddit.com/r/Python pays no role in web2py popularity (positive or negative). Here are some statistics: Number of http requests: 29/Mar/2011 82379 30/Mar/2011 81757 31/Mar/2011 88105 01/Apr/2011 72613 <<< nothing happened 02/Apr/2011 51305 Number of requests from distin

[web2py] Re: IS_IN_DB no dropdown list

2011-04-03 Thread Anthony
The online version of the book is continually edited, so it will be more up-to-date than the printed copy. I doubt there's much (or anything) in the printed book that is out-of-date (i.e., no longer correct), particularly given that web2py maintains backward compatibility of the API. However, t

[web2py] Re: IS_IN_DB no dropdown list

2011-04-03 Thread Massimo Di Pierro
There is nothing really outdated in the 3rd edition of the book. There are a few typos (fixed online) and it missed a description of some of the new features (mostly new router, restful services). On Apr 3, 2:19 pm, Kevin Cole wrote: > Hi, > > Is there a nice place to figure out what's out of da

[web2py] Re: IS_IN_DB no dropdown list

2011-04-03 Thread Kevin Cole
Hi, Is there a nice place to figure out what's out of date in the book? (I recently bought a copy and was assuming it was a bit more up-to-date.) I'm just beginnings of web2py, having fought with and been defeated by other frameworks. ;-) Having beat my head against this very problem I had as

[web2py] Making my own decorator...

2011-04-03 Thread Jason Brower
I am making my first decorator and I want to make sure I do it right... def is_in_conference(): if not session.current_conference: redirect(URL('default', 'index')) @is_in_conference() def index(): """ INFO: This page takes all the various things of the conference on to one p

[web2py] Re: web2py joins Pylons project

2011-04-03 Thread Anthony
Thanks, Pyramid. http://twitter.com/#!/amarandon/status/54413227936854016

Re: [web2py] Re: Issues with python in the menu.py

2011-04-03 Thread Jason Brower
On 04/03/2011 06:26 PM, ron_m wrote: Hi Jason This line response.menu += [(T('My Conferences'), False, URL('default','my_conferences'), [ users_conferences_list ])] I think should be response.menu += [(T('My Conferences'), False, URL('default','my_confe

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 9:01 AM, Shark wrote: > > Hello > > I am asking about url rewriting in web2py withGAE > > I want to make our site page > www.site.com/init/login > > to > > www.site,com/login > > can you help me ? > > someone tell me change app,yaml > others > say change routers.py Change

[web2py] url rewriting

2011-04-03 Thread Shark
Hello I am asking about url rewriting in web2py withGAE I want to make our site page www.site.com/init/login to www.site,com/login can you help me ? someone tell me change app,yaml others say change routers.py so I need your help Thanks

[web2py] Re: Uploaded file content issue.

2011-04-03 Thread Massimo Di Pierro
I do not fully understand the workflow. I assume the problem is that exposecsv() cannot find the file. Correct? What is in request.args(0)? How were the files uploaded? massimo On Apr 1, 7:14 am, Limesle wrote: > Hello, > > as you know, Web2py transform the content and the name of a file when >

[web2py] Re: "extra" arguments for Table and Field

2011-04-03 Thread Marcel Luethi
Wow! Great! And many thanks for the superfast reply! On 3 Apr., 17:57, Massimo Di Pierro wrote: > You can already do: > > db.table.field.extra = {} > > "extra" is not a keyword but you can attach attributes to a field > object. You can do it with tables too but they must be preceded by and >

[web2py] Re: "extra" arguments for Table and Field

2011-04-03 Thread Massimo Di Pierro
You can already do: db.table.field.extra = {} "extra" is not a keyword but you can attach attributes to a field object. You can do it with tables too but they must be preceded by and underscore to avoid naming conflicts with fields: db.table._extra = {} Massimo On Apr 3, 10:51 am, Marcel Lue

[web2py] PostgreSQL Error "SELECT DISTINCT, ORDER BY expressions must appear in select list"

2011-04-03 Thread fuga
web2py generate SQL that PostgreSQL doesn't accept. For instance, SELECT DISTINCT a.id, a.uid, a.name FROM a, b WHERE a.deleted <> 'T') AND (a.id > 0)) AND (((b.deleted <> 'T') AND (b.id > 0)) AND (b.id = 1))) AND (b.uid = a.uid)) ORDER BY b.id, a.id LIMIT 1 OFFSET 0; It fails because select

[web2py] mod_wsgi + CentOS + web2py in subdirectory => possible?

2011-04-03 Thread Alex Quinn
I spent 6 fruitless hours yesterday trying to get Web2py working on my hosting service: a CentOS VPS running Apache 2.0.52, Python 2.7, mod_wsgi 3.3 (latest), and web2py 1.94.6 (latest stable). I need it to run in a subdirectory since I use the server for other things. After trying everything wit

[web2py] Re: DAL: all database connections should be made by using the credentials of the authenticated user?!?!

2011-04-03 Thread Massimo Di Pierro
Mind that if you do this connection pooling will not work and you it will result in shower response time.

[web2py] "extra" arguments for Table and Field

2011-04-03 Thread Marcel Luethi
Hello. I'm trying to implement common grid operations (with Ext JS, GridPanel) for all tables in my app. Now I would need some extra info on table and field levels as hints, ex. default sort order of a table, column width of a field. The easiest way would be to have a "extra" argument in gluon.da

[web2py] Re: Issues with python in the menu.py

2011-04-03 Thread ron_m
Hi Jason This line response.menu += [(T('My Conferences'), False, URL('default','my_conferences'), [ users_conferences_list ])] I think should be response.menu += [(T('My Conferences'), False, URL('default','my_conferences'), users_conferences

[web2py] Re: Uploaded file content issue.

2011-04-03 Thread Limesle
Nobody can help me on this issue ? Limesle

[web2py] Re: DAL: all database connections should be made by using the credentials of the authenticated user?!?!

2011-04-03 Thread howesc
in have an app that has 2 connections - one for core data, and one for statistical data. no problem at all. the conditional authorization requirement in your app might make it a little tricky but should be doable. cfh

[web2py] Re: psycopg2 on macos

2011-04-03 Thread howesc
psycopg2 (and postgres in general) on mac can be tricky. it's been a while since i did this, but the obvious thing to double check is that the web2py is using the same version of python that psycopg2 got installed to. chances are there are multiple python installs on your machine (this is no

Re: [web2py] Re: jquery mobile, google maps and routes.py

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 4:58 AM, ChrisM wrote: > > update - seems to only work if you have multiple page definitions in > same html file. I'd avoid using # in a URL, because a browser is likely to parse it as a fragment (anchor) identifier. > > On Apr 2, 1:02 pm, ChrisM wrote: >> i am using the ex

[web2py] Re: web2py Ajax and ajaxClick()

2011-04-03 Thread luismurciano
Hi CrisM. The response.js works only in components loaded by =LOAD() function. You can find some documetation in http://www.web2py.com/book/default/chapter/13#Components Its very easy to use.

[web2py] [SOLVED] cannot import name DateTime

2011-04-03 Thread villas
It was due to package dependency in kinterbasdb. I always seem to have such a struggle setting up Firebird and Kinterbasdb. I've tried to retrace my steps and look at how I solved the problem in case anyone else gets it. Hopefully hereunder will be a clue for you :) ### Ubuntu 10.04 LTS Lucid Lyn

Re: [web2py] Issues with python in the menu.py

2011-04-03 Thread Jason Brower
On 04/03/2011 02:36 PM, Kenneth Lundström wrote: On 3.4.2011 14:03, Jason Brower wrote: So I have been playing with the idea of having some dynamic menus and I am a bit stuck... If a user is logged in and has created a conference then they should see an extra menu item with all of the conferenc

[web2py] Re: jquery mobile, google maps and routes.py

2011-04-03 Thread ChrisM
update - seems to only work if you have multiple page definitions in same html file. On Apr 2, 1:02 pm, ChrisM wrote: > i am using the examples from; > > I have a incoming request at > > http://localhost:8000/#/init/default/map_geoloc > > in routes.py i have: > > routes_in = ((r'.*:/favicon.ico',

[web2py] web2py Ajax and ajaxClick()

2011-04-03 Thread ChrisM
I have the following I have the ajax function returning html depending on logic from a controller. one the html elements is a link to a google map, it is possible to automate page transition in jquery using ajaxClick() but i cant get it to work using the response.js method. if request.vars.t1 ==

Re: [web2py] Issues with python in the menu.py

2011-04-03 Thread Kenneth Lundström
Oh shit, no I undestand why you created the list, it was a submenu you tried to create and my was for creating the main menu. Why yours is failing I have no idea. Sorry. Kenneth So I have been playing with the idea of having some dynamic menus and I am a bit stuck... If a user is logged in a

Re: [web2py] Issues with python in the menu.py

2011-04-03 Thread Kenneth Lundström
On 3.4.2011 14:03, Jason Brower wrote: So I have been playing with the idea of having some dynamic menus and I am a bit stuck... If a user is logged in and has created a conference then they should see an extra menu item with all of the conferences they are currently organizing. I have this in

[web2py] Issues with python in the menu.py

2011-04-03 Thread Jason Brower
So I have been playing with the idea of having some dynamic menus and I am a bit stuck... If a user is logged in and has created a conference then they should see an extra menu item with all of the conferences they are currently organizing. I have this in the menu.py file... if auth.is_logged_

[web2py] Re: Function is evaluated twice?

2011-04-03 Thread Serbitar
Thanks for the advice. The problem does indeed not occur with another plugin layout (I used Whitelight before). I am just testing some functionality and will add a form statement soon. On Apr 3, 3:56 am, Massimo Di Pierro wrote: > Add a print statement. You find that the function is being called