Re: [web2py] Re: nginx+uwsgi and ubuntu 12.10

2012-10-23 Thread Bruce Wade
t;> uwsgi stop working ? >> >> (using latest web2py and nginx+uwsgi script - 2.2.1 Stable) >> >> Just wondering... >> >> -- >> []'s >> Marco Tulio >> > > > > -- > []'s > Marco Tulio > > -- > > > >

Re: [web2py] Re: Avoiding loading models for the public portion of a site

2012-08-29 Thread Bruce Wade
c that needs to be shared but that > isn't applicable to the public-side of the site. I can't use your solution > to make any gains there. > > > On Wednesday, August 29, 2012 2:25:11 AM UTC-4, Bruce Wade wrote: > >> Ok see attached. >> >> 1) I left the def

Re: [web2py] Re: Avoiding loading models for the public portion of a site

2012-08-28 Thread Bruce Wade
I am righting a quick example app as I don't think anyone is really understanding what I am saying :D I will email it within the next 30 mins. On Tue, Aug 28, 2012 at 10:36 PM, Bruce Wade wrote: > Conditional models will work, however not with the default design as you > may have

Re: [web2py] Re: Avoiding loading models for the public portion of a site

2012-08-28 Thread Bruce Wade
; application. With such a setup, it makes no sense to be loading >>>>> models for the public portion of the site, as it's just some semi-static >>>>> pages and a login form. So I'm wondering >>>>> >>>>>- a) Is

Re: [web2py] Re: Avoiding loading models for the public portion of a site

2012-08-28 Thread Bruce Wade
; login form. So I'm wondering >> >>- a) Is there a way to prevent models loading at the request or >>controller level? >>- b) Should the 'public' site be part of the same application at all, >> or should it be a separate light-weight

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-17 Thread Bruce Wade
; >> massimo.dipie...@gmail.com> wrote: >> >>> I remind the readers we have conditional models: >>> >>> models/db.py (runs for every action) >>> models/default/db.py runs (runs only for actions in >>> controllers/default.py) >>>

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-17 Thread Bruce Wade
still thinking whether having a different file per action would be worth it to improve speed. On Tue, Jul 17, 2012 at 9:40 AM, Bruce Wade wrote: > LOL well the before and after performance improvements from moving the > models has proven it to be a major problem. So yes models are definitely

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-17 Thread Bruce Wade
, pbreit wrote: > I'd be surprised if model processing is your biggest problem. Have you > reviewed all your queries for optimization opportunities? Cache, cache and > more cache? Indexes? > > -- > > > > -- -- Regards, Bruce Wade http://ca

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-17 Thread Bruce Wade
do get it right based on the input provided > and perhaps it will be some benefit to others who won't make the same > mistakes I made. :>) > > -- > > > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittrai

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-16 Thread Bruce Wade
splitting >>> these tables into multiple model files? The tables belong to a single >>> database and most use the auth_user table as a referenced table. >>> >>> I'm assuming that they're all going to get read in regardless, >>>

Re: [web2py] Re: Help! IOErrors

2012-07-16 Thread Bruce Wade
vars(request, environ) >>>> File "C:\\dashboard\\web2py\\gluon\**\main.py", line 275, in >>>> parse_get_post_vars >>>> request.body = copystream_progress(request) ### stores request body >>>> File "C:\\dashboard\\web2py\\gluon\**\main.py

Re: [web2py] Re: Recommendations on model file size (database tables)

2012-07-16 Thread Bruce Wade
Split models folder into multiple folders 1 per controller then define tables used for each controler.. for more fine control add folders inside the folders you just created with one per controller action and define only tables used for that action. On Jul 16, 2012 2:47 PM, "Anthony" wrote: > The

Re: [web2py] Re: Help! IOErrors

2012-07-16 Thread Bruce Wade
t redirect to login._next after the login, >> and other issues. Also I think sessions in db gets a bit slower. >> >> I am planning to test sessions in redis. >> >> >> On Mon, Jul 16, 2012 at 1:01 PM, Bruce Wade wrote: >> >>> That I/o warning shouldn&#

Re: [web2py] Re: Help! IOErrors

2012-07-16 Thread Bruce Wade
he browser >> declares a different size than it sends). Perhaps because of network >> issues. Perhaps web2py could report a better (clearer error). Do you think >> it should be logged or silently ignore and the request dropped? >> >> Massimo >> >> >> On

Re: [web2py] Re: Help! IOErrors

2012-07-16 Thread Bruce Wade
_size) >> File "C:\\dashboard\\web2py\\gluon\**\fileutils.py", line 374, in >> copystream >> data = src.read(size) >> IOError: request data read error >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Help! IOErrors

2012-07-16 Thread Bruce Wade
t; > > I have never worked on Windows with Apache but this looks like either > incorrect ownership of the web2py files or just a permission problem. > > Make sure the user that owns Apache process is the one that owns the > web2py tree or at least has full access to it. > > Re

Re: [web2py] Re: hi

2012-07-13 Thread Bruce Wade
On Thursday, 12 July 2012 15:22:26 UTC+5:30, ahmad wrote: >> >> please anyone can tell me about the web2py and it's community and if i >> learn it can i find a job easily >> >> -- -- Regards, Bruce Wade http://ca.linkedin.com/in/bruce

Re: [web2py] Re: postgres connect problem

2012-07-11 Thread Bruce Wade
to the > local under pg_hba.conf file and using the proper password. > > > also under python native: > > import psycopg2 > conn = psycopg2.connect('dbname=testbank user=postgres password=password') > > works fine also with no issues and conn shows a proper connection object. > so damn, even the psycopg2 driver is working either. > > lucas > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: postgres connect problem

2012-07-11 Thread Bruce Wade
23/deploy-web2py-** >> on-fedoracentosred-hat<http://www.web2pyslices.com/slice/show/1423/deploy-web2py-on-fedoracentosred-hat> >> >> lucas >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: postgres connect problem

2012-07-11 Thread Bruce Wade
cas wrote: >> >> and i did "CREATE DATABASE testbank;" under psql and it does exist as an >> empty database at this point. >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Website running extremely slow

2012-07-07 Thread Bruce Wade
Remove any requires you have in you models will reduce function calla On Jul 7, 2012 3:53 PM, "howesc" wrote: > do you have anything in models that run queries? i made that mistake once > and it slowed things down a lot! > > On Friday, July 6, 2012 11:51:38 AM UTC-7, wdtatenh wrote: >> >> My web

[web2py] Production performance lessions uwsgi + nginx

2012-07-07 Thread Bruce Wade
per second you can get. Also - if you can change the way nginx talks to uwsgi - instead of local tcp connection use file socket - you want hammer tcp stack with a lot of connections. in uwsgi config use: "socket = /var/run/uwsgi.socket" in nginx config use: "uwsgi_pass unix:///v

Re: [web2py] Re: Website running extremely slow

2012-07-06 Thread Bruce Wade
unning web2py??? Perhaps not??? Scratching my head. >> >> Appreciate any thoughts anyone might have. >> >> thanks in advance >> Bill >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Updated deplopyment docs?

2012-07-05 Thread Bruce Wade
ython is > generally poorly supported in shared hosting environments. > > Does your host provide any information about deploying Python apps? > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal

Re: [web2py] Redirect not working can't find issue

2012-07-05 Thread Bruce Wade
July 2012 21:35:44 UTC+1, Bruce Wade wrote: > >> No problem, I have ran into that problem when I was first learning :D >> >> On Thu, Jul 5, 2012 at 1:34 PM, adohertyd wrote: >> >> Yeah it works now. Thanks very much Bruce much appreciated. Still have >>>

Re: [web2py] Redirect not working can't find issue

2012-07-05 Thread Bruce Wade
10 UTC+1, Bruce Wade wrote: > >> It shouldn't look at your javascript console, if you are using ajax to >> call this. >> >> On Thu, Jul 5, 2012 at 1:30 PM, adohertyd wrote: >> >> Thanks Bruce will try that. Why does 'return blekkoresults' work th

Re: [web2py] Redirect not working can't find issue

2012-07-05 Thread Bruce Wade
It shouldn't look at your javascript console, if you are using ajax to call this. On Thu, Jul 5, 2012 at 1:30 PM, adohertyd wrote: > Thanks Bruce will try that. Why does 'return blekkoresults' work though? > > > On Thursday, 5 July 2012 21:24:53 UTC+1, Bruce Wade w

Re: [web2py] Redirect not working can't find issue

2012-07-05 Thread Bruce Wade
> {{=results}} > > On Thursday, 5 July 2012 21:20:59 UTC+1, Bruce Wade wrote: > >> I am assuming by your error inside results.html you have a variable >> defined as results however you are passing a tuple blekkoresults,bingresults >> we would need to see results.html &

Re: [web2py] Redirect not working can't find issue

2012-07-05 Thread Bruce Wade
roblem. However, with the >>> bing section included I get the following error: >>> >>> 1. >>> 2. >>> 3. >>> 4. >>> 5. >>> 6. >>> >>> Traceback (most recent call last): >>> File "C:\web2py\gluon\restricted.**py", line 205, in restricted >>> >>> exec ccode in environment >>> File "C:\web2py\applications\**metasearch2\views\manage/**results.html", >>> line 86, in >>> NameError: name 'results' is not defined >>> >>> Can anyone please tell me what's going on? If I run this program in IDLE >>> it returns the bing results so it is definitely a web2py issue. >>> >> >> -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Change password without the link...

2012-07-04 Thread Bruce Wade
user can change their password from the default >> features of auth without getting an email with the link? It seems the only >> way is the link to get an email with a link to change the password. >> BR, >> Jason Brower >> > > -- -- Regards, Bruce Wade

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-04 Thread Bruce Wade
from the web2py examples, and on the job. So I learnt python by writing > ukjazz.net. This site is pretty complete but not yet promoted. I found > python very easy to learn and such a nice language. Web2py plus python is a > dream come true. > > > Peter > > > On Tuesday,

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
s becoming a lot faster as we learned from > > a lot of mistakes. > > That's nice. I realise you won't have the time right now, but an article > summarising what you've learned would be good one day. > -- > We're looking for good Linux people: > http://ww

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
;We welcome all the new commers to > join this incredible site, Please full-fill the following form." > > Maybe the tech part is done, and it's time for the copywriters? > -- > We're looking for good Linux people: > http://www.tiger-computing.co.uk/jobs >

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
find it a little humorous when you think it is still in development mode and not in production :D On Tue, Jul 3, 2012 at 3:00 PM, Bruce Wade wrote: > Just watch the first page the how many ads views pulls the last record ID > inserted refresh that page a few times to see how active it is. >

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
Just watch the first page the how many ads views pulls the last record ID inserted refresh that page a few times to see how active it is. On Tue, Jul 3, 2012 at 2:54 PM, Bruce Wade wrote: > What do you mean the site isn't in production? Or course the site is in > production.

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
have often given valuable > feedback to the group about how to ensure that web2py sites do run > efficiently and I have learnt from your feedback. > > Peter > > > On Tuesday, 3 July 2012 19:07:50 UTC+1, Bruce Wade wrote: >> >> My site is probably the largest site

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
nt.com/ just to get the taste > of it, but can we create a website like ( Scribd / Slideshare / youtube etc > i mean big / large) > > > On Tue, Jul 3, 2012 at 10:15 PM, Bruce Wade wrote: > >> Well that depends, if you mean master it in knowing how to create models, >> vi

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
/contact http://127.0.0.1:8000/special will all work. On Tue, Jul 3, 2012 at 10:36 AM, ANIKET KADAM wrote: > thank you bruce but how much time period is needed to master web2py > > > On Tue, Jul 3, 2012 at 10:02 PM, Bruce Wade wrote: > >> No if you know HTML/CSS/Javascript yo

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
No if you know HTML/CSS/Javascript you can do whatever you want to the frontend very easily. On Tue, Jul 3, 2012 at 10:28 AM, ANIKET KADAM wrote: > is it very difficult to customize front end in web2py? > > > On Tue, Jul 3, 2012 at 9:54 PM, Bruce Wade wrote: > >> LOL all o

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Bruce Wade
going and create most apps: >>> http://web2py.com/books/default/chapter/29/2 >>> >> >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] How much Python is needed to learn to learn web2py?

2012-07-01 Thread Bruce Wade
; > Please help > > thank you > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Learning web2py need advise

2012-07-01 Thread Bruce Wade
g on, so i m willing to give full time to my > learning > and my other question is it is possible to make huge site like Scribd / > Slideshare / Youtube etc with web2py > i know the question is some what silly but around the web i have read it > is a micro framework. > > Than

Re: [web2py] Re: Image uploads to different server, mongodb with grid

2012-06-23 Thread Bruce Wade
current one of many servers. On Sat, Jun 23, 2012 at 7:09 AM, Massimo Di Pierro < massimo.dipie...@gmail.com> wrote: > > > On Friday, 22 June 2012 15:33:52 UTC-5, Bruce Wade wrote: >> >> Hi, >> >> I have 2 questions: >> >> First what is the process

[web2py] Image uploads to different server, mongodb with grid

2012-06-22 Thread Bruce Wade
backend? -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com --

Re: [web2py] Re: web2py and python 3.3 ?

2012-06-16 Thread Bruce Wade
all of existing apps. > > > massimo > > > On Saturday, 16 June 2012 17:17:55 UTC-5, samuel bonilla wrote: >> >> >> web2py 2.0 will supports python 3.3 ? >> > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com

Re: [web2py] Re: Very strange

2012-06-16 Thread Bruce Wade
ignature=True), _class="gridlink-button delete button-delete") ] # make search form == searchForm=FORM( LABEL(T('Search')), INPUT(_type='text', _name='searchKeyword', _id='search-keyword', _v

[web2py] Very strange

2012-06-15 Thread Bruce Wade
return self.log_execute(*a, **b) File "/home/developer/projects/yaw/gluon/dal.py", line 1386, in log_execute ret = self.cursor.execute(*a, **b) InternalError: current transaction is aborted, commands ignored until end of transaction block -- -- Regards, Bruce Wade http:

Re: [web2py] Re: Why errors for incompetent programmer?

2012-06-14 Thread Bruce Wade
ou can provide, the better we are able > to help. -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

[web2py] Are we the biggest site using web2py?

2012-06-13 Thread Bruce Wade
3 front end servers 3 database servers. If there is a bigger site please help us scale, ideally share the problems you have faced. :D Once we get the new union software and banner advertising software all the numbers will increase dramatically. -- -- Regards, Bruce Wade http://ca.linkedin.com

Re: [web2py] server down?

2012-06-13 Thread Bruce Wade
13 June 2012 16:13:25 UTC-5, JavierQQ wrote: >> >> >> On Wed, Jun 13, 2012 at 4:08 PM, davidjensen wrote: >> >>> cannot establish connection to www.web2py.com >>> 2012-06-13T17:11 >>> >> >> Me too :( >> why is this

[web2py] Benefit & Disadvantages of 'daemon'

2012-06-12 Thread Bruce Wade
Hi, What are the advantages and disadvantages of running web2py as Linux daemon? How would you scale this solution? Does this change how requests load models on every request? Would this make running the application much faster because web2py would always be running? -- -- Regards, Bruce Wade

Re: [web2py] Re: Help! Changed Password and now I get errors

2012-06-09 Thread Bruce Wade
ould set once > and get tables of the form prefix_tablename.migrate for everything, without > further hassle. Now all we need is a migration migration scheme...) > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Help me get a better feel for efficient code

2012-06-07 Thread Bruce Wade
gt; This is how Auth and Crud work: > http://code.google.com/p/web2py/source/browse/gluon/tools.py#898, > http://code.google.com/p/web2py/source/browse/gluon/tools.py#3056. > Probably the best approach when you need to access db from multiple methods. > > Anthony > >

Re: [web2py] Re: String EOF error

2012-06-06 Thread Bruce Wade
solution? > > > On Wednesday, April 25, 2012 5:29:09 PM UTC-4, Bruce Wade wrote: >> >> Hi I randomly get a EOFError this doesn't always happen and I have no idea >> what is causing it. >> >> Traceback (most recent call last): >> >> File &q

Re: [web2py] Re: Why would this happen?

2012-06-02 Thread Bruce Wade
7;yaw', ), yaw = dict( file_match = r'(.*)$',# legal file (path) name ), ) On Sat, Jun 2, 2012 at 8:57 PM, Bruce Wade wrote: > Ok thanks I will give it a try. > > > On Sat, Jun 2, 2012 at 8:51 PM, Jonathan Lundell wrote: > >> On Jun 2, 2012, at 6:32 PM,

Re: [web2py] Re: Why would this happen?

2012-06-02 Thread Bruce Wade
n question: > > routers = dict( > # base router > BASE = dict( > default_application = 'welcome', > ), > welcome = dict( >file_match = r'(.*)$',# legal file (path) name > ), > ) > > ...and you might want to be a little more restrictive than .* if you can. > But yeah, that's the idea. -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] new matplotlib library

2012-06-02 Thread Bruce Wade
Does this support multi-language mainly Chinese? On Jun 2, 2012 2:39 PM, "Massimo Di Pierro" wrote: > https://github.com/mdipierro/canvas >

Re: [web2py] Re: Why would this happen?

2012-06-02 Thread Bruce Wade
hement" should be "attachment" -- does that help? > > Anthony > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Why would this happen?

2012-06-02 Thread Bruce Wade
#x27;d be careful about directory traversal or > any similar vectors of attack. Web2py's upload/download mechanism has this > taken care of. And I'd test this download separately in IE, in any case. > I've stumbled on IE's quirks with such file names before... > > Regar

[web2py] Why would this happen?

2012-06-02 Thread Bruce Wade
llow to be downloaded. What is the correct way to accomplish this? -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread Bruce Wade
i-track is the winner I already have it integrated into my project and will build off of it. On Fri, Jun 1, 2012 at 7:01 AM, Bruce Wade wrote: > issue tracker there is an error when you click on projects on the demo not > a good example :D > i-track looks like a very good starting po

Re: [web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread Bruce Wade
ing at itracker now > Thanks. :) > > > On Fri, Jun 1, 2012 at 10:31 AM, stefaan wrote: > >> >> >> >> I have noticed one other tracker in web2py, but I couldn't demo it. >>> >>> Have you seen these? >> >> http://code.google.com/p/

Re: [web2py] Thinking of building a bug tracker...

2012-05-31 Thread Bruce Wade
ket when not connected locally accessing it. > BR, > Jason > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

[web2py] Full time work

2012-05-29 Thread Bruce Wade
Hi, Is anyone looking for some full time work? Could possibly lead to permanent. Goals optimization and scale. As well as adding to the advertising platform. Real-time banner ads. If you are interested send me an email with some work you have done and expect rate of pay in CAD Regards, Bruce

Re: [web2py] Re: Questions for an application with a large number of features and a large database.

2012-05-27 Thread Bruce Wade
Yes you can soft link however when you get to the point of multiple servers and upgrading code on each it is a pain. The site I`m working in is very large. I am now rewriting the code with a new technique in modules and using conditional if statements in side each module so you have 100% control o

[web2py] More DB issues

2012-05-25 Thread Bruce Wade
16935 of database 16386; blocked by process 20969. HINT: See server log for query details. CONTEXT: SQL statement "SELECT 1 FROM ONLY "public"."ads" x WHERE "id" OPERATOR(pg_catalog.=) $1 FOR SHARE OF x"Any suggestions? -- -- Regards, Bruce Wade h

Re: [web2py] Re: Google Translate

2012-05-23 Thread Bruce Wade
ack google translate with google analytics) On Wed, May 23, 2012 at 6:56 AM, greaneym wrote: > It is fine if you want to figure out vocabulary, but it is not very good > with grammatical structures, yet. It keeps improving though. > > > On Tuesday, May 22, 2012 5:56:44 PM UTC-5, Br

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-22 Thread Bruce Wade
og.tmp 52095 function calls (50779 primitive calls) in 0.085 seconds Ordered by: internal time List reduced from 727 to 80 due to restriction <80> On Mon, May 14, 2012 at 12:06 PM, Bruce Wade wrote: > Yes, I have started moving everything from models to custom api modules > t

[web2py] Google Translate

2012-05-22 Thread Bruce Wade
Has anyone tried this before? http://translate.google.com/translate_tools -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Pass multiple arguments to URL through javascript

2012-05-20 Thread Bruce Wade
$("url_with_params").attr('href', url); } On Sun, May 20, 2012 at 7:41 PM, Ashraf Mansour wrote: > both > > > > and > > > > > are not working ( they are not showing the values of param1 and param2 ) > > >> -- -- Regards,

Re: [web2py] Re: Pass multiple arguments to URL through javascript

2012-05-20 Thread Bruce Wade
n {{ }} ) > > > is there a solution without using jquery? > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Pass multiple arguments to URL through javascript

2012-05-20 Thread Bruce Wade
the client side -- which means > they cannot be set on the server side by web2py. Of course, I don't know > what he's actually doing on the client side, so this exact code may or may > not be relevant. Do you have an alternative suggestion? > > Anthony > > On Sund

Re: [web2py] Re: Pass multiple arguments to URL through javascript

2012-05-20 Thread Bruce Wade
nk').attr('href', '{{=URL("action")}}' + '/' + param1 + > '/' + param2); > }); > > > {{=A('...', _href='', _id='mylink')}} > > When the page is loaded, the href of the mylink anchor tag will b

Re: [web2py] Re: Pass multiple arguments to URL through javascript

2012-05-20 Thread Bruce Wade
{{=URL('controller','action', args=[arg1, arg2])}} On May 20, 2012 10:18 AM, "Ashraf Mansour" wrote: > I tried this > > > > and it did not work.:) > > what is the right way of doing it? > > On Saturday, December 3, 2011 7:37:58 PM UTC+3, Anthony wrote: >> >>

Re: [web2py] Re: nginx uwsgi error 502 bad gate way

2012-05-18 Thread Bruce Wade
ou put the > > rest of the directives? command line? > > > > Does anyone know how to have one uwsgi config file load another (as we do > > in apache)? I was trying to see an example or find it in uwsgi docs to > no > > avail. > > > > &g

Re: [web2py] Re: about uwsgi, nginx and such

2012-05-18 Thread Bruce Wade
um/#!topic/web2py/**moZqFqZ8eHo<https://groups.google.com/forum/#!topic/web2py/moZqFqZ8eHo> >> >> Are you on a cloud server that you can rebuild? If so, I'd recommend a >> rebuild and start from scratch. >> >> If your server comes with Apache pre-installed t

Re: [web2py] Re: nginx uwsgi error 502 bad gate way

2012-05-18 Thread Bruce Wade
o /var/web2py/, load wsgihandler module and bind to > socket 127.0.0.1:9001) > Now visit your website with your browser. Does it work ? > > If it does not work double check if /var/web2py is the correct path of > your web2py installation. > > -- > Roberto De Ioris >

Re: [web2py] Re: Conditional models

2012-05-15 Thread Bruce Wade
For example see attached, it isn't complete but will give a better example. On Tue, May 15, 2012 at 1:43 PM, Bruce Wade wrote: > Well one example is my location class, which contains countries, > provinces, and cities models. Having one class allows me to write a single > AP

Re: [web2py] Re: Conditional models

2012-05-15 Thread Bruce Wade
.guardian = Field("guardian", "reference guardian") > > class Meta: > tablename = "dog" > migrate = False > ... > > > I will try it today... > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade htt

Re: [web2py] Re: Conditional models

2012-05-15 Thread Bruce Wade
an, so need to define it before > dog = Dog(db) > dog.define_table() > > *# controllers/guardian.py* > > def index(): > return db(db.guardian).select(0 > > *# controller/dog.py* > > def index(): > return db(db.dog.guardian == db.guardian.id).select() > > It could be a little better, a singleton, a way to define references > automatically etc... > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Conditional models

2012-05-15 Thread Bruce Wade
Not sure using conditional models is "premature optimization" it is just better design. On Tue, May 15, 2012 at 12:14 PM, pbreit wrote: > "I'd better prevent running into performance problems" > > I generally advise against premature optimization. >

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-14 Thread Bruce Wade
7;t 135 table definitions going to be a problem in a high volume app? >> Aren't many/most of those 85k-100k function calls going to >> examining/parsing all those tabledefs? > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-13 Thread Bruce Wade
ction the >> model does not change (usually) at runtime. >> > > Yes, definitely turn off migrations -- you can do so for the entire > connection via: > > db = DAL(..., migrate_enabled=False) > > Also, compile the app -- I believe that particularly speeds up the view

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-13 Thread Bruce Wade
Youadworld is HUGE some tables even have 50 columns. On May 13, 2012 2:59 PM, "pbreit" wrote: > 135 tables to run YouAdWorld??

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-12 Thread Bruce Wade
Shouldn't be as I have deleted that default function. On May 12, 2012 4:36 PM, "Bruno Rocha" wrote: > Do you have images being seved by web2py using the default download > function? > > On Sat, May 12, 2012 at 7:51 PM, Bruce Wade wrote: > >> Ok so I started i

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-12 Thread Bruce Wade
> > You wasting *your* time trying to guess where the application is > wasting *its* time. > > mic > > 2012/5/12 Anthony : > > On Saturday, May 12, 2012 12:06:28 PM UTC-4, Bruce Wade wrote: > >> > >> Yeah I am going through all my controllers right now to s

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-12 Thread Bruce Wade
les.Ads].id == 5).select().first() # Things like this will be moved into adviewer_api at some point This works by only creating the tables that I define per action. Do you for see any problems using this method? On Sat, May 12, 2012 at 9:06 AM, Bruce Wade wrote: > Yeah I am going through all my

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-12 Thread Bruce Wade
Yeah I am going through all my controllers right now to see if I can use the folder solution. Which way would be faster? Folders or modules? On Sat, May 12, 2012 at 8:52 AM, Anthony wrote: > On Saturday, May 12, 2012 10:51:59 AM UTC-4, Bruce Wade wrote: >> >> I am starting to t

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-12 Thread Bruce Wade
you should get many postgres processes IDLE IN TRANSACTION. It is a > > symptom of web2py taking long to commit the transaction. > > If you do not use the db in some complex view you can try to put a > > db.rollback() at the beginning of the controller. > > Are you using

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-11 Thread Bruce Wade
for represent or other use? > > Recently I solve speed problem I had by caching dict building query. > > I never thought that building a dictionary could be that expensive in term > of cpu load. > > Richard > > > On Thu, May 10, 2012 at 5:13 PM, Bruce Wade wrote: &

Re: [web2py] Looking for web2py help - is there a group for recruiting?

2012-05-10 Thread Bruce Wade
into > and efficiency of each solar plant. > > > > -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers Online http://www.warplydesigned.com

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-10 Thread Bruce Wade
suffice. As a rule of thumb you should not have > the number of web2py processes be more than twice the number of cores. > > mic > > > 2012/5/10 Bruce Wade : > > Web2py is on 3 different servers/nodes, postgresql is on it's own node > with > > 8GB ram. > > &

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
>>> last_row = None >>> next_page_number = 0 >>> >>> Go in a for loop that just assign the db query result one-by-one to row >>> variable. >>> >>> After that I assign the TABLE() helper to a list variable. That is it. >>> >&

Re: [web2py] Re: Nginx-uwsgi problem.

2012-05-10 Thread Bruce Wade
breit wrote: > Is your traffic from serving ads or users coming to your web site? Have > you exhausted caching opportunities? -- -- Regards, Bruce Wade http://ca.linkedin.com/in/brucelwade http://www.wadecybertech.com http://www.fittraineronline.com - Fitness Personal Trainers

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
select * from file_properties where id > 0"): >> >> # do something >> >> >> Does it have a lower memory usage? >> >> >> On Thu, May 10, 2012 at 4:14 AM, Bruce Wade < >wrote: >> >>> for row in db( db.file_**properties.id > 0

[web2py] Re: Nginx-uwsgi problem.

2012-05-10 Thread Bruce Wade
Hi, Have you ever fixed this problem? I am finding it very very hard to handle high load websites, also using postgres. I think the bottle neck is the DB layer as even using the admin tool causes timeout issues. Last night I had 2.3k concurrent users for 5 hours which caused one of the servers

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
emory instead of 1 instance per record in the database. If you make it load only a single instance your problem will go away. I am pretty sure this might be covered in the web2py book. On Thu, May 10, 2012 at 6:14 AM, Bruce Wade wrote: > Their is no grantee that python will use that exact same me

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
not right. > > 2012. május 10., csütörtök 9:41:31 UTC+2 időpontban Bruce Wade a > következőt írta: > >> http://effbot.org/pyfaq/why-**doesnt-python-release-the-** >> memory-when-i-delete-a-large-**object.htm<http://effbot.org/pyfaq/why-doesnt-python-release-the-memory-

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
pe the mem usage is linearly growing >>> and after the successful execution never released and that is why I ask :( >>> >>> 2012. május 10., csütörtök 9:14:14 UTC+2 időpontban Bruce Wade a >>> következőt írta: >>> >>>> WOW not a good idea: >

Re: [web2py] Need a little help in code review (a function eating up all memory)

2012-05-10 Thread Bruce Wade
d that is why I ask :( > > 2012. május 10., csütörtök 9:14:14 UTC+2 időpontban Bruce Wade a > következőt írta: > >> WOW not a good idea: >> for row in db( db.file_**properties.id > 0 ).select( >> >> If you have a lot of records that is going to kill your m

  1   2   3   4   5   >