Re: VERY cheap django hosting?

2011-06-09 Thread Matteius
I've been really happy with Valcato Hosting which has all that shell hosting shared goodness and a fast turn around on trouble tickets at excellent pricing: https://secure.valcato.com/aff.php?aff=070 -Matteius -- You received this message because you are subscribed to the Google Groups

How to add CSRF to context when using test client???

2011-06-09 Thread Matteius
Greetings, I am writing unit tests for my application, and I want to leave CSRF checks enabled in testing. This means on my POST I am getting 403 because I have not figured out how to add csrf to my context when using the test client. Please advise on how to most easily do this: #

Help with custom model method for query

2011-06-09 Thread Chris McComas
I have this views.py and models.py: http://dpaste.com/552615/ On the view what I want to do is display a list of all the feed types (News, Sports, etc general categories), then then below each of those feed type headings display the FeedItems for each feed for that city. Prior to adding the

Re: VERY cheap django hosting?

2011-06-09 Thread AJ
> > I put all my projects on Google AppEngine ... > works pretty well with > django-nonrel > although sometimes there are some fairly signifi I was wondering if you can have multiple instances of an app and

Re: VERY cheap django hosting?

2011-06-09 Thread raj
Can you please elaborate on the second part of your statement? What do you mean by specifying what python you use? I've also been trained in using python 2.7, will I notice a difference if I use 2.4? Thank you. -Raj On Jun 9, 3:32 pm, elliot wrote: > more specific: >

Re: Passing extra context data to class-based generic views?

2011-06-09 Thread Greg
I've created a reusable view which allows for an extra_context argument, see https://github.com/gregplaysguitar/django-baseclasses/blob/master/baseclasses/views.py +1 on this functionality being added to django itself though. -- You received this message because you are subscribed to the

Re: Django and Rich Client

2011-06-09 Thread Ovnicraft
soaplib On Thu, Jun 9, 2011 at 1:10 PM, Knack wrote: > Hi guys, > > I've got a prototype DB + Rich Client app and need to make a proper > production app out of it. The client is written in PyQt and needs to > fullfill quite some functional

RE: Django and Rich Client

2011-06-09 Thread Sells, Fred
FWIW I use flex for the rich client and get xml out of django which flex handles nicely. I use Ldap for Authorization (had to use legacy junk for authentication to be compliant) and I have a cron job that loads the ldap groups I need and there members into my db. Solves speed and reliability

Re: Authentication in API (REST)

2011-06-09 Thread Yohanes Adhi Nugraha
Hi Malcolm, Not that one, if we use django.contrib.auth and @login_required, it's only redirects you to login page. What I saw from another site is, browser will popup an alert with username and password to be filled. Nez -- You received this message because you are subscribed to the Google

Re: 'ValuesListQuerySet' object has no attribute 'META'

2011-06-09 Thread Ian Clelland
On Thu, Jun 9, 2011 at 11:00 AM, javatina wrote: > I need a list of all IDs for model records. So, I do this > concept_ids = Concept.objects.values_list('concept_id', flat=True) > > concept_ids is a ValuesListQuerySet - I got it. According to docs > since ValuesListQuerySet

Re: Email app is breaking long lines, any fix?

2011-06-09 Thread John Crawford
Just for the record, to close this off - the problem was solved when I finally configured Django to send email via my *ISP*. Apparently Django was doing some unnecessary formatting, whether the output went to file, console, or even *smtp*, going to a local smtp server: python -m smtpd -n -c

Re: Django daemon

2011-06-09 Thread Nan
Wait... how long has django.utils.daemonize existed, and why isn't it documented? (Wishing I'd known about this 12 months ago...) On Jun 9, 8:19 am, Tom Evans wrote: > On Thu, Jun 9, 2011 at 12:50 PM, Sherif Shehab Aldin > > wrote: > > Actually

Re: Django daemon

2011-06-09 Thread Sherif Shehab Aldin
Alright, I think now I know what to do ;-) Thanks everyone who tried to help :-) On Thu, Jun 9, 2011 at 3:14 PM, Shawn Milochik wrote: > On 06/09/2011 07:50 AM, Sherif Shehab Aldin wrote: > >> Actually that's what am doing, am saving the files with timestamp, The >>

Re: abc

2011-06-09 Thread jaspreet kaur
k thanks -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this

Passing cookies around?

2011-06-09 Thread Roy Smith
We're using django as a front end to a pre-existing web site implemented in PHP. The PHP code has a vaguely RESTful interface, where you can make HTTP calls on it and get back JSON-ized data. The django layer sits in front of that and talks directly to the browser. We're not using any models in

Serge Illaryonov wants to chat

2011-06-09 Thread Serge Illaryonov
--- Serge Illaryonov wants to stay in better touch using some of Google's coolest new products. If you already have Gmail or Google Talk, visit: http://mail.google.com/mail/b-888d96fd0a-997bf05459-ELIpu97555fCtl3jlI1zKT_ZJlE

Serge Illaryonov wants to chat

2011-06-09 Thread Serge Illaryonov
--- Serge Illaryonov wants to stay in better touch using some of Google's coolest new products. If you already have Gmail or Google Talk, visit: http://mail.google.com/mail/b-888d96fd0a-3b21a3b9fb-Uvp05Dr0RIOiVE4GbtbXCoYF7_w

Re: Authentication in API (REST)

2011-06-09 Thread Malcolm Box
On 9 June 2011 17:51, Neznez wrote: > Hi all, I'm newbie in Django, and I started to build my own API. I > know that there is Piston or Django REST framework, but I want to > learn API from scratch. What I want to know is, how to make my HTTP > Response (View) is perform

Re: Boolean field, unexpected behavior

2011-06-09 Thread Malcolm Box
On 9 June 2011 21:16, elliot wrote: > However, I'm still not clear why i can save without specifying values > for the CharField or BooleanField. I didn't say null="true", and I > didn't provide default values. > > Because both have sensible default values ("" for

Re: Boolean field, unexpected behavior

2011-06-09 Thread elliot
Thanks, Your email wasn't showing up when I sent the second one. Little bit of lag i guess. What a noob mistake, thanks for the clarification. I did originally have a default in my model instance, but i deleted it as part of the debugging. However, I'm still not clear why i can save without

Re: NoReverseMatch Error

2011-06-09 Thread krzysiekpl
Hi, Look at this: https://docs.djangoproject.com/en/dev/topics/http/urls/#reverse `viewname` is incorrect in your app you must use 'poll_results' instead of 'polls.views.results' Krzysztof Hoffmann On 9 Cze, 09:28, bahare hoseini wrote: > hi there, > this is my

Re: Boolean field, unexpected behavior

2011-06-09 Thread Shawn Milochik
On 06/09/2011 03:42 PM, elliot wrote: to my great annoyance, not specifying active has lead to the objects being created as I wanted. But I cannot rely on this. Seems like m.active is true if either true or false is specified, and is false if it is never initialized. See my previous e-mail.

auth.LoginTest seems to require sites

2011-06-09 Thread Brian
Hi, When I run the unit tests, I get a failure (stack trace below) from django.contrib.auth.tests.views.LoginTest. test_current_site_in_context_after_login calls Site.objects.get_current() which fails because I'm not using that app. If I include it in the list of installed apps, then the test

Re: Boolean field, unexpected behavior

2011-06-09 Thread elliot
to my great annoyance, not specifying active has lead to the objects being created as I wanted. But I cannot rely on this. Seems like m.active is true if either true or false is specified, and is false if it is never initialized. On Jun 9, 2:24 pm, elliot wrote: > I

Re: Boolean field, unexpected behavior

2011-06-09 Thread Shawn Milochik
You have two problems: 1. You're assigning a string to a boolean. The string will evaluate to true. 2. You're not re-querying the database after the first save, so your 'm' instance still retains the string 'False.' Here's some sample output with commentary which will illustrate. #get an

Re: VERY cheap django hosting?

2011-06-09 Thread elliot
more specific: Django is already installed, howto page on setting up a project works as expected, comes with ssh. all on the baby plan for $4/month (might be more if you only get short contract). I believe Django is 1.1. My only complaint is that default python is 2.4, but I have been using 2.7

Boolean field, unexpected behavior

2011-06-09 Thread elliot
I am not new to django, but this misbehavior is blowing my mind. I cannot understand what is happening. please help. Django 1.1 I have: class MeetingMember(models.Model): lastname = models.CharField(max_length = 30) firstname = models.CharField(max_length = 30) active =

Django admin report

2011-06-09 Thread Leonardo da Costa Santos
Good morning guys! I came to share with you the Django Admin Report ... she is a little Django app that makes it easy to export reports in PDF using the administration interface of django. The idea is to just tell the class of directors which is the list of template fields to be exported

Re: VERY cheap django hosting?

2011-06-09 Thread elliot
I use hostgator works great for me. customer service is helpful. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to

Re: abc

2011-06-09 Thread Iván Raskovsky
Hello, why don't you start with the first steps[0]? https://docs.djangoproject.com/en/1.3/#first-steps On Thu, Jun 9, 2011 at 3:29 PM, jaspreet wrote: > i m new to django ...i need the help > > -- > You received this message because you are subscribed to the Google Groups >

abc

2011-06-09 Thread jaspreet
i m new to django ...i need the help -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com.

Re: VERY cheap django hosting?

2011-06-09 Thread Jagdeep Singh Malhi
Webfraction.com very cheap for hosting django For more plan : http://www.webfaction.com/services/hosting -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from

Re: Add custom html between two model fields in Django admin's change_form

2011-06-09 Thread mf
Thanks christian, it worked!!. On 8 jun, 12:21, "christian.posta" wrote: > Well, there are a couple things you could do: > > for the PresupuestoAdminForm, you could do this to the CharField: > name = forms.CharField(max_length=100, >

Re: VERY cheap django hosting?

2011-06-09 Thread Aaron Madison
I put all my projects on Google AppEngine ... works pretty well with django-nonrel although sometimes there are some fairly significant concessions you might have to live with to go this route. AppEngine is

Django and Rich Client

2011-06-09 Thread Knack
Hi guys, I've got a prototype DB + Rich Client app and need to make a proper production app out of it. The client is written in PyQt and needs to fullfill quite some functional and performance requirements (I would really like to keep it). The client connects directly to the DB. After some

Authentication in API (REST)

2011-06-09 Thread Neznez
Hi all, I'm newbie in Django, and I started to build my own API. I know that there is Piston or Django REST framework, but I want to learn API from scratch. What I want to know is, how to make my HTTP Response (View) is perform authentication before can be accessed, or we can make it have to throw

'ValuesListQuerySet' object has no attribute 'META'

2011-06-09 Thread javatina
I need a list of all IDs for model records. So, I do this concept_ids = Concept.objects.values_list('concept_id', flat=True) concept_ids is a ValuesListQuerySet - I got it. According to docs since ValuesListQuerySet is a subclass of QuerySet I can do list(concept_ids) - see

Re: Updating static files: Still in browser cache

2011-06-09 Thread Malcolm Box
Sent from my iPhone, please excuse any typos On 9 Jun 2011, at 14:21, DrBloodmoney wrote: > On Thu, Jun 9, 2011 at 9:16 AM, Malcolm Box wrote: >> On 9 June 2011 08:09, Thomas Guettler wrote: >>> >>> My static files (JS/CSS)

hierarchal inheritance

2011-06-09 Thread LurkingFrog
In our current system, I have noted a pattern of hierarchal inheritance with regards to gathering configuration information . In the simplest case, we add generic foreign key to the table containing the configuration and check the existence of records in order of a predetermined precedence.

Re: 2 projects based on the same codebase

2011-06-09 Thread Benedict Verheyen
> Hi, > > > I developed a calltracking for our team and now, another team is interested > to have their own calltracking. > The best way to seem to deal with a project that is the same from the start, > is to makea new virtualenv > and "git clone" the codebase. The new project might slightly

Re: VERY cheap django hosting?

2011-06-09 Thread Cal Leeming [Simplicity Media Ltd]
Just as a side note guys, I know there are tons of PHP hosting providers out there which offer dirt cheap hosting, but Python hosting is *extremely* different to PHP. A lot of providers simply don't have any concept of how to properly manage a webapp deployment in production. I'd really question

Re: Updating static files: Still in browser cache

2011-06-09 Thread Martin
Use django-compressor. On Thu, Jun 9, 2011 at 9:21 PM, DrBloodmoney wrote: > On Thu, Jun 9, 2011 at 9:16 AM, Malcolm Box wrote: > > On 9 June 2011 08:09, Thomas Guettler wrote: > >> > >> My static files (JS/CSS) are cached in

Re: Payment form

2011-06-09 Thread delegbede
Get another IT Guy or become one. Sent from my BlackBerry wireless device from MTN -Original Message- From: lillian Sender: django-users@googlegroups.com Date: Thu, 9 Jun 2011 06:41:57 To: Django users Reply-To:

Re: Payment form

2011-06-09 Thread Tom Evans
On Thu, Jun 9, 2011 at 2:41 PM, lillian wrote: > Hello, I want to set up a Payment form on my Listen On Demand talk > programs.  How does one set up a form on this system.  Please use > simple words.  I've lost my IT guy and I'm on my own.  Thanks, > Hire a new IT

Payment form

2011-06-09 Thread lillian
Hello, I want to set up a Payment form on my Listen On Demand talk programs. How does one set up a form on this system. Please use simple words. I've lost my IT guy and I'm on my own. Thanks, -- You received this message because you are subscribed to the Google Groups "Django users" group.

Re: Updating static files: Still in browser cache

2011-06-09 Thread DrBloodmoney
On Thu, Jun 9, 2011 at 9:16 AM, Malcolm Box wrote: > On 9 June 2011 08:09, Thomas Guettler wrote: >> >> My static files (JS/CSS) are cached in the browser. But if there is a bug >> in a file, an update won't help people which have already cached the old

Re: Updating static files: Still in browser cache

2011-06-09 Thread Malcolm Box
On 9 June 2011 08:09, Thomas Guettler wrote: > My static files (JS/CSS) are cached in the browser. But if there is a bug > in a file, an update won't help people which have already cached the old > file. > > You would need a new URL for every change in the JS/CSS files. > >

Re: Django daemon

2011-06-09 Thread Shawn Milochik
On 06/09/2011 07:50 AM, Sherif Shehab Aldin wrote: Actually that's what am doing, am saving the files with timestamp, The question is, do I create a daemon to check the dir and process new files in order, and if that's the best practice, how do I use Django environment in the daemon so I can

Re: Django daemon

2011-06-09 Thread Tom Evans
On Thu, Jun 9, 2011 at 12:50 PM, Sherif Shehab Aldin wrote: > Actually that's what am doing, am saving the files with timestamp, The > question is, do I create a daemon to check the dir and process new files in > order, and if that's the best practice, how do I use Django

Re: Django daemon

2011-06-09 Thread Sherif Shehab Aldin
Actually that's what am doing, am saving the files with timestamp, The question is, do I create a daemon to check the dir and process new files in order, and if that's the best practice, how do I use Django environment in the daemon so I can import the models?? On Thu, Jun 9, 2011 at 1:46 PM,

Re: Django daemon

2011-06-09 Thread Shawn Milochik
Here's one idea: When you retrieve the files from the remote server, put them in your local temp directory named with a datestamp. Then, just ensure you process them in order, and you won't have to worry about the out-of-order insertions. -- You received this message because you are

Django daemon

2011-06-09 Thread Sherif Shehab Aldin
Hi all, I need your suggestions regarding the following. I have a Django app, with custom command that runs throw cron and it grabs files from some servers, those files holds data that needs to be inserted into Django models. I can't make the Django command to read the files and insert the data

Re: django transactions.

2011-06-09 Thread Malcolm Box
On 8 June 2011 11:07, Marc Aymerich wrote: > On Tue, Jun 7, 2011 at 11:53 PM, Malcolm Box > wrote: > > n 7 June 2011 15:16, Marc Aymerich wrote:You're > right :) I'm using Mysql with myisam, I'm going to switch to > InnoDB engine

Re: django-ztask

2011-06-09 Thread Markus Gattol
since you want feedback, that's http://www.reddit.com/r/Python/comments/hve19/django_zeromq_djangoztask/ probably something to watch :) -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: Django solved tutorial for download??

2011-06-09 Thread Harjot Gill
www.djangoproject.com , this is the official website of django.In this website you will find the solved example of django application. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: tuple comparison to make one tuple

2011-06-09 Thread MikeKJ
Excellent thank you guys and thanks for the pointer to itertools -- View this message in context: http://old.nabble.com/tuple-comparison-to-make-one-tuple-tp31802229p31808134.html Sent from the django-users mailing list archive at Nabble.com. -- You received this message because you are

Re: 2 projects based on the same codebase

2011-06-09 Thread Malcolm Box
On 9 June 2011 08:06, Benedict Verheyen wrote: > > I developed a calltracking for our team and now, another team is interested > to have their own calltracking. > The best way to seem to deal with a project that is the same from the > start, is to makea new

Re: Django solved tutorial for download??

2011-06-09 Thread Praveen Krishna R
I don't understand what you mean by "django tutorial solved" There is a tutorial which gets you up and running with django, if you are a beginner. and its here ! https://docs.*django* project.com/en/dev/intro/tutorial01/ * * On Wed, Jun 8,

Re: 2 projects based on the same codebase

2011-06-09 Thread delegbede
Hi Benedict, This is a mere advice. I hope someone can come up with an elegant solution pretty soon. The two projects though similar are different and as such there is a possibility that one might get more complex than the other at a much faster rate depending on the client's need. Just go

NoReverseMatch Error

2011-06-09 Thread bahare hoseini
hi there, this is my views.py that doesn't have any problem: from django.shortcuts import get_object_or_404, render_to_response from django.core.urlresolvers import reverse . . . return HttpResponseRedirect(reverse('polls.views.results', args=( p.id,))) def results(request, poll_id):

Re: Updating static files: Still in browser cache

2011-06-09 Thread Alexey Moskvin
Tomas, try this: https://github.com/jaddison/django-cachebuster On 9 июн, 11:09, Thomas Guettler wrote: > Hi, > > My static files (JS/CSS) are cached in the browser. But if there is a bug > in a file, an update won't help people which have already cached the old file. > > You

Re: Excel dumps to Office 10

2011-06-09 Thread Thomas Guettler
Hi, That's bad news. I liked this pattern very much: Send the browser a HTML table with content type application/vnd.ms-excel. This is much better than CSV. If you find a solution, please post here. Thomas On 06.06.2011 17:10, Bobby Roberts wrote: > hey - > > we are dumping results to excel

2 projects based on the same codebase

2011-06-09 Thread Benedict Verheyen
Hi, I developed a calltracking for our team and now, another team is interested to have their own calltracking. The best way to seem to deal with a project that is the same from the start, is to makea new virtualenv and "git clone" the codebase. The new project might slightly differ in the

Updating static files: Still in browser cache

2011-06-09 Thread Thomas Guettler
Hi, My static files (JS/CSS) are cached in the browser. But if there is a bug in a file, an update won't help people which have already cached the old file. You would need a new URL for every change in the JS/CSS files. How do you handle this? Thomas -- Thomas Guettler,