Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread Patryk Zawadzki
2007/12/3, Malcolm Tredinnick <[EMAIL PROTECTED]>: > On Mon, 2007-12-03 at 13:09 -0800, David Cramer wrote: > > For the most part I'm just doing if request.POST to validate. > > This isn't completely sufficient because it's possible to submit a form > via POST with no data (e.g. a form with checkb

Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread Malcolm Tredinnick
On Mon, 2007-12-03 at 13:09 -0800, David Cramer wrote: > For the most part I'm just doing if request.POST to validate. This isn't completely sufficient because it's possible to submit a form via POST with no data (e.g. a form with checkboxes and maybe some fields that aren't filled in). That's w

Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread James Bennett
On 12/3/07, David Cramer <[EMAIL PROTECTED]> wrote: > For the most part I'm just doing if request.POST to validate. The request.method attribute exists precisely for this purpose, so that you can find out what the HTTP request method was ;) -- "Bureaucrat Conrad, you are technically correct --

Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread David Cramer
For the most part I'm just doing if request.POST to validate. On Dec 3, 11:16 am, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Mon, 2007-12-03 at 11:00 -0800, David Cramer wrote: > > Just my 2 cents... > > > If you drop request.POST, request.GET, and replace them all with > > request.DATA -

Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread Malcolm Tredinnick
On Mon, 2007-12-03 at 11:00 -0800, David Cramer wrote: > Just my 2 cents... > > If you drop request.POST, request.GET, and replace them all with > request.DATA -- we're going to again be branching away from Django > trunk. > > For our uses -- POST and GET are completely different things -- > wh

Re: Changes to request_response have broken django-rest-interface

2007-12-03 Thread David Cramer
Just my 2 cents... If you drop request.POST, request.GET, and replace them all with request.DATA -- we're going to again be branching away from Django trunk. For our uses -- POST and GET are completely different things -- whether you use one at a time or not is unrelated. Things should be differ

Re: Changes to request_response have broken django-rest-interface

2007-10-18 Thread David Larlet
2007/10/18, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > On Tue, 2007-10-16 at 21:52 +0200, David Larlet wrote: > > 2007/10/10, David Larlet <[EMAIL PROTECTED]>: > > > > > > BTW, no more thought about the way of handling PUT? I've just added a > > > patch against test.client which add .put() and .d

Re: Changes to request_response have broken django-rest-interface

2007-10-17 Thread Jacob Kaplan-Moss
On 10/17/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > However, neither decision is binding until at least one other core > maintainer steps in with some agreement [...] Here's my 2ยข: use ``request.DATA``, and keep ``request.POST`` around forever. I quite like the way ``request.GET`` and ``

Re: Changes to request_response have broken django-rest-interface

2007-10-17 Thread Malcolm Tredinnick
On Tue, 2007-10-16 at 21:52 +0200, David Larlet wrote: > 2007/10/10, David Larlet <[EMAIL PROTECTED]>: > > > > BTW, no more thought about the way of handling PUT? I've just added a > > patch against test.client which add .put() and .delete(), I'm waiting > > for (a) reaction(s) to add tests and do

Re: Changes to request_response have broken django-rest-interface

2007-10-16 Thread David Larlet
2007/10/10, David Larlet <[EMAIL PROTECTED]>: > > BTW, no more thought about the way of handling PUT? I've just added a > patch against test.client which add .put() and .delete(), I'm waiting > for (a) reaction(s) to add tests and documentation. > Sorry for insisting on that point but this is imp

Re: Changes to request_response have broken django-rest-interface

2007-10-10 Thread David Larlet
2007/10/8, Peter Nixon <[EMAIL PROTECTED]>: > > Hi David > > Thanks for doing this. I have written a patch for mod_python and added it to > the ticket. I have tested it and deployed it with a patched rest api in > production ;-) > Ok, can you add your patch against django.http.__init__.py too, you

Re: django-rest-api use [was Re: Changes to request_response have broken django-rest-interface]

2007-10-09 Thread David Larlet
2007/10/7, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > The Resource class is quite as independent from everything as we would > have liked. I say "we" here because towards the end of the SoC period, > Andreas and I spent quite a long time trying to loosen a few of the > couplings between output cl

Re: Changes to request_response have broken django-rest-interface

2007-10-08 Thread Peter Nixon
On Sat 06 Oct 2007, David Larlet wrote: > 2007/10/5, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > On Fri, 2007-10-05 at 16:17 +0300, Peter Nixon wrote: > > > On Thu 04 Oct 2007, Malcolm Tredinnick wrote: > > > > On Thu, 2007-10-04 at 18:10 +0300, Peter Nixon wrote: > > > > > I tried to open the fol

Re: Changes to request_response have broken django-rest-interface

2007-10-08 Thread David Larlet
2007/10/7, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > On Sun, 2007-10-07 at 02:39 +0200, David Larlet wrote: > > The > > option (3) seems more natural to me to make the difference between > > what you post and the POST verb, it's more explicit. What about > > self.PUT in this scenario? > > That'

django-rest-api use [was Re: Changes to request_response have broken django-rest-interface]

2007-10-07 Thread Malcolm Tredinnick
On Sun, 2007-10-07 at 20:02 +0400, Ivan Sagalaev wrote: > Malcolm Tredinnick wrote: > > As soon as > > you start to move to situations where your publically exposed resources > > don't map more or less one-to-one onto models, things become a lot > > trickier and we haven't quite solved that > > W

Re: Changes to request_response have broken django-rest-interface

2007-10-07 Thread Ivan Sagalaev
Malcolm Tredinnick wrote: > As soon as > you start to move to situations where your publically exposed resources > don't map more or less one-to-one onto models, things become a lot > trickier and we haven't quite solved that Weren't custom descendants of the Resource class designed for this? I

Re: Changes to request_response have broken django-rest-interface

2007-10-07 Thread Malcolm Tredinnick
On Sun, 2007-10-07 at 11:16 -0400, Malcolm Tredinnick wrote: [...] > There are a lot of cases that Andreas' work doesn't cover, since REST is > a very broadly applicable theory. That was one of the challenges of the > project: working out what areas needed help and where we would just be > adding

Re: Changes to request_response have broken django-rest-interface

2007-10-07 Thread Malcolm Tredinnick
On Sun, 2007-10-07 at 02:39 +0200, David Larlet wrote: > 2007/10/6, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > > > I had a quick read of it. Looks like you're on the right track. > > Thanks for your reactivity. > > > > > The main problem I see with it is that you're over-populating the data > >

Re: Changes to request_response have broken django-rest-interface

2007-10-06 Thread Kenneth Gonsalves
On 05-Oct-07, at 1:23 PM, Peter Nixon wrote: >> On 10/4/07, Peter Nixon <[EMAIL PROTECTED]> wrote: >>> I tried to open the following ticket but it thinks my IP is a >>> spammer, >>> so I am sending to the list: >> >> If you create an account in Trac, it won't apply spam filtering to >> you.

Re: Changes to request_response have broken django-rest-interface

2007-10-06 Thread David Larlet
2007/10/6, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > I had a quick read of it. Looks like you're on the right track. Thanks for your reactivity. > > The main problem I see with it is that you're over-populating the data > structures a bit. If the request is a PUT, you're still populating > sel

Re: Changes to request_response have broken django-rest-interface

2007-10-06 Thread Malcolm Tredinnick
On Sat, 2007-10-06 at 18:49 +0200, David Larlet wrote: [..] > I use django-rest-interface too and I have this bug which need to be > quickly fixed so I submitted a patch which need review on #5682, let > me know if I need to do something else. I will add a patch for > modpython too when this one

Re: Changes to request_response have broken django-rest-interface

2007-10-06 Thread David Larlet
2007/10/5, Malcolm Tredinnick <[EMAIL PROTECTED]>: > > On Fri, 2007-10-05 at 16:17 +0300, Peter Nixon wrote: > > On Thu 04 Oct 2007, Malcolm Tredinnick wrote: > > > On Thu, 2007-10-04 at 18:10 +0300, Peter Nixon wrote: > > > > I tried to open the following ticket but it thinks my IP is a spammer,

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Malcolm Tredinnick
On Fri, 2007-10-05 at 16:17 +0300, Peter Nixon wrote: > On Thu 04 Oct 2007, Malcolm Tredinnick wrote: > > On Thu, 2007-10-04 at 18:10 +0300, Peter Nixon wrote: > > > I tried to open the following ticket but it thinks my IP is a spammer, > > > so I am sending to the list: > > > > > > http://django-

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Peter Nixon
On Thu 04 Oct 2007, Malcolm Tredinnick wrote: > On Thu, 2007-10-04 at 18:10 +0300, Peter Nixon wrote: > > I tried to open the following ticket but it thinks my IP is a spammer, > > so I am sending to the list: > > > > http://django-rest-interface.googlecode.com/svn/trunk/django_restapi/res > >ourc

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Jacob Kaplan-Moss
On 10/5/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > Thanks. I have signed up now, but I still cannot for the life of me find a > link to that page from anywhere. Shouldn't it be a little more prominent? Yeah, it should; I'll add a couple of links when I get a moment. Jacob --~--~-~--~-

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Peter Nixon
On Fri 05 Oct 2007, Tomas Kopecek wrote: > Peter Nixon napsal(a): > > On Thu 04 Oct 2007, James Bennett wrote: > >> On 10/4/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > >>> I tried to open the following ticket but it thinks my IP is a spammer, > >>> so I am sending to the list: > >> > >> If you cr

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Tomas Kopecek
Peter Nixon napsal(a): > On Thu 04 Oct 2007, James Bennett wrote: >> On 10/4/07, Peter Nixon <[EMAIL PROTECTED]> wrote: >>> I tried to open the following ticket but it thinks my IP is a spammer, >>> so I am sending to the list: >> If you create an account in Trac, it won't apply spam filtering to

Re: Changes to request_response have broken django-rest-interface

2007-10-05 Thread Peter Nixon
On Thu 04 Oct 2007, James Bennett wrote: > On 10/4/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > > I tried to open the following ticket but it thinks my IP is a spammer, > > so I am sending to the list: > > If you create an account in Trac, it won't apply spam filtering to you. And how does one go

Re: Changes to request_response have broken django-rest-interface

2007-10-04 Thread James Bennett
On 10/4/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > I tried to open the following ticket but it thinks my IP is a spammer, so I > am sending to the list: If you create an account in Trac, it won't apply spam filtering to you. -- "Bureaucrat Conrad, you are technically correct -- the best kind

Re: Changes to request_response have broken django-rest-interface

2007-10-04 Thread Malcolm Tredinnick
On Thu, 2007-10-04 at 18:10 +0300, Peter Nixon wrote: > I tried to open the following ticket but it thinks my IP is a spammer, so I > am sending to the list: > > http://django-rest-interface.googlecode.com/svn/trunk/django_restapi/resource.py > > tries to set "request.method = 'POST'" in order

Changes to request_response have broken django-rest-interface

2007-10-04 Thread Peter Nixon
I tried to open the following ticket but it thinks my IP is a spammer, so I am sending to the list: http://django-rest-interface.googlecode.com/svn/trunk/django_restapi/resource.py tries to set "request.method = 'POST'" in order to run PUTs through request._load_post_and_files() as POSTs as _