Re: Forking a background process on request

2010-11-05 Thread Elver Loho
Celery is exactly what I'm looking for! Thanks! :) On 4 November 2010 13:41, Brian Bouterse <bmbou...@gmail.com> wrote: > I would look into django-celery to do asynchronous tasks.  It can also be > executed as a webhooks style, see here. > > Brian > On Thu, Nov 4, 2010 a

Forking a background process on request

2010-11-04 Thread Elver Loho
Hi, I am working on a web app that creates reports that may take up to a minute to generate. (Or longer under heavy loads.) Ideally I would like something like this to happen: 1. User presses a button on the website. Javascript sends a begin- report-creation message to the server. 2. Report

Re: when is 1 != 1? (according to 'ifequal' in template)

2006-08-07 Thread Elver Loho
On 8/7/06, hotani <[EMAIL PROTECTED]> wrote: > > I'm doing a comparison of a session variable and an id for a 'selected' > tag in a drop-down in a template. If I output both vars, they will both > be "1" yet 'ifequal' is still returning false. Has water stopped being > wet? While water might be

Re: Django vs TurboGears

2006-07-29 Thread Elver Loho
On 7/29/06, Javier Nievas <[EMAIL PROTECTED]> wrote: > > Django does not use MVC model, it uses Model - View - Template (MVT) > model. It's similar, because an MVC view is like an MVT template, and > an MVC controller is like a MVT view.

Re: Django vs TurboGears

2006-07-29 Thread Elver Loho
On 7/29/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > I'm evaluating the possibility to use Django for a project, but I have > read so many comments about Django vs TurboGears and right now I am > very confused. > I installed both of them in my system and sincerelly I found that > Django is

Re: Is Django the framework I've been looking for?

2006-07-20 Thread Elver Loho
On 7/21/06, Sean Schertell <[EMAIL PROTECTED]> wrote: > > Thanks for presenting a different angle. I imagine you're one of > these long-bearded guys who uses NetBSD and Fluxbox as his main > desktop OS and edits code in VI through a tsch shell ;-) Ubuntu Dapper and Gnome. (I need Unix on

Re: Is Django the framework I've been looking for?

2006-07-20 Thread Elver Loho
Allow me to offer a dissenting view. I recently faced the task of finding a Python-based framework to use at work and tried several, including Django. I finally settled on using CherryPy with Kid. (Which is what TurboGears is doing, but with a lot of extra cruft thrown in. And btw, the TurboGears

Re: Weird behaviour

2006-06-07 Thread Elver Loho
On 6/8/06, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > On Thu, 2006-06-08 at 02:21 +0300, Elver Loho wrote: > > On 6/8/06, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > > > > > On 6/7/06, Elver Loho <[EMAIL PROTECTED]> wrote: > > &

Re: Weird behaviour

2006-06-07 Thread Elver Loho
On 6/8/06, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > On 6/7/06, Elver Loho <[EMAIL PROTECTED]> wrote: > > This behaviour is just way too weird. I'm currently developing with > > Django for work and with CherryPy for a side project and CherryPy > > doesn'

Weird behaviour

2006-06-07 Thread Elver Loho
request.session seems to be storing things beyond me closing the Django development server. This is sort of weird. Is it a feature or a bug? Because, I'd prefer a clean slate every time I run the devserver. Example code: def foo(request): foo = request.session.get("foo", None)

Re: I think I'm doing something wrong...

2006-06-06 Thread Elver Loho
Darn, well, that fixed it :P And to think I had the same problem with TurboGears a while bak. Sheesh. Thanks, everyone! :) Elver On 6/7/06, Max Battcher <[EMAIL PROTECTED]> wrote: > > Elver Loho wrote: > > > > Sadly it seems you, along with so many,

Unhappy, reinventing

2006-05-24 Thread Elver Loho
I used to code stuff with TurboGears, which started sucking rather fast. I still liked their templating engine, Kid. Sort of. I've also tried Zope 3's and Django's, a couple of homegrown ones, Interchange's as used on our big webstore and a bunch of others. As far as I'm concerned, they all have

Function caching

2006-05-23 Thread Elver Loho
Can Django's caching framework somehow be used to cache the output of any function? What I have right now is basically a standard Django project where I've swapped out the templating engine and replaced it with Kid and where I'm not using the supplied O-R mapper, but where I've written my own DB

Re: Transactions and model.save()

2006-05-16 Thread Elver Loho
On 5/17/06, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > On 5/16/06, Elver Loho <[EMAIL PROTECTED]> wrote: > > Let's take the poll sample. We've got the vote() view going on. > > > > choice.votes += 1 > > choice.save() > > > > Suppose we'

i18n

2006-05-16 Thread Elver Loho
Is there a way to chain languages in the i18n interface? We're using a custom Interchange tag right now to do i18n in our webstore. We support Estonian, Latvian, Lithuanian, Russian, and English. The language chaining goes something like this: if locale is estonian: print i18n(message,

Transactions and model.save()

2006-05-16 Thread Elver Loho
Hiya! Someone raised this question in the comments of the 4th tutorial and it's been bugging me to no end. Let's take the poll sample. We've got the vote() view going on. choice.votes += 1 choice.save() Suppose we've got thread1 and thread2 going on (high-load website): choice.votes is