[web2py] Can't use external internet in my development environment...

2010-11-18 Thread encompass
I see that the latest web2py pulls from ajax.googleapis.com. This is a bad thing for me as I don't have external internet access. Can we simply include these libraries? BR, Jason Brower

Re: [web2py] ajax push

2010-11-18 Thread Michele Comitini
2010/11/18 Phyo Arkar : > Very cool framework . > > But how web2py gonna work with as it have no serverside support for python ? > > We may be have to run 2 servers 1 for web2py and just 1 alone for Pushes .. Yes and you probably need to build a module if you want interactions between APE and Web2

[web2py] Re: New style 1.89.X forms seem washed out?

2010-11-18 Thread dederocks
Hi Ron, I have two web2py running, one on ubunto 10.10, and the other on windows 7. Both look very similar (buttons appear slightly taller on ubuntu), and I don't see any of the problems you mentionned: controls wahsed out, lack of color change for buttons selected, none of this happens on both ve

[web2py] Re: New style 1.89.X forms seem washed out?

2010-11-18 Thread villas
Hi Ron I agree. The controls in the standard Welcome app are not as visible as they should be. The Admin app is much, much better. I thought it may have been given a washed-out look so that this would encourage us to make our own styles. However, this is no reason why we cannot have a little

[web2py] Re: How do we add projects or post a request for a new job on expert exchange?

2010-11-18 Thread mdipierro
Are you talking about experts4solutions? Let me clarify. It is NOT a site where people post jobs and we compete for the lowest bid like some other sites. Quite the opposite. We go for quality. It is a place where people who need a job done can see who the qualified web2py programmers are and the

[web2py] Re: session not saving variables?

2010-11-18 Thread mdipierro
Three possibilities: - you are storing in session something that is not pickable - file system permissions error - browser cookies disabled On Nov 18, 12:45 am, Crim wrote: > so my website was working yesterday and now for some reason the > session variables arnt saving at certain points > > name

[web2py] Re: postgresql error ... (relation "auth_user" already exists)

2010-11-18 Thread mdipierro
This is a reasonable error now. when you change a field type (but not the name) web2py tries to convert the data. In this case postgres fails because it does not know how to convert dates to integers. You have to do it in multiple steps: - remove the field from define_table - run appadmin once (

[web2py] Re: experts4solutions.com again

2010-11-18 Thread mdipierro
No. ;-) On Nov 17, 9:40 pm, Nathan Freeze wrote: > Massimo, your bio is missing a pic. Is it okay to endorse you? :) > > On Wed, Nov 17, 2010 at 9:23 PM, mdipierro wrote: > > I have implemented an endorsement mechanism. Existing members can see > > and endorse new applicants. New applications sh

[web2py] Re: Precise behaviour of "compute" on record update

2010-11-18 Thread mdipierro
true. the text should be fixed. On Nov 18, 1:46 am, cjrh wrote: > Regarding the "compute" attribute of a Field object, the book says > this: > > "compute is an optional function. If a record is inserted and there is > no value for a field that has a compute attribute, the value is > calculated by

Re: [web2py] New style 1.89.X forms seem washed out?

2010-11-18 Thread Martín Mulone
2010/11/18 ron_m > > The text input fields are not very tall, in fact select boxes don't > even show the full height of the font. I fixed that by changing the > input text, input password and select height from 16px to 20px in > base.css > > Ron I think massimo change to 16 px, because original

Re: [web2py] Re: Upgrade problem

2010-11-18 Thread Kenneth Lundström
What can I do to fix this? What kind of path issue is this? Kenneth hmmm. I can make the error go away but this is a path issue On Nov 17, 3:31 pm, Kenneth Lundström wrote: I tried to upgrade version 1.89.1 to 1.89.3. I got the following error. I m running Linux, Apache and mod_wsgi. Is thi

[web2py] Re: Please help: Are these errors?

2010-11-18 Thread mdipierro
fixed in trunk On Nov 18, 1:47 am, Seeker wrote: > Hi guys, > Please help: > > Could someone please confirm whether the following two issues are > indeed errors or if I am simply doing something wrong.  They have both > been around for a while now and I am surprised that they have not been > noti

[web2py] Re: list:reference and orderby

2010-11-18 Thread mdipierro
What is your requires statement? On Nov 18, 1:53 am, Johann Spies wrote: > On 17 November 2010 16:48, mdipierro wrote: > > > IS_IN_DB(...,orderby=...) > > Thanks.  Now I get > > Traceback > > 1. > 2. > 3. > 4. > 5. > 6. > 7. > 8. > 9. > > Traceback (most recent call last): >   File "/home/js/web

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Branko Vukelic
Things you could do: 1. Use a picture of you looking natural. 2. Write a short biography that tells our clients why they might want to consider hiring you. 3. Add a link to your previous work so clients can see what you've done in the past. 4. Add any contact information to make it easier for clie

[web2py] Re: Upgrade problem

2010-11-18 Thread mdipierro
I do not have enough information to debug this. I suggest get 1.89.3 and see if you still have the problem, then I will suggest a test. Massimo On Nov 18, 6:06 am, Kenneth Lundström wrote: > What can I do to fix this? What kind of path issue is this? > > Kenneth > > > hmmm. I can make the error

[web2py] Re: Please help: Are these errors?

2010-11-18 Thread Seeker
Thanks Massimo, but I am up to date on trunk (change set 1223 mercurial), but both the problems still persist. On Nov 18, 2:06 pm, mdipierro wrote: > fixed in trunk > > On Nov 18, 1:47 am, Seeker wrote: > > > > > Hi guys, > > Please help: > > > Could someone please confirm whether the followi

[web2py] Guido on pep8

2010-11-18 Thread mdipierro
http://mail.python.org/pipermail/python-dev/2010-November/105681.html :-)

Re: [web2py] Re: Upgrade problem

2010-11-18 Thread Kenneth Lundström
The Upgrade problem I can´t test of course but now I manually upgraded to 1.89.3 and still have the problem with creating a new application. Kenneth I do not have enough information to debug this. I suggest get 1.89.3 and see if you still have the problem, then I will suggest a test. Massimo

[web2py] Re: Please help: Are these errors?

2010-11-18 Thread mdipierro
I am confused. With the new code in trunk, there should not be a 'view' link in appadmin select. On Nov 18, 6:20 am, Seeker wrote: > Thanks Massimo, but I am up to date on trunk (change set 1223 > mercurial), but both the problems still persist. > > On Nov 18, 2:06 pm, mdipierro wrote: > > > fix

[web2py] Re: Please help: Are these errors?

2010-11-18 Thread mdipierro
My bad. I did not push the change. Please check again in trunk. On Nov 18, 6:20 am, Seeker wrote: > Thanks Massimo, but I am up to date on trunk (change set 1223 > mercurial), but both the problems still persist. > > On Nov 18, 2:06 pm, mdipierro wrote: > > > fixed in trunk > > > On Nov 18, 1:47

[web2py] Re: Upgrade problem

2010-11-18 Thread mdipierro
what is you configuration (source/binary, apache/rocket)? On Nov 18, 6:35 am, Kenneth Lundström wrote: > The Upgrade problem I can t test of course but now I manually upgraded > to 1.89.3 and still have the problem with creating a new application. > > Kenneth > > > I do not have enough informatio

Re: [web2py] Re: Upgrade problem

2010-11-18 Thread Kenneth Lundström
Apache, mod_wsgi, Linux, MySQL, source Kenneth what is you configuration (source/binary, apache/rocket)? On Nov 18, 6:35 am, Kenneth Lundström wrote: The Upgrade problem I can t test of course but now I manually upgraded to 1.89.3 and still have the problem with creating a new application.

Re: [web2py] Guido on pep8

2010-11-18 Thread Bruno Rocha
+1 :) // Shutting the mouth of the purist pythonistas who criticized web2py API 2010/11/18 mdipierro > http://mail.python.org/pipermail/python-dev/2010-November/105681.html > > :-) -- Bruno Rocha http://about.me/rochacbruno/bio

Re: [web2py] Customize the Appearance of the menu

2010-11-18 Thread Martín Mulone
In the last version of web2py you can pass A() helper instead of URL, so you can customize as you want. View the new welcome. For example, this change menu if there log in: models/menu.py if is_user_logged_in(): response.menu += [ (T('My account'), False, A(T('My account'),_href='javascr

[web2py] Losing sessions

2010-11-18 Thread Bruno Rocha
Is there someone else having problems to keep sessions in 1.89.3 + apache mod_wsgi ?? My app is creating a new session on every new request. (I am runnnig survey cloud applicance, with few changes) -- Bruno Rocha http://about.me/rochacbruno/bio

[web2py] Re: Upgrade problem

2010-11-18 Thread mdipierro
I see the problem but I do not understand why you have it. This should manifest itself when you upgrade, not when you create a new app. Can you list steps to reproduce the problem? I am close to fixing it... On Nov 17, 3:31 pm, Kenneth Lundström wrote: > I tried to upgrade version 1.89.1 to 1.89

[web2py] Re: Losing sessions

2010-11-18 Thread mdipierro
This http://web2py.com/examples/session_examples/counter runs on 1.89.3 and apache+mod_wsgi On Nov 18, 6:57 am, Bruno Rocha wrote: > Is there someone else having problems to keep sessions in 1.89.3 + apache > mod_wsgi ?? > > My app is creating a new session on every new request. > > (I am runnn

[web2py] Re: Precise behaviour of "compute" on record update

2010-11-18 Thread cjrh
"I have a field that is a uuid which is only supposed to be calculated once, on insertion." Best way to do this currently? I would use "default" if within the context of a controller, but these are records I create manually in admin. There is a field that I want populated with a newly-calculated

[web2py] Re: Customize the Appearance of the menu

2010-11-18 Thread annet
Hi Joe, The code in the view works: {{if not response.menu:}} Browse Sign up {{else:}} {{for _name,_active,_link in response.menu:}} {{=_name}} {{pass}} {{pass}} However, when trying to reproduce the problem I noticed the following: given this menu:

Re: [web2py] Re: Upgrade problem

2010-11-18 Thread Kenneth Lundström
- unpacked the source package - did a chown apache:web2py on all files - login in to admin - write the name of the new application and press create - get the unable to create application "test" Upgrade problem, the same, but - select upgrade - press YES - get the error ticket I don´t know what e

Re: [web2py] Re: Losing sessions

2010-11-18 Thread Bruno Rocha
That is running here locally too. ( http://192.168.0.7/examples/session_examples/counter) I think the problem is in SurveyCloud app or in some change that I've made on that. that was working tomorrow, I made no changes and now it is killing sessions. I will change the answer.sa record by the requ

Re: [web2py] Re: Losing sessions

2010-11-18 Thread Bruno Rocha
replace('tomorrow','yesterday') 2010/11/18 Bruno Rocha > That is running here locally too. ( > http://192.168.0.7/examples/session_examples/counter) > > I think the problem is in SurveyCloud app or in some change that I've made > on that. > that was working tomorrow, I made no changes and now it

[web2py] Re: session not saving variables?

2010-11-18 Thread Crim
Suppose i am storing something that is not pickable why would it clear all my other values at the same time too On Nov 18, 6:00 am, mdipierro wrote: > Three possibilities: > - you are storing in session something that is not pickable > - file system permissions error > - browser cookies disabled

Re: [web2py] session not saving variables?

2010-11-18 Thread Bruno Rocha
Same problem here. Yesterday that was working well, today the sessions are being created in every request. I am watching the app/sessions folder ( one new file per second ) File system permissions not changed 2010/11/18 Crim > so my website was working yesterday and now for some reason the >

[web2py] Re: Please help: Are these errors?

2010-11-18 Thread Seeker
:-) Thanks. will do. On Nov 18, 2:45 pm, mdipierro wrote: > My bad. I did not push the change. Please check again in trunk. > > On Nov 18, 6:20 am, Seeker wrote: > > > > > Thanks Massimo, but I am up to date on trunk (change set 1223 > > mercurial), but both the problems still persist. > > > On

[web2py] Re: Precise behaviour of "compute" on record update

2010-11-18 Thread mdipierro
>>> db=DAL() >>> db.define_table('xxx',Field('yyy',writable=False,readable=False)) >>> db.xxx.yyy.default=lambda: 'hello world' >>> db.xxx.insert() 1 >>> print db.xxx(1).yyy hello world default can be a lambda. On Nov 18, 7:05 am, cjrh wrote: > "I have a field that is a uuid which is > only sup

[web2py] Re: Upgrade problem

2010-11-18 Thread mdipierro
Thanks Kenneth, the traceback you posted applies to the second problem and I understand that. I am scratching my head on why that traceback would also apply to the first problem. Massimo On Nov 18, 7:09 am, Kenneth Lundström wrote: > - unpacked the source package > - did a chown apache:web2py o

Re: [web2py] bug in the book or in the code? linkedin instruction

2010-11-18 Thread Kuba Kucharski
one more thing, w/o registration process I cannot do: auth.settings.register_onaccept=lambda form:auth.add_permission(auth.user_group(form.vars.id),'create','my_table') how to handle it then? I tried to search for the place in the code where the group for the user is created but I cannot find it e

[web2py] Standalone DAL - connection to sqlite db - running web2py

2010-11-18 Thread Ole Martin Maeland
Hi, I am trying to connect to sqlite db that works fine with a small web2py applicaiton. connection parameters: >>> dbfolder='C:\web2py\web2py\applications\teqb\databases' >>> db = dal.DAL('sqlite://storage', folder=dbfolder) error message: Traceback (most recent call last): File "", line

[web2py] Re: Standalone DAL - connection to sqlite db - running web2py

2010-11-18 Thread mdipierro
I think you do not have write access on this file/folder On Nov 18, 7:36 am, Ole Martin Maeland wrote: > Hi, > > I am trying to connect to sqlite db that works fine with a small web2py > applicaiton. > > connection parameters: > > >>> dbfolder='C:\web2py\web2py\applications\teqb\databases' > >>>

Re: [web2py] experts4solutions.com again

2010-11-18 Thread Bruno Rocha
Endorsement has only 'no' option? You endorse: no (your your/no endorsement is confidential) Where can I endorse someone? 2010/11/18 mdipierro > I have implemented an endorsement mechanism. Existing members can see > and endorse new applican

Re: [web2py] experts4solutions.com again

2010-11-18 Thread Bruno Rocha
humm, I just figure out that I have to click in 'no' to toggle it to yes! not so clear. 2010/11/18 Bruno Rocha > Endorsement has only 'no' option? > > You endorse: no (your > your/no endorsement is confidential) > > Where can I endorse someon

[web2py] VirtualField Issues

2010-11-18 Thread VijayS
Hello, I am new to web2py, and this group. I was conversing on IRC and it was suggested by dingding1 that I should post this here. I think there's a bug with virtualfields. It seems that if I try to use a select() statement with only one field name, then virtualfields will fail to work as it can

Re: [web2py] Re: Standalone DAL - connection to sqlite db - running web2py

2010-11-18 Thread Ole Martin Maeland
Hi Massimo, I have administrator access on the folder. The database is running a small web2py application that is crypted. Do I have to pass the crypt string to the db, or do I have to use administrator password in order to access it. I reach it by using SQLite Manager.. regards Martin On T

[web2py] Re: PostgreSQL super slowdowns

2010-11-18 Thread Chris
I added your limitby code to some places. I haven't seen the same slowdowns recently, though, so it's hard to tell what happened - maybe it's from a fresh install of postgresql? We'll see if it comes back. On Nov 1, 11:01 pm, KMax wrote: > Please check .first() or .last() usage. > With Postgres f

Re: [web2py] Re: Upgrade problem

2010-11-18 Thread Kenneth Lundström
OK, I have no idea if they are related, it was just a thought on my part. Kenneth Thanks Kenneth, the traceback you posted applies to the second problem and I understand that. I am scratching my head on why that traceback would also apply to the first problem. Massimo On Nov 18, 7:09 am, Ke

[web2py] Re: experts4solutions.com again

2010-11-18 Thread selecta
A bit off topic question - I am currently happily employed and developing web2py based open source applications, but when this changes I might want to have a foot in the door for finding a job hacking web2py apps. Should i register at experts4solutions and state that I am currently not interested i

[web2py] Re: social network, event planners, and the like?

2010-11-18 Thread selecta
some parts are implemented (plugin based) in the project that I will submit in the application exhibition 2.0 ... On Nov 17, 8:42 pm, mdipierro wrote: > Not exactly but this is a good place to start: > > http://web2py.com/appliances/default/show/71 > > On Nov 17, 12:59 pm, Carlos wrote: > > > >

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Jason Brower
That would be up to you. I know I have registered. On Thu, 2010-11-18 at 07:10 -0800, selecta wrote: > A bit off topic question - > I am currently happily employed and developing web2py based open > source applications, but when this changes I might want to have a foot > in the door for finding

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Jason Brower
I didn't endorse him because I wanted to follow the rule. :D On Thu, 2010-11-18 at 04:04 -0800, mdipierro wrote: > No. ;-) > > On Nov 17, 9:40 pm, Nathan Freeze wrote: > > Massimo, your bio is missing a pic. Is it okay to endorse you? :) > > > > On Wed, Nov 17, 2010 at 9:23 PM, mdipierro wrote

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Kenneth Lundström
I´m too happily employed but doing some web2py development on my spare time. You never know when a big,perfect job comes looking for you. If your not on the list it might go to somebody else. Kenneth A bit off topic question - I am currently happily employed and developing web2py based open

Re: [web2py] Re: PostgreSQL super slowdowns

2010-11-18 Thread Michele Comitini
LIMITing results to max 1, is a good practice when you expect at most 1 result. On postgresql it is very important to create indexes to have huge performance boosts. Check your slow queries with the EXPLAIN command (see on postgresql.org) and make appropriate indexes. Also do cluster long tables

Re: [web2py] Re: How do we add projects or post a request for a new job on expert exchange?

2010-11-18 Thread Jason Brower
That would be awesome! I think we could have a more pertinent way to find people to work with with a simple search were you could type what kind of project you are wanting to do and it response with people with a particular ranking and relavence. It would also be nice to get "recommended" by our c

Re: [web2py] Re: social network, event planners, and the like?

2010-11-18 Thread Jason Brower
I have a product that is going to be my main income that does event planning. It has social aspects as well. If your interested in helping make the project go further, please contact me privately and I can show you how it works and you can give feedback on what you would like. I have used it at 4

[web2py] Re: VirtualField Issues

2010-11-18 Thread mdipierro
You make a good point. The code must be revised to take care of this situation. I need to think about it. On Nov 18, 8:20 am, VijayS wrote: > Hello, > >  I am new to web2py, and this group. I was conversing on IRC and it > was suggested by dingding1 that I should post this here. > > I think there

[web2py] Re: Standalone DAL - connection to sqlite db - running web2py

2010-11-18 Thread mdipierro
I do not understand the meaning of "web2py application that is crypted" On Nov 18, 8:56 am, Ole Martin Maeland wrote: > Hi Massimo, > > I have administrator access on the folder. The database is running a small > web2py application that is crypted. Do I have to pass the crypt string to > the db,

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Bruno Rocha
Some questions about projects page: http://experts4solutions.com/e4s/default/projects Can I add any public website that I've create powered by web2py ? (even if not a corporate site) Can I add a public website even wothout this source code? Can I add any application that I am not the creator, just

[web2py] Re: experts4solutions.com again

2010-11-18 Thread mdipierro
I think for now we should only list people who are available to do work, even if only on a part time bases. We could add a flag (available, not available) but people not avaiable would not be listed. On Nov 18, 9:10 am, selecta wrote: > A bit off topic question - > I am currently happily employed

[web2py] Re: experts4solutions.com again

2010-11-18 Thread mdipierro
If you are fully employed but willing to take some part time work it is perfectly ok to be listed. On Nov 18, 9:21 am, Kenneth Lundström wrote: > I m too happily employed but doing some web2py development on my spare > time. You never know when a big,perfect job comes looking for you. If > your n

[web2py] Re: experts4solutions.com again

2010-11-18 Thread DenesL
Two comments: 1) In the title, experts4solutions is missing a t 2) We should have some mechanism to prevent email address harvesting, no one wants to get spammed. Denes

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Bruno Rocha
> > > > 2) We should have some mechanism to prevent email address harvesting, > no one wants to get spammed. > > Better to have a simple contact form(with captcha) that sends a message directly to the expert mail. just like the 'mail me' button in http://about.me/rochacbruno/bio -- Bruno Rocha h

[web2py] Re: How do we add projects or post a request for a new job on expert exchange?

2010-11-18 Thread mdipierro
I am working on some sample legal agreements. The points to make are: - the client hires you not experts4solutions - experts4solutions can sell you code review and long term support but that is optional - clients who take a job via experts4solutions should meet some guidelines (suggest the client s

[web2py] Re: Standalone DAL - connection to sqlite db - running web2py

2010-11-18 Thread mart
Hey, It took me a few tries before getting this to work. So, I see 2 things that you may want to try to look at: 1) I don't really use windows, but I think the first line is problematic. (unless more recent windows versions have gotten smarter about slashes?). >>> dbfolder='C:\web2py\web2py\appl

[web2py] striped tables

2010-11-18 Thread Bruno Rocha
Now I am using this code: http://pastebin.com/BbizfpcE to create striped tables with a Row object. Is there an easy way? can SQLTABLE be striped? -- Bruno Rocha http://about.me/rochacbruno/bio

[web2py] Re: striped tables

2010-11-18 Thread Bruno Rocha
Without the enumerate works if we do have an id: http://pastebin.com/h0bnZjqR 2010/11/18 Bruno Rocha > Now I am using this code: http://pastebin.com/BbizfpcE to create striped > tables with a Row object. > > Is there an easy way? can SQLTABLE be striped? > > -- > > Bruno Rocha > http://about.me/

Re: [web2py] Re: decimal validator by default or not

2010-11-18 Thread Richard Vézina
Ok... I could set it to : (0,00.99) for example. Thanks! Richard On Wed, Nov 17, 2010 at 6:00 PM, mdipierro wrote: > 4,2 have to do with precision, not range. > > On Nov 17, 4:18 pm, Richard Vézina > wrote: > > Ok, > > > > I think I wrongly define the IS_DECIMAL_IN_RANGE > > > > I set it to (

[web2py] Re: decimal validator by default or not

2010-11-18 Thread mdipierro
If we were to do it I would have gone for (-99.99,+99.99) On Nov 18, 10:50 am, Richard Vézina wrote: > Ok... I could set it to : (0,00.99) for example. > > Thanks! > > Richard > > On Wed, Nov 17, 2010 at 6:00 PM, mdipierro wrote: > > 4,2 have to do with precision, not range. > > > On Nov 17, 4:

[web2py] Re: striped tables

2010-11-18 Thread villas
> Is there an easy way? can SQLTABLE be striped? SQLTABLE already has so you just style those classes. -D

[web2py] Re: New style 1.89.X forms seem washed out?

2010-11-18 Thread mdipierro
I actually like it as it is. On Nov 18, 10:58 am, Ron McOuat wrote: > I added email subscription so now I can attach a PNG of what I see on Ubuntu > 10.04 default install. > > I will fix it for my own purposes, but am wondering if there is room to > consider improving the defaults? > > Ron > > On

Re: [web2py] Re: web2py converts the data to thml chars from controller to view

2010-11-18 Thread Daniel Gonzalez
Hi! Thx! It looks that all that i need was the TAG() helper :) Regards! El mar, 16-11-2010 a las 01:46 -0800, villas escribió: > Hi Demetrio > > Take a look at the XML helper: > > http://web2py.com/book/default/chapter/05 > > Regards, D > > On Nov 16, 12:52 am, demetrio wrote: > > Hi ever

[web2py] model definition

2010-11-18 Thread Richard Vézina
Hello, I would clarify my understanding a bit... In the book it says : Notice that requires=... is enforced at the level of forms, required=True is enforced at the level of the DAL (insert), while notnull, unique and ondeleteare enforced at the level of the database. While they sometimes may seem

[web2py] Directory app

2010-11-18 Thread Carlos
Hi, I was wondering if a Directory app has been implemented in web2py?. With similar features as described in the following thread: http://groups.google.com/group/web2py/browse_thread/thread/b6019d54d4ec8f23/09892cb7d92b15c3 This is related to my inquiries about Social Networking and Event Plan

[web2py] Re: social network, event planners, and the like?

2010-11-18 Thread Carlos
Hi selecta, When can I see your project?, will it be free open-source?, what features does it have?. Unless no info should not be revealed before this exhibition?, which btw when will it be?. Thanks, Carlos On Nov 18, 9:14 am, selecta wrote: > some parts are implemented (plugin based) in

Re: [web2py] Re: web2py converts the data to thml chars from controller to view

2010-11-18 Thread Bruno Rocha
You can call your function with .load extension app/default/action.load 2010/11/18 Daniel Gonzalez > Hi! > > Thx! It looks that all that i need was the TAG() helper :) > > Regards! > > > El mar, 16-11-2010 a las 01:46 -0800, villas escribió: > > Hi Demetrio > > > > Take a look at the XML helper

Re: [web2py] session not saving variables?

2010-11-18 Thread Bruno Rocha
Can it be a matter of current server datetime problems? def is_expired(self, seconds = 3600):now = datetime.datetime.today()if not self._last_timestamp or \ self._last_timestamp + \ datetime.timedelta(seconds = seconds) > now: self._last_timest

[web2py] Re: session not saving variables?

2010-11-18 Thread mdipierro
sessions never expire although there is an admin/cron job that deletes them. On Nov 18, 12:08 pm, Bruno Rocha wrote: > Can it be a matter of current server datetime problems? > > def is_expired(self, seconds = 3600):        now = > datetime.datetime.today()        if not self._last_timestamp or \

[web2py] Re: session not saving variables?

2010-11-18 Thread mdipierro
auth sessions (in session.auth) do expire On Nov 18, 12:08 pm, Bruno Rocha wrote: > Can it be a matter of current server datetime problems? > > def is_expired(self, seconds = 3600):        now = > datetime.datetime.today()        if not self._last_timestamp or \ >           self._last_timestamp +

[web2py] Re: Validate dynamically generated select SQLFORM.factory

2010-11-18 Thread Kostas M
It seems I don't understand what is the problem. Isn't the intended action the form to have errors if nothing is selected? This is checked with the: if form.accepts(request.vars, session): ... > My app throws an error if you click the submit button without selecting an > item from the list in the

[web2py] replace delete with inactive

2010-11-18 Thread Carlos
Hi, I'm trying to replace the built-in delete behavior in crud.update (deletable=True) with a boolean active field instead, in order to NOT do a hard-delete of any records but instead a soft-delete via the active flag. I'm also using onaccept=crud.archive. I successfully manage to cancel the del

[web2py] Re: replace delete with inactive

2010-11-18 Thread mdipierro
good point. This will work: if request.post_vars.delete_this_record: del request.post_vars.delete_this_record db.t_person.active.update=False there are two problems in your example: - you are using request.vars and not request.post_vars which crud uses and therefore the varia

[web2py] Re: Precise behaviour of "compute" on record update

2010-11-18 Thread cjrh
On Nov 18, 3:46 pm, mdipierro wrote: > >>> db=DAL() > >>> db.define_table('xxx',Field('yyy',writable=False,readable=False)) > >>> db.xxx.yyy.default=lambda: 'hello world' > >>> db.xxx.insert() > 1 > >>> print db.xxx(1).yyy > > hello world > > default can be a lambda. I did not know that. I'm goi

[web2py] Migrations questions (help!)

2010-11-18 Thread Lorin Rivers
My database is PostgreSQL I have tables defined in my ../models/db.py Now I want to add some fields to one of the tables defined there. The table has data in it already. I tried modifying the original table definition but that didn't actually change the table's structure. Where should I make

[web2py] Re: replace delete with inactive

2010-11-18 Thread Carlos
Thanks Massimo ! On Nov 18, 1:41 pm, mdipierro wrote: > good point. > > This will work: > >     if request.post_vars.delete_this_record: >         del request.post_vars.delete_this_record >         db.t_person.active.update=False > > there are two problems in your example: > - you are using reque

[web2py] Re: Migrations questions (help!)

2010-11-18 Thread VP
Unless you have migration set to False, these things should be automatic. On Nov 18, 1:53 pm, Lorin Rivers wrote: > My database is PostgreSQL > > I have tables defined in my ../models/db.py > > Now I want to add some fields to one of the tables defined there. The table > has data in it already

Re: [web2py] Re: Migrations questions (help!)

2010-11-18 Thread Lorin Rivers
They are not set to false. I'm coming from a slight rails perspective (some experience with it). In rails, migrations are sequential. If you want to add a field to a table, you create a new migration that only does that. Regarding my question, then, do most people just edit the model (i.e., add

Re: [web2py] Re: Migrations questions (help!)

2010-11-18 Thread Kenneth Lundström
Correct, you edit the db.py file and reload a page and the database is updated. Kenneth They are not set to false. I'm coming from a slight rails perspective (some experience with it). In rails, migrations are sequential. If you want to add a field to a table, you create a new migration th

[web2py] Re: verification login

2010-11-18 Thread mattynoce
i don't know if there is way to do this through settings but i invented my own method to log in a user after verification. the user has registered and thus has a row in auth_user. in the model: auth.settings.registration_requires_verification = True auth.settings.verify_email_next = '/init/default

[web2py] Bug in response.stream

2010-11-18 Thread Clayton
The chunk_size seems to be ignored in response.stream def stream( self, stream, chunk_size = DEFAULT_CHUNK_SIZE, request=None, ): """ if a controller function:: return response.stream(file, 100) the file content will

[web2py] Re: verification login

2010-11-18 Thread mdipierro
I am assuming you are not using Janraion Oauth, etc. 1) make sure the db.auth_user has a Field('registration_completed','boolean',default=True,writable=False,readable=False) (default must be True if regular use go thought normal registration process) and a Field('parent_user','reference auth_user'

[web2py] Re: Migrations questions (help!)

2010-11-18 Thread mdipierro
As a rails user, would you share your experience with web2py so far? What you like, what you do not, what you think rails is better at? We'll defend ourselves but not take any offense. This can help us improve. Massimo On Nov 18, 2:47 pm, Lorin Rivers wrote: > They are not set to false. > > I'm

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Branko Vukelic
On Thu, Nov 18, 2010 at 5:01 PM, Bruno Rocha wrote: > Some questions about projects > page: http://experts4solutions.com/e4s/default/projects > Can I add any public website that I've create powered by web2py ? (even if > not a corporate site) > Can I add a public website even wothout this source c

[web2py] Re: Bug in response.stream

2010-11-18 Thread mdipierro
Not a bug. chunk_size applies when you are returning a file-like object that needs to be streamed. If you return a string, it is not streamed. Massimo On Nov 18, 3:04 pm, Clayton wrote: > The chunk_size seems to be ignored in response.stream > >     def stream( >         self, >         strea

[web2py] Re: experts4solutions.com again

2010-11-18 Thread mdipierro
There are two options: 1) you can list all the projects you worked on, whether or no web2py related, whether or not open source, in your page profile. You can add links and you can add pictures. There are no restrictions because you are advertising yourself. 2) you can submit projects to the list

Re: [web2py] Re: Migrations questions (help!)

2010-11-18 Thread Lorin Rivers
I self-taught hacker (I would never describe myself as a programmer), I found rails to be less clear, it seem to be unnecessarily terse. I hate how ruby loops, I can never remember the syntax. I find that DHH's personality flavors the framework (in a bad way) as your personality flavors web2py

[web2py] Re: Migrations questions (help!)

2010-11-18 Thread mdipierro
> I find the migrations to not work that well and fail silently. there is one catch with migrations. If you use sqlite, you cannot change the type of field because sqlite will accept but will not actually change the column type. It is because sqlite has limited ALTER TABLE support. Massimo > >

[web2py] Re: Bug in response.stream

2010-11-18 Thread Clayton
Ok, thanks for that. However, when I call response.stream(myfilename, request=request), it seems to stream it in 64K chunks, and tracing the code confirms it as far as I can see. I'm confused because despite passing in chunk_size as a parameter, it had no effect on the streaming. Also I'm not unde

[web2py] Typo in Official Web2py book

2010-11-18 Thread karl simon
Not sure if this is the place to post this, but, I think there is a typo in the Official Web2py book in chapter 10: http://web2py.com/book/default/chapter/10 In the section labeled "The Ajax Function: {{extend 'layout.html'}} I believe id="name" should be name="name". I tried it with id="na

Re: [web2py] Re: experts4solutions.com again

2010-11-18 Thread Bruno Rocha
I have one E-store online here: http://natalanimal.com.br/ I want to list the sites I've made, and I want to include my contribution to web2py with mainsite/examples app, also I want to list some public visible websites. Where should I point this? on my profile or in projects? Will web2py itself

[web2py] Re: problem whith admin

2010-11-18 Thread Jose
Daniel Gonzalez, The patch works well for me. Thanks Jose

[web2py] Re: gluon/contrib/login_methods/linkedin_account.py - anyone deployed this?

2010-11-18 Thread Carl
Michele, I have the germ of something that works. Your code outline was pretty close... In a controller function... auth.settings.login_form = LinkedInAccount(globals(),CLIENT_ID,CLIENT_SECRET, AUTH_URL, TOKEN_URL, ACCESS_TOKEN_URL) token = auth.settings.login_form.accessToken() if to

  1   2   >