Re: Apache mod_python config problem

2007-11-18 Thread Nimrod A. Abing
ng slash, apparently some versions of Apache (1.3) ship with a broken mod_dir that causes strange (and sometimes correct) behavior when a trailing slash is appended to DocumentRoot. See: http://httpd.apache.org/docs/1.3/mod/core.html#documentroot -- Best Regards, Nimrod A. Abing W http://arsenic.

Re: Apache mod_python config problem

2007-11-16 Thread Nimrod A. Abing
aversing up the directory structure until you get the correct permissions. HTH. -- Best Regards, Nimrod A. Abing W http://arsenic.ph/ W http://preownedcar.com/ W http://abing.gotdns.com/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to t

Command line app using Django is always "Idle in Transaction"

2007-11-09 Thread Nimrod A. Abing
saction lock. But I'm thinking it will eventually cause serious problems later on so it's better if it would not idle inside a transaction. BTW. I tried settings.DISABLE_TRANSACTION_MANAGEMENT = True and inserted it somewhere before run() is called. Still I get "idle in transaction". -

Re: spam

2007-11-06 Thread Nimrod A. Abing
Google's in-built spam filter button is that it tags entire "conversations" and does not seem to allow you to tag individual messages. So if a Groups subscriber replies to a spam message his email (and email address) gets included in my spam filter training data. -- Best Rega

Re: django and postgres

2007-09-27 Thread Nimrod A. Abing
It's a bad idea to use the 'postgres' user account since this account is the Postgresql *superuser* account. Which means, with this account it is possible to do some serious damage to the system catalogs. You should create a separate Postgres user account and create a database for it. First

Using a Single Sign-on Server with Django

2007-09-24 Thread Nimrod A. Abing
Hello, Does anyone know of a single sign-on server that can be used with Django? Similar to the approach taken by Cosign or Pubcookie but without the fluff that is LDAP and Kerberos. Just a simple database of users and passwords to authenticate

Re: How to automatically apply a method to all fields in newforms subclass?

2007-09-17 Thread Nimrod A. Abing
Just revisiting this thread... On 9/14/07, Doug B <[EMAIL PROTECTED]> wrote: > > I think you can make a custom form field to do your validation check > for you. > > def StrippedField(forms.CharField): > def clean(self,value): > #do your validation here While the solution above would

How to automatically apply a method to all fields in newforms subclass?

2007-09-13 Thread Nimrod A. Abing
Hello, I have several forms that I subclass from a subclass of newforms: # newforms is aliased as forms class StrippedFieldsForm(forms.Form) def strip_field(self, field, error_message): if (self.clean_data.get(field)): data = self.clean_data[field].strip() if

Re: More than one Django version installed - possible?

2007-08-22 Thread Nimrod A. Abing
I used to do this a while back. Off the top of my head what I did was unpack 0.96 and the svn versions in separate directories. Then using the PYTHONPATH environment variable you should be able to specify which version you want to use. For example: 0.96 is in... ~/Python/libs/django-0.96/django

Re: automatic form submission

2007-08-08 Thread Nimrod A. Abing
On 8/8/07, cesco <[EMAIL PROTECTED]> wrote: > > Hi, > > I need to retrieve automatically some information from an e-commerce > site. > The site doesn't offer any API, so the only way to perform the search > is via the form they provide. The form is submitted via a POST method > and the URL

Re: Templates escaping ampersand

2007-08-07 Thread Nimrod A. Abing
On 8/8/07, Kynatro <[EMAIL PROTECTED]> wrote: > > I'm fairly new to dJango and I'm having a problem with the templating > system. I'm replacing a block in my base template and trying to pass > over apostrophe characters as their entity codes (), but the > template system is converting the

Re: MySQL and InnoDB

2007-08-07 Thread Nimrod A. Abing
On 8/8/07, Rob Hudson <[EMAIL PROTECTED]> wrote: > > On Aug 6, 4:16 am, Matti Haavikko <[EMAIL PROTECTED]> wrote: > > Hi, > > > > Can you get the same result with "default-storage-engine=InnoDB" in your > > my.cnf? > > > > - Haavikko > > I believe you can but for other various reasons I'm not

Re: [OT] pydev

2007-08-05 Thread Nimrod A. Abing
On 8/6/07, Derek Anderson <[EMAIL PROTECTED]> wrote: > > i was using the ubuntu packages for eclipse and pydev...(why are they so > far behind?) That's because they take whatever is the latest version of software available at a particular point in time during the 6 month development cycle.

Model Examples page, gone?

2007-08-02 Thread Nimrod A. Abing
Hello, I was just going through the current docs and wanted to look up some examples and I noticed that the Model Examples page is gone: http://www.djangoproject.com/documentation/models/ though it can still be accessed in the older versions of the docs.

Re: pydev

2007-08-02 Thread Nimrod A. Abing
On 8/2/07, eXt <[EMAIL PROTECTED]> wrote: > > Hi > >As I said earlier i don't have (and don't remember) these settings. > But you're right - it was in eclipse.ini. Now I use Eclipse Europa and > Java 6 on Kubuntu (32 bit) and I don't have any errors (even null > references mentioned by

Re: [OT] pydev

2007-07-31 Thread Nimrod A. Abing
Hello, What OS and JRE/JDK are you using? I'm on Linux with Eclipse Europa running on JDK1.6.0_02. I have never experienced any hangs. I run 32-bit Linux on my laptop and 64-bit Linux on the desktop. On both systems there comes an exception from time to time complaining about null references and

Re: Using LimitRequestBody to Limit File Uploads

2007-07-29 Thread Nimrod A. Abing
On 7/30/07, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > The documentation says: > > """Similarly, an 'apache' subdirectory should have been created within > the package and the script file stored there under the name > 'django.wsgi'.""" > > Rather than trying to launch straight into setting up

Re: Using LimitRequestBody to Limit File Uploads

2007-07-29 Thread Nimrod A. Abing
On 7/29/07, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > > I would love to try that on my development server but I can't seem to > > find documentation on how to do it: > > > > http://code.djangoproject.com/wiki/ServerArrangements > > > > Can someone point me in the right direction? > >

Re: Using LimitRequestBody to Limit File Uploads

2007-07-29 Thread Nimrod A. Abing
On 7/29/07, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > We hadn't been able to come up with a way of reproducing the problem > on demand so hadn't yet been able to investigate. Where people had > seen this exception it was very rare and very random. I think the following conditions trigger the

Using LimitRequestBody to Limit File Uploads

2007-07-28 Thread Nimrod A. Abing
Hello, I have recently begun testing LimitRequestBody to limit file uploads. It works but there are some issues. Whenever the uploaded file hits the limit, I get "Connection reset by peer". Ideally I would like to be able to redirect the user to an error page but it seems that Django tries to

Re: transaction commit

2007-07-25 Thread Nimrod A. Abing
On 7/25/07, Andrey Khavryuchenko <[EMAIL PROTECTED]> wrote: > > Nimrod, > > NAA> On 7/25/07, Andrey Khavryuchenko <[EMAIL PROTECTED]> wrote: > >> >> Yes, I read carefuly your question and thought the answer was > >> >> straighforward. I don't understand why you don't want decorators, > but

Re: transaction commit

2007-07-25 Thread Nimrod A. Abing
Hello Andrey, > NAA> On 7/25/07, Andrey Khavryuchenko <[EMAIL PROTECTED]> wrote: > >> Yes, I read carefuly your question and thought the answer was > >> straighforward. I don't understand why you don't want decorators, but > you > >> could just check the decorator definition to read what

Re: transaction commit

2007-07-24 Thread Nimrod A. Abing
Hello everyone, On 7/25/07, Andrey Khavryuchenko <[EMAIL PROTECTED]> wrote: > Yes, I read carefuly your question and thought the answer was > straighforward. I don't understand why you don't want decorators, but you > could just check the decorator definition to read what it does and copy >

Re: How to use request.GET??

2007-07-18 Thread Nimrod A. Abing
On 7/19/07, SmileyChris <[EMAIL PROTECTED]> wrote: > > On Jul 19, 2:22 pm, Greg <[EMAIL PROTECTED]> wrote: > > I was wondering how do I send a 'favorite_color' GET parameter? Do I > > have to use a form to do this that sends data by GET or is there > > another way to do it? > >

Re: Spawning Subprocesses under mod_python

2007-07-16 Thread Nimrod A. Abing
On 7/17/07, Giovanni Giorgi <[EMAIL PROTECTED]> wrote: > > I have used the subprocess module with success. > I have used it only on command line based script under Linux, but I > think it can work inside mod_python. > If you plan to use it I suggest you to reboot the apache one a day, to >

Spawning Subprocesses under mod_python

2007-07-16 Thread Nimrod A. Abing
Hello, I'm just wondering if anyone has any experiences spawning subprocesses under mod_python on Linux/Unix. My specific use case is something in the line of an os.system() call with the exception that I will be using its replacement using Popen() as detailed here:

Re: Question about AddManipulator/ChangeManipulator

2007-07-10 Thread Nimrod A. Abing
On 7/11/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > On Tue, 2007-07-10 at 02:40 +0800, Nimrod A. Abing wrote: > > Hello, > > > > I am currently in the process of porting one of my oldforms-based app > > to use newforms. I have some blocks

Web Framework Shootout

2007-07-10 Thread Nimrod A. Abing
I was looking around the Net for an objective comparison between the different frameworks (actually looking for objective comparison between Django and RoR) available out there. I found this one and I thought it would be good to share:

Re: Question about AddManipulator/ChangeManipulator

2007-07-09 Thread Nimrod A. Abing
ed before 1.0). Just as > importantly, newforms are a vast improvement over the manipulator > framework and so even for the short term you will probably see payoff > for your efforts. > I say "upgradde" for a double dose of formness. > > -rob > > On Jul 9, 11:40 a

Re: ubuntu 6.06 deployment issues

2007-07-05 Thread Nimrod A. Abing
Hello, Your problem could be that the permissions to /home/john-scott do not allow directory traversal down into this directory for "other" users. You probably need to do: $ chmod 0755 /home/john-scott $ chmod 0755 /home/john-scott/workspace $ cd /home/john-scott/workspace $ find -type d |

Re: Password Logistics Help Needed

2007-06-27 Thread Nimrod A. Abing
On 6/27/07, Bryan Veloso <[EMAIL PROTECTED]> wrote: > At the moment, the game can only read md5 or plain-text passwords, and > I know that Django has the hash$salt$hash (or something. :P) way of > doing it. So I can't just copy the password from the User model to the > account table since the

Re: all on one server release, ballpark?

2007-06-26 Thread Nimrod A. Abing
On 6/26/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > I don't want to sound discouraging, but if the answer is at all critical > to your operation, you can't trust any numbers you get here. They will > not have the same usage patterns as yours. Benchmark, benchmark, > benchmark is the only

Re: Ticket #3297 & Newforms Image Uploading

2007-06-22 Thread Nimrod A. Abing
On 6/23/07, Bryan Veloso <[EMAIL PROTECTED]> wrote: > > > Can't paste the code from the actual app (am under NDA) but the logic > > in saving the image from form data is here: > > > > http://dpaste.com/12731/ > > The only problem with this, and probably why I'm looking to use #3297 > (which

Re: Ticket #3297 & Newforms Image Uploading

2007-06-22 Thread Nimrod A. Abing
On 6/22/07, Dirk van Oosterbosch, IR labs <[EMAIL PROTECTED]> wrote: > This is what I did for the field validation http://dpaste.com/12715/ > > the code to save the field data is in the view that uses this form. > Nice! Would you maybe be willing to share your view code too? Can't paste the code

Re: Development / Production Setup

2007-06-21 Thread Nimrod A. Abing
See: http://dpaste.com/12716/ What you can do is setup a conditional like that in your settings.py where settings will be loaded based on your current hostname. This is what I have been doing for quite some time now and seems to work well. For templates, you have to set URL_PREFIX,

Re: Ticket #3297 & Newforms Image Uploading

2007-06-21 Thread Nimrod A. Abing
On 6/22/07, Bryan Veloso <[EMAIL PROTECTED]> wrote: > > RE: http://code.djangoproject.com/ticket/3297 > > I'm wondering if anybody has actually used this patch for a production > site. If not, then I'll put off a certain feature of my site until > later. The patch is really tempting though, so I

Re: Hypothetical: Customizable Member Pages

2007-06-20 Thread Nimrod A. Abing
Hello, Django does not support this out of the box. If you plan to use the built-in auth module, you can extend it by creating Profile and UserStyle model which would presumably store details about the user's profile (fields not already in the default User model) and user's custom style. Can't

Re: Captcha module Version 1.1 ready for testing

2007-06-15 Thread Nimrod A. Abing
On 6/15/07, Martin Winkler <[EMAIL PROTECTED]> wrote: > > Am Thu, 14 Jun 2007 12:00:11 +0800 > schrieb "Nimrod A. Abing" <[EMAIL PROTECTED]>: > > > Are you planning to implement a configuration to allow in-memory > > images? > > One thing t

Re: App.objects.get(user='John') error

2007-06-14 Thread Nimrod A. Abing
On 6/15/07, Vincent Nijs <[EMAIL PROTECTED]> wrote: > > Hi, > > I have the following model > > class App(models.Model): > user = models.ForeignKey(User, unique=True, editable=False) > > In a view I now want to check if a user is indeed in the database table. I > tried the following >

Re: Captcha module ready for testing

2007-06-13 Thread Nimrod A. Abing
Hello, I am about to try your module and I haven't downloaded it yet but I have a few questions and some suggestions. I have my own CAPTCHA module too which is slightly different from yours in some respects: 1. It does not need a dedicated directory to save image files. Images are created

Re: Handling Very Large File Uploads and Cookie-less Visitors

2007-06-13 Thread Nimrod A. Abing
as middleware. Has someone else worked on this already? If not, it will make for a good first stab for me at writing middleware. On 6/13/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > On Wed, 2007-06-13 at 13:53 +0800, Nimrod A. Abing wrote: > > Hello, > > > > Regard

Handling Very Large File Uploads and Cookie-less Visitors

2007-06-12 Thread Nimrod A. Abing
Hello, Regarding very large file uploads, I know this probably gets asked a lot and I've found one thread that comes close to what the answer I'm looking for: http://groups.google.com/group/django-users/browse_thread/thread/ca95963aaa33ce1e/c69fb3381885f9a7 This thread was posted about a year

Re: Including [django-users] in subject line?

2007-06-10 Thread Nimrod A. Abing
Hello, Prior to switching to GMail exclusively, I used to use Outlook or Outlook Express. I had the same problem that you have now, so I understand where you're coming from. I used to use a modified spambayes filter that would modify the Subject field and add a prefix to it (e.g., SPAM,

Re: passing foreign key via post

2007-06-09 Thread Nimrod A. Abing
On 6/10/07, Car <[EMAIL PROTECTED]> wrote: > > > > Why not create it there? That is the moment you have all the data you > > need and all you're doing is calling a constructor. The code you've > > written there is a pretty normal pattern for taking form information and > > putting it into a

Re: Scalability where file uploads are involved

2007-06-08 Thread Nimrod A. Abing
On 6/9/07, ZebZiggle <[EMAIL PROTECTED]> wrote: > > If your focus is on images, I can't recommend this utility strong > enough: > > http://www.aurigma.com/ Bookmarked :) Although we only allow as many as four images per upload session, I have to entertain the possiblity that my employer will

Re: Scalability where file uploads are involved

2007-06-08 Thread Nimrod A. Abing
On 6/9/07, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote: > > On 6/7/07, Nimrod A. Abing <[EMAIL PROTECTED]> wrote: > > The only thing I can think of right now is to share a directory on the > > dedicated media server and have each server in the Django cluster >

Re: Scalability where file uploads are involved

2007-06-07 Thread Nimrod A. Abing
Thanks for this suggestion. Although there would be a slight delay while the media server syncs up with the Django servers I think this solution is more feasible. On 6/8/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > On Fri, 2007-06-08 at 00:38 +0800, Nimrod A. Abing wrote:

Scalability where file uploads are involved

2007-06-07 Thread Nimrod A. Abing
Hello, I am currently doing research on scaling one of the sites I made using Django. I have looked at Chapter 21 of the in-progress Django Book. I plan to follow the track recommending 3 django servers behind perlbal + 1 dedicated media server + 1 dedicated database server. The current setup

Re: Flatpages not working on Apache+mod_python

2007-05-16 Thread Nimrod A. Abing
On 5/17/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > > On 5/16/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > > Already done, though under-documented. > > http://www.djangoproject.com/documentation/templates/#django-contrib-markup > > Ah, here, too: >

Re: Flatpages not working on Apache+mod_python

2007-05-16 Thread Nimrod A. Abing
On 5/17/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > > On 5/16/07, Nimrod A. Abing <[EMAIL PROTECTED]> wrote: > > Can anyone here provide pointers on how to get flatpages to work > > properly under Apache and mod_python? > > From yo

Flatpages not working on Apache+mod_python

2007-05-16 Thread Nimrod A. Abing
Hello, I am using Django 0.96 and I am currently having problems getting flatpages middleware to work under Apache with mod_python. I am pretty sure this is mod_python related since flatpages work fine using the development server. I have found at least one thread the mentions this problem,