Re: Django and Services

2008-05-02 Thread Peter Rowell
> The one catch that I see is that you still > have to go through all your views and make sure that you're now > passing in a request object, and if you miss any then you won't > necessarily know until you notice that your page is rendered funny. No problems, mate. :-) All Django views a) take a

Another installation problem

2008-05-02 Thread LRP
Hi Folks, I've been trying for days now to correctly install python2.5 and psycop2 on my Debian Etch system so I can work with postgresql8.1, django, and web2py. I've installed python2.5 from the Debian repository and made it the default choice. When I call python from the CLI I get Python2.5.

Re: Pass extra data to a view

2008-05-02 Thread Jay Parlar
On 5/2/08, Jay Parlar <[EMAIL PROTECTED]> wrote: > I must be missing something super obvious here, but I can't figure out > how to pass data to a new view, from the old one. > > For example, I have the following in a view: > > categories = [1,2,3] > return HttpResponseRedirect( >

Installation problem...

2008-05-02 Thread Pedro Vidal
Hello guys, I'm a new django user, and I'm tryin since three days ago install django, but it's still not working... That's the problem: Installed Python, ok. Installed mod_python, ok. Downloaded and extracted django, renamed the folder to "django" and put it in C:/, everything ok. The Apache

Patch #2070, progress bar and form view. Can't make it work.

2008-05-02 Thread Julien
Hi everyone, I'm trying to use patch with ticket #2070 [1] to be able to upload big files and have a progress bar, and I can't quite figure out how to make it work... I'm also using 2 snippets [2] and [3]. Then, here's my simple view and template: View --- def frontpage(request): if

Re: Django installation problem ...

2008-05-02 Thread Karen Tracey
On Fri, May 2, 2008 at 5:27 PM, AY <[EMAIL PROTECTED]> wrote: > > Following the instruction on Django tutorial #4, I had encounted the > following problem: > > On the website of http://localhost:8000/polls/ ...it displays only one > line of information ...". What's up? " > > and on the website

Debugging, breakpoints, and newforms-admin

2008-05-02 Thread Martin Diers
I have a problem I am trying to troubleshoot, specifically on the newforms-admin branch, latest revision as of this afternoon. The trouble is in an Inline, which contains MultiWidgets assigned two MultipleValueFields. In this case, it is a Bible reference being displayed as a select, and

Re: Looking at objects by year, month

2008-05-02 Thread Pawel Pilitowski
Maybe something like this would help: in the month loop: {% if forloop.counter|divisibleby:"2" %} {% else %} {% endif %} or try forloop.parentloop.counter if you need to get at it from you event loop. Cheers, Pawel On 03/05/2008, at 11:15 AM, Darryl Ross wrote: Ryan

Re: Looking at objects by year, month

2008-05-02 Thread Darryl Ross
Ryan Vanasse wrote: Now, my problem is that for every month, I want a different color of image text... //blue/orange swap so that on even months i'd have them come from the blue folder and odd months they'd come from the orange folder (or something of that nature). As far as I can tell, none

Pass extra data to a view

2008-05-02 Thread Jay Parlar
I must be missing something super obvious here, but I can't figure out how to pass data to a new view, from the old one. For example, I have the following in a view: categories = [1,2,3] return HttpResponseRedirect( reverse('question-select',

Re: File caching and pickling issue

2008-05-02 Thread Julien
> > So we have same problem? Have you find solution? I don't know if we both have the same problem... the error messages seem to be a bit different. I have had other problems with caching that same function (all other parts of the site that are cached work perfectly). I've got "TypeError:

Re: efficiency of apache+mod_fastcgi --> django+flup

2008-05-02 Thread Graham Dumpleton
On May 3, 3:10 am, Robin Becker <[EMAIL PROTECTED]> wrote: > Djangophiles, is there any kind of analysis of the above combination with > regard > to efficiency. It seems that mod_fastcgi must talk to the flup server through > a > single socket (or rather each front end apache process must do

DjangoAMF vs. pyAMF - any opinions?

2008-05-02 Thread J Peyret
I am just starting out with Flex 3 and I'd like to know if anybody's got any strong opinions on which AMF<=>Python bridge is best for using AMF to talk to Django. I do know Python and am somewhat familiar with Django. Things that make a difference to me, roughly in order of decreasing

Django installation problem ...

2008-05-02 Thread AY
Following the instruction on Django tutorial #4, I had encounted the following problem: On the website of http://localhost:8000/polls/ ...it displays only one line of information ...". What's up? " and on the website of (1)http://localhost:8000/polls/poll_list.html or (2)

Code works with Django's server, but not with Apache+mod_python?

2008-05-02 Thread mw
Hello, I've emailed the mailing list in the past because of problems with PIL and and image field upload in the admin interface. The problem, just got weirder. I noticed that images were never validating as actual images and were constantly being rejected. Out of a hunch, I fired up the

Re: django can't find admin or any other templates

2008-05-02 Thread jmDesktop
I got it to find the /media/ directory by adding the media folder to inetpub/wwwroot directory. I had that when I initially created my wsgi dll with isapi-wsgi. I tried changing the root folder to my real root folder, but it did not affect anything. It required the media folder in inet pub.

Re: django can't find admin or any other templates

2008-05-02 Thread jmDesktop
I have verified that it is pulling the admin template from the site- packages and not my new templates directory, for some reason. I changed base_site.html and it only updates from the site-packages base_site.html file, not the local templates directory. On May 2, 3:20 pm, jmDesktop <[EMAIL

Re: File caching and pickling issue

2008-05-02 Thread Josh Whitaker
tell me what you mean. - Original Message From: Szymon <[EMAIL PROTECTED]> To: Django users Sent: Friday, May 2, 2008 2:28:43 PM Subject: Re: File caching and pickling issue On 30 Kwi, 16:12, Julien <[EMAIL PROTECTED]> wrote: > [...]

Re: File caching and pickling issue

2008-05-02 Thread Szymon
On 30 Kwi, 16:12, Julien <[EMAIL PROTECTED]> wrote: > [...] http://groups.google.com/group/django-users/browse_thread/thread/ed3abed9122f5506/eb4237d8fe579e7b?lnk=gst=pickling+error#eb4237d8fe579e7b So we have same problem? Have you find solution?

django can't find admin or any other templates

2008-05-02 Thread jmDesktop
I am using IIS 5.1, xp pro, isapi-wsgi. I can get the admin page working. It has not CSS and is plain because it cannot resolve the link to the stylesheet /media/css... In my settings.py I have: ADMIN_MEDIA_PREFIX = "/media/" TEMPLATE_DIRS - ( "C:/sw/django/mysite/templates", #I have the

blogmaker: bool not iterable

2008-05-02 Thread gregf
Hi, I'm trying to get Blogmaker (.6 Jan 2) running. I'm using django trunk from today, but got the same error on an older trunk. Dbsync created the databases properly, and the front-end is showing without error, although there are no entries. Admin is giving this error on a template. {{

Re: django-tagging doesn't work with qs-ref

2008-05-02 Thread Michael
Update your django-tagging. This bug was fixed in the new svn release. On Fri, May 2, 2008 at 2:10 PM, James Bennett <[EMAIL PROTECTED]> wrote: > > On Fri, May 2, 2008 at 1:05 PM, bcurtu <[EMAIL PROTECTED]> wrote: > > How can I solve this parse_lookup problem? > > Cheers > > Have you

Sorry to butt in. I'm just trying to get my message out.

2008-05-02 Thread Slayer
Please come check out SaveTheWorld. It's my own group that I'm trying to get started. There's no harm in looking is there? Come see what I'm trying to do to change the world. Come to look, to laugh, to get enraged in debate, but please come. --~--~-~--~~~---~--~~

Re: django-tagging doesn't work with qs-ref

2008-05-02 Thread James Bennett
On Fri, May 2, 2008 at 1:05 PM, bcurtu <[EMAIL PROTECTED]> wrote: > How can I solve this parse_lookup problem? > Cheers Have you considered looking at that project's bug tracker? http://code.google.com/p/django-tagging/issues/detail?id=106=1=queryset-refactor -- "Bureaucrat Conrad, you are

django-tagging doesn't work with qs-ref

2008-05-02 Thread bcurtu
Hi, Have any of you used django-tagging with the new qs-ref? It doesn't work, when I do a manage.py syncdb it yells: ... File "/usr/local/lib/python2.5/site-packages/tagging/managers.py", line 6, in from django.db.models.query import QuerySet, parse_lookup ImportError: cannot import name

Re: What is reverse() good for? Not really reversing...

2008-05-02 Thread J. Cliff Dyer
On Thu, 2008-05-01 at 09:36 -0700, web-junkie wrote: > Hi, > > what is the new reverse() method good for? Seems it just swaps the > order_by statement? > I would appreciate a reverse() method that, if used after slicing, > would actually reverse the queryset. > In the docs it's said: "Django

Re: Need help with tutorial url.py not matching using IIS and isapi_wsgi

2008-05-02 Thread jmDesktop
On May 2, 12:25 pm, jmDesktop <[EMAIL PROTECTED]> wrote: > On May 2, 10:18 am, jmDesktop <[EMAIL PROTECTED]> wrote: > > > > > > > Hi, I am using isapi_wsgi with django, or trying to: > > >http://code.google.com/p/isapi-wsgi/wiki/IntegrationWithDjango > > > I have my script exactly like the

Re: Rendering specific widgets of a MultiWidget

2008-05-02 Thread Bram Duvigneau
Thanks for the replies. I'm not really new to Django, but this is my first application that I'm really building with it. I never said that this should be in trunk or something, but if it will get in, I would prefer something more customizable. However, it seems that writing my own version that

Re: profiling django with fastcgi & cprofile?

2008-05-02 Thread skunkwerk
I tried appending -m cProfile -o project.profile to this call: /usr/bin/python manage.py runfcgi... but i got an error saying can't open cProfile - no such file or directory. is this even the right place to call cProfile? the other option would be to modify this:http://code.djangoproject.com/

Re: Need help with tutorial url.py not matching using IIS and isapi_wsgi

2008-05-02 Thread jmDesktop
On May 2, 10:18 am, jmDesktop <[EMAIL PROTECTED]> wrote: > Hi, I am using isapi_wsgi with django, or trying to: > > http://code.google.com/p/isapi-wsgi/wiki/IntegrationWithDjango > > I have my script exactly like the example.  I created the same > directories on my pc.  I believe django is

Re: File Upload, form issue

2008-05-02 Thread Peter
It's probably one of two things: 1. You might be pointing to the wrong template, load the page in your browser and hit view source to ensure that your form is indeed doing enctype="multipart/form-data", and that whatever url you're pointing to for the action attribute is blank or for debugging,

Re: What is reverse() good for? Not really reversing...

2008-05-02 Thread Justin Lilly
Interesting. To support your statement, I tried it myself and here's what I got from my shell... In [1]: from aids.trends.models import County In [2]: foo = County.objects.all()[:3] In [3]: foo Out[3]: [, , ] In [4]: foo.reverse() Out[4]: [, , ] In [5]: foo.reverse() Out[5]: [, , ] In [6]:

Re: What is reverse() good for? Not really reversing...

2008-05-02 Thread Karen Tracey
On Fri, May 2, 2008 at 11:11 AM, web-junkie <[EMAIL PROTECTED]> wrote: > > On 1 Mai, 19:32, "Justin Lilly" <[EMAIL PROTECTED]> wrote: > > While it may be the long way around, can you not do the following? > > a = Articles.objects.all()[:3] > > a.reverse() > > > > That would probably be my

Re: Should I set up Django locally or on a web server?

2008-05-02 Thread Justin Lilly
Just to save you a step, you don't have to create the sqlite db file. If you reference it in settings.py, then run syncdb.. django will create it for you. On Fri, May 2, 2008 at 11:31 AM, Matic Žgur <[EMAIL PROTECTED]> wrote: > > I use Sqlite3 for development because it already comes installed

Re: Should I set up Django locally or on a web server?

2008-05-02 Thread Matic Žgur
I use Sqlite3 for development because it already comes installed with Ubuntu. I used to use Apache and MySQL, but it didn't make much sense using that since Django development server and Sqlite3 handle serving quite well and are quite lightweight. To start using Sqlite you just have to create a

Re: What is reverse() good for? Not really reversing...

2008-05-02 Thread web-junkie
That's exactly what I tried, and as I described, it gives you something wrong, not the queryset reversed... On 1 Mai, 19:32, "Justin Lilly" <[EMAIL PROTECTED]> wrote: > While it may be the long way around, can you not do the following? > a = Articles.objects.all()[:3] > a.reverse() > > That

Django Users Group Belfast

2008-05-02 Thread Gareth Fleming
This is probably not the place to discuss this, but are there enough Django users interested to start a user group in Belfast? I have no experience of running a user group (apart from an internal one at work, and that's not going too well), but I'd love to meet with other users in the area.

Need help with tutorial url.py not matching using IIS and isapi_wsgi

2008-05-02 Thread jmDesktop
Hi, I am using isapi_wsgi with django, or trying to: http://code.google.com/p/isapi-wsgi/wiki/IntegrationWithDjango I have my script exactly like the example. I created the same directories on my pc. I believe django is "trying" to work, but it cannot resolve the URLs. I have done syncdb and

self-rerencing ForeignKey menu in admin

2008-05-02 Thread leland
Hi all - I have this code: class Page(models.Model): visible = models.BooleanField(default=True) parent = models.ForeignKey('self', null=True, blank=True) title = models.CharField(max_length=255) In the admin, I don't want a user to be able to select the current page as its own

Re: Should I set up Django locally or on a web server?

2008-05-02 Thread Taylor
SQLite is a good solution, but if you maybe want something that's closer to what you may be using in production, installation of MySQL on OS X is pretty easy. Check out this link: http://dev.mysql.com/doc/refman/5.1/en/mac-os-x-installation.html The only other thing you need is the database

Re: Announcing django-compress

2008-05-02 Thread Andreas Pelme
On 2 Maj, 02:04, hiwd <[EMAIL PROTECTED]> wrote: > this sounds awesome. > > i'll take a look, and implement, and try to push some code to prod > next week (if things are hunky dory) > Great! I'd be happy to hear how it went! Cheers Andreas --~--~-~--~~~---~--~~

Re: Custom Authentication System

2008-05-02 Thread Abdallah El Guindy
Thanks for the reply... I'll try that out and see if it works out... On May 2, 1:18 am, jonknee <[EMAIL PROTECTED]> wrote: > > Can anyone refer a nice tutorial or explain how to create custom > > user attributes and use the authentication/authorization app? > > It would be just like a regular

Re: Announcing django-compress

2008-05-02 Thread desfrenes
Thank you ! I used to have a similar tool in PHP and having it for Django is a blessing. On May 1, 3:57 pm, [EMAIL PROTECTED] wrote: > Hi > > I recently put up django-compress on Google > Code:http://code.google.com/p/django-compress/ > > django-compress provides an automated system for

Re: Memcached hangs & never responds?

2008-05-02 Thread Gregor Hochmuth
I think this might be it, thank you *so much* Karen! On May 2, 1:55 am, "Karen Tracey" <[EMAIL PROTECTED]> wrote: > On Thu, May 1, 2008 at 6:51 PM, Gregor Hochmuth <[EMAIL PROTECTED]> wrote: > > > Hello, > > Has anyone experienced the following symptom with Memcached before? > > >

Admin : Select category -> show subcategory

2008-05-02 Thread martyn
Hi, I've created a simple product model : class Produit(models.Model): nom = models.CharField(maxlength=200) slug = models.SlugField(prepopulate_from=('nom',)) description = models.TextField(blank=True) published = models.BooleanField(default=True)

Re: Looking at objects by year, month

2008-05-02 Thread Ryan Vanasse
I got my data to populate mostly alright. The key was changing the template example to "{% for month in months.values %}" it wasn't working before that. Now, my problem is that for every month, I want a different color of image text... //blue/orange swap so that on even months i'd have them

Is there a way to disable QuerySet caching?

2008-05-02 Thread Cornel Nitu
Hi, I'm using this manager in order to display only the articles which have the status "P"(published). By default all the articles have the status "D" (draft). class ArticleManager(models.Manager): def get_query_set(self): queryset = super(ArticleManager, self).get_query_set()

Re: ManyToMany error with new queryset refactoring

2008-05-02 Thread bcurtu
I found it! Karen you are right. I had already a field called "friends", with a different information. When I was using Attributes as an OneToOne relationship it was all ok, but when using it in inheritance, it fails, of course! Thanks for your help On 2 mayo, 01:42, "Karen Tracey" <[EMAIL

Re: Django and Services

2008-05-02 Thread Michael Burton
> I'll have to disagree with you here.  I think this is a perfect > example of Russ's point.  Somewhere on your PYTHONPATH just write a > function that looks something like this (warning, untested code): > > from django.shortcuts import render_to_response as old_rtr > from django.template import

Re: django-tagging or search engine?

2008-05-02 Thread francesco
Thanks a lot for your replies. So, if I understand correctly from the last two posts, the suggestion would be to keep the tags but to store them in a full-text-index engine so that the queries will be more efficient. In that case I have a few more questions: would that approach help protecting

Re: Django and Services

2008-05-02 Thread [EMAIL PROTECTED]
> It's a very good idea, but it suffers from a DRY usability concern > related to the pervasive use of the render_to_response() shortcut > commonly employed by Django apps.  Because render_to_response() is a > static method, there's no good way to pre-configure it to use > RequestContext instead

Re: Django and Services

2008-05-02 Thread Michael Burton
> Ah.. the singleton... Java's answer to the fact that not everything is > an object. :-) Ha ha, fair enough Russ :) And I don't dispute a certain java- oriented predisposition to the way i think about these problems. But let me bring a point in favor of the Singleton, and why I think it might