Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Reinout van Rees
. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups &quo

Re: Release considerations

2012-07-10 Thread Reinout van Rees
example configurations on how to integrate it with a webserver (apache/nginx). Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham"

Re: JSONField: which app to choose ?

2012-07-10 Thread Reinout van Rees
/django-jsonfield/ on bitbucket. I looked at it with a colleague and it seemed to have a bit more validation than some others. Little things. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not

Re: How to serve staticfiles with full URL for local development?

2012-05-14 Thread Reinout van Rees
of my messages something about "needing a full path name '/tmp/' for saved pages". What did you mean by that? Such a full path is different from a proper localhost:8000 url. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: How to serve staticfiles with full URL for local development?

2012-05-05 Thread Reinout van Rees
. You have to add that to your urls.py. But normally, you don't have to. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You r

Re: template logic vs AJAX newbie seeks advice

2012-05-05 Thread Reinout van Rees
: take a look. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Goo

Re: template logic vs AJAX newbie seeks advice

2012-05-05 Thread Reinout van Rees
-- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Django users&

Re: template logic vs AJAX newbie seeks advice

2012-05-04 Thread Reinout van Rees
-- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Django users&

Re: How to get caller function from a function

2012-05-04 Thread Reinout van Rees
, not returning its results. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are

Re: buildout development vs. deployment

2012-04-30 Thread Reinout van Rees
. That way you can also reuse them and be sure that everything you need is included. The core point is that setup.py's are "recursive" where buildouts are not. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http:/

Re: @login_required do nothing

2012-04-29 Thread Reinout van Rees
Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Djan

Re: outdated django book

2012-04-29 Thread Reinout van Rees
link: http://www.caktusgroup.com/blog/2011/12/29/class-based-views-django-13/ You need to decorate the dispatch() method in the class-based-view case. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you'r

Re: Unable to get result using distance query

2012-04-29 Thread Reinout van Rees
reats points differently? Wild guesses... Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you

Re: buildout development vs. deployment

2012-04-29 Thread Reinout van Rees
your project directory, nothing beats the functionality of buildout. And it combines fine with tools like fabric that can handle everything outside of the project directory. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://

Re: Loading static files from a dev environment

2012-04-29 Thread Reinout van Rees
. The directory that collectstatic fills is just for your production environment where you've got a proper webserver to serve that directory. So... it is by design :-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen

Re: Django Book

2012-04-21 Thread Reinout van Rees
able books are quite old, so I'm doing my best to get this one out so that there's a current book. I'm targetting Django 1.4 so that's pretty current :-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/

Re: TestCase Client.login() fails

2012-03-28 Thread Reinout van Rees
rns a User. You're right, I was wrong :-) I overlooked that create_user is a special call and thought it was just a generic create statement. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "I

Re: TestCase Client.login() fails

2012-03-28 Thread Reinout van Rees
mple error. Reinout [1]: http://reinout.vanrees.org/weblog/2011/11/18/django_unicodedecodeerror.html -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul

Re: myproject/wsgi.py vs. myproject.wsgi?

2012-03-26 Thread Reinout van Rees
van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Django users&

Re: philosophy behind sites and applications in Django

2012-03-26 Thread Reinout van Rees
at in the apps. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed t

Re: Pip install matplotlib error with virtualenv

2012-03-26 Thread Reinout van Rees
* mean you must have all xyz-devel packages installed. An alternative is to keep your global python clean and only install specific packages with your OS that are best handled by the OS. Don't "pip install" other stuff by hand. Reinout -- Reinout van Rees

Re: Accessing objects from a dictionary in templates

2012-03-23 Thread Reinout van Rees
? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups &quo

Re: Accessing objects from a dictionary in templates

2012-03-23 Thread Reinout van Rees
{{ my_dict.42 }}. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to

Re: Pip install matplotlib error with virtualenv

2012-03-23 Thread Reinout van Rees
On 23-03-12 21:37, Reinout van Rees wrote: On 23-03-12 18:51, darwin_tech wrote: the weird thing is that matplotlib works fine on my system. If I have a Django project running outside of virtualenv, there is no problem and matplotlib is on the pythonpath. One of virtualenv's options

Re: Pip install matplotlib error with virtualenv

2012-03-23 Thread Reinout van Rees
python. "virtualenv -s" or something like that. Perhaps you passed along that option? In that case, nothing in your virtualenv can find the system python's matplotlib. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http:/

Re: Pip install matplotlib error with virtualenv

2012-03-23 Thread Reinout van Rees
this. Only reason I can think of is that it might be safer on the server or something like that. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul G

Re: Django log lines spamming syslog

2012-03-23 Thread Reinout van Rees
for debug purposes. So check the django that your site is using and see if you have to beat someone with a stout stick. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do,

Re: Django-1.4c2 logging issue on Snow Leopard

2012-03-23 Thread Reinout van Rees
path or so. Or the `#!` python line at the top. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message becaus

Re: Weird stacktrace coming from manage.py test

2012-03-23 Thread Reinout van Rees
geodjango case, do you perhaps miss django.contrib.gis in your INSTALLED_APPS list? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham&quo

Re: Request Context problem

2012-02-19 Thread Reinout van Rees
token. It won't even hit your "else add csrf token" code. The solution is simple: just add a {{ csrf_token }} somewhere in your form. That ought to do it. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-sch

Re: sqlite3 error

2012-02-12 Thread Reinout van Rees
f was fine in older django versions, so you might have picked up an example from there. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham&qu

Re: how to lookup dictionary in filter return?

2012-01-27 Thread Reinout van Rees
In your case: {% for itm in somevalue | dic_filter %} {{ somevalue.itm }} {% endfor %} (And I'd replace 'itm' with 'key') Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure wha

Re: Error with Apache + mod_wsgi

2012-01-27 Thread Reinout van Rees
ies. I'd try looking at /usr/lib/pymodules/python2.6/django and figure out which Django version that is. And if python 2.6 is the same one as was running before. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-sch

Re: CsrfViewMiddleware from a xml post?

2012-01-24 Thread Reinout van Rees
that takes care of including the csrf token: https://docs.djangoproject.com/en/dev/ref/contrib/csrf/#ajax Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make some

Re: Can't make 404.html template to be used. Keep getting Apache 500 Internal Server Error instead.

2012-01-22 Thread Reinout van Rees
ement, btw. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google G

Re: django-html5boilerplate error

2012-01-19 Thread Reinout van Rees
/static/js/libs/modernizr-2.0.min.js So it is all relative to main.js and it somehow has a | and some number behind it. I think you've mis-configured something with that django-mediagenerator you mention. (or django-mediagenerator is defective, I don't know as I haven't heard about

Re: How I could reset django admin pass in a buildout project

2011-12-29 Thread Reinout van Rees
s normally impossible. You must have removed something by hand? Could you look inside the bin/django script? It ought to have a "sys.path" list in there that shows you where it thinks it can find the djangorecipe. Make sure it is still there. Or re-run your buildout, for instance. Reinout

Re: How I could reset django admin pass in a buildout project

2011-12-29 Thread Reinout van Rees
variable to your settings file pre-set. So: "bin/django shell". Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You

Re: preventing data from getting saved to the backend database?

2011-12-27 Thread Reinout van Rees
eems a bit wasteful: use some low-level django caching and you'll be fine again. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham&qu

Re: Django Upload Image Help

2011-12-12 Thread Reinout van Rees
"render as an integer".). So I'd expect an "TypeError: not enough arguments for format string". Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do

Re: Best way to upload and play a video

2011-12-11 Thread Reinout van Rees
is to upload it to youtube/smugmug/whatever and to just store a URL in your model, pointing at the correct embed URL. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do,

Re: converting from function based views to class based views

2011-12-10 Thread Reinout van Rees
hints? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Grou

Re: urls.py?

2011-12-09 Thread Reinout van Rees
ariables by accident that way. Better to explicitly import what you need. In this case the problem was that the original poster imported 'view' a few times from different places. Doing a "*" import would only make that problem worse :-) Reinout -- Reinout van Reesht

Re: urls.py?

2011-12-09 Thread Reinout van Rees
t have one variable point to several things at the same time. Best thing you can do: import mysite.contact.views import mysite.books.views ... (r'^contact/$', mysite.contact.views.contact), Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@v

Re: Any help regarding the SAAS based django-web application

2011-12-08 Thread Reinout van Rees
documentation or help on this topic if anyone has already developed in this way See Tom Evans' reply to your previous email. Your question is way too broad to give a meaningful answer. You'll have to give us more information. Reinout -- Reinout van Reeshttp

Re: Deployment problem

2011-12-08 Thread Reinout van Rees
ture of my files , what to upload ? mod_python is very outdated and unmaintained for years. Almost everyone uses wsgi (for apache: mod_wsgi) nowadays. Look a bit at the django documentation to get an idea. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@v

Re: Query with no-correspondence results

2011-12-06 Thread Reinout van Rees
ght be a way to do it with the ORM; but you can definitely use raw sql for this. Till two years ago I didn't touch an sql database for 8 years as I used zope's luxurious python object database :-) So I'm happily proven wrong in what SQL can do :-) Reinout -- Reinout van Rees

Re: Query with no-correspondence results

2011-12-06 Thread Reinout van Rees
with a Django query). In case you want all contexts, you'll have to query for those specifically. And afterwards grab the results belonging to that context. So you won't escape a for loop and some manual work, I'm afraid. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/

Re: Django E-Commerce Framework

2011-12-06 Thread Reinout van Rees
On 06-12-11 06:40, Md,Mehedi Hasan Kabir(Tanim) wrote: Can anyone give me some suggestion/link for Django E-Commerce Framework? No personal experience, but the one I see mentioned most often: django lightning fast shop. http://www.getlfs.com/ Reinout -- Reinout van Rees

Re: Management commands inside namespaced packages not found

2011-12-06 Thread Reinout van Rees
). - You still have the companyname prefix. - You get the full "companyname_product" in INSTALLED_APPS. - You visually see the difference between the package dir and the python module dir. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@v

Re: Template filter with multiple non-string arguments?

2011-12-06 Thread Reinout van Rees
. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups &quo

Re: Query with no-correspondence results

2011-12-06 Thread Reinout van Rees
).values_list('thing', 'context', 'vote) should return a list of those lists. What do you get with a plain Vote.objects.filter(thing=carrot) ? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If y

Re: Can't figure out this Object Model error...

2011-12-05 Thread Reinout van Rees
ith syncdb (it will now contain the foreign key column). - Use south for database migrations. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul

Re: Query with no-correspondence results

2011-12-05 Thread Reinout van Rees
ific values: Vote.objects.filter(thing=carrot).values_list('thing', 'context', 'vote) See https://docs.djangoproject.com/en/1.3/ref/models/querysets/#values-list for how that last trick works. Something like that? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ re

Re: New design for class-based views

2011-12-05 Thread Reinout van Rees
;keep forever" option? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed

Re: Django

2011-12-02 Thread Reinout van Rees
? Depends on how you want to edit. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are

Re: How to intercept password change in admin module ?

2011-12-01 Thread Reinout van Rees
list than Django's build-in apps? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are

Re: Nginx - How to configure the virtual.conf to serve a Django application

2011-11-30 Thread Reinout van Rees
t_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_redirect off; proxy_pass http://localhost:11000; } } Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/

Re: A view associated with a lot of urls

2011-11-29 Thread Reinout van Rees
So you probably have a start page that lists the categories and then a category page that lists the items. A 404 on /non/existing leads people to try /non/ which would also 404. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: django 1.3: how to use get_abolute_url in class based generic views

2011-10-15 Thread Reinout van Rees
e instead of a url. You forgot to call reverse(): from django.core.urlresolvers import reverse ... def get_absolute_url(self): return reverse('article_detail', (), { 'year': ^^^ ... That's probably it. Reinout - class based views are great -

Re: forms.ChoiceField/forms.ModelChoiceField Needs a Lot of Love

2011-09-06 Thread Reinout van Rees
ayhap it suggests improvements to the generic choicefield? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message

Re: logging django errors also on the server

2011-09-04 Thread Reinout van Rees
messages, including the ones to the django.something.error logger. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- Yo

Re: logging django errors also on the server

2011-09-04 Thread Reinout van Rees
://djangosnippets.org/snippets/421/ . I've used that one for almost a year. Works like a charm. But... hurray for django 1.3 for including it in the regular python logging :-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http

Re: Template image display issue

2011-09-01 Thread Reinout van Rees
t available separate for earlier django versions). Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this mess

Re: Unable to have a template NOT show up

2011-09-01 Thread Reinout van Rees
loader is the one that you ought to use most of the time, so that's good. What's not good is that apparently only the admin's templates are found. Is your "polls" app a real app? Is it in your settings.py's INSTALLED_APPS list? Reinout -- Reinout van Rees

Re: Setting up a PostGIS DB

2011-09-01 Thread Reinout van Rees
casts. Anyone have any advice or ideas? It seems you haven't installed the postgis database extras into your postgres database. It depends on your OS how you have to do that. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http

Re: feed updates stopped working

2011-09-01 Thread Reinout van Rees
ks as it didn't seem to run :-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscrib

Re: feed updates stopped working

2011-09-01 Thread Reinout van Rees
-c "import sys;print sys.path" Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because yo

Re: Unable to have a template NOT show up

2011-09-01 Thread Reinout van Rees
/ The current URL, |polls/1/|, didn't match any of these. Such a "^polls/ ^polls/$" regex is incorrect. What's the extra "^polls/ " doing in front of the actual regex? That's the cause of your error, I think. Reinout -- Reinout van Reeshttp://reino

Re: feed updates stopped working

2011-09-01 Thread Reinout van Rees
On 01-09-11 15:11, vanderkerkoff wrote: Thanks for trying though, I will find the problem, eventually:-) Can you specify "it stopped working" a bit, btw? Do you get a traceback, for instance? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@v

Re: feed updates stopped working

2011-09-01 Thread Reinout van Rees
an OS update also updated the python version? So that the default /usr/bin/python isn't the same anymore as the version with the fact.pth in its site-packages folder? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen

Re: Unable to have a template NOT show up

2011-08-31 Thread Reinout van Rees
how up? You probably forgot to add it to your INSTALLED_APPS list in your settings.py. At least, that happened to me a few times. "I can import it, why doesn't it work?!?" Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: Mystery... Faked Referrer Generates 500 Instead of 404 Error

2011-08-31 Thread Reinout van Rees
visitors to those specific pages that the page is gone (apache rewriterule, for instance, with a "410 GONE" response). Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure w

Re: Unable to have a template NOT show up

2011-08-31 Thread Reinout van Rees
think of right now: You mis-typed something in your urls.py. I'd expect there to be a "polls.view" in there instead of the customary "polls.views...", so with an 's'. The module is "views.py", not "view.py". Just guessing... Reinout --

Re: How to run tests?

2011-08-30 Thread Reinout van Rees
vip_mobile could not be found Try "manage.py test data". Django doesn't really like those dot-separated namespace packages, sadly. Only the last part is used. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-sch

Re: Unable To Delete Records

2011-08-30 Thread Reinout van Rees
the last item gets deleted. It bit my once, too. What you need to call is request.POST.getlist('del_id'): that will give you the list you're expecting. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ &quo

Re: App namespace/packages?

2011-08-30 Thread Reinout van Rees
, lizard_map, lizard_shape). The only reason for the dash/underscore difference is that it makes it easier to spot in which directory you are (the dash is the one with the setup.py, the underscore is the directory with the code within that outer-one-with-the-dash). Reinout -- Reinout

Re: Media files not served automatically anymore in 1.3?

2011-08-29 Thread Reinout van Rees
On 27-08-11 17:22, Karen Tracey wrote: On Thu, Aug 25, 2011 at 7:21 AM, Reinout van Rees <rein...@vanrees.org <mailto:rein...@vanrees.org>> wrote: Only, with this 1.3 change django's 1.2's automatic serving of the media_url stuff has gone the way of the dodo. Django 1

Re: django themes

2011-08-26 Thread Reinout van Rees
css/js with your application. Works like a charm. Look into that one first. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- Yo

Re: Media files not served automatically anymore in 1.3?

2011-08-25 Thread Reinout van Rees
On 25-08-11 12:08, Reinout van Rees wrote: Two questions: - "Breaking" automatic media_url serving seems worthy of a real note in the 1.3 changelog. That note isn't there. Is this bad? Or am I missing something? Yes, I am missing something... It turns out that django-staticf

Re: Media files not served automatically anymore in 1.3?

2011-08-25 Thread Reinout van Rees
. (This is not recommended!) Nope, that's not it. Staticfiles works fine with runserver and serves the static_url stuff just fine. Only, with this 1.3 change django's 1.2's automatic serving of the media_url stuff has gone the way of the dodo. Reinout -- Reinout van Reeshttp

Media files not served automatically anymore in 1.3?

2011-08-25 Thread Reinout van Rees
the 1.3 changelog. That note isn't there. Is this bad? Or am I missing something? - Serving static_url automatically but omitting media_url is a bit strange if you ask me. Is this a bug? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: Problems on using multiple databases

2011-08-24 Thread Reinout van Rees
the main default database by default. You'll have to call syncdb on the second database separately. Often the second database is an existing one that django shouldn't touch, that's why the default is that way. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein

Re: mod_wsgi cannot load MySQLdb

2011-08-24 Thread Reinout van Rees
ualenv dir in there, unless it is the /Users/jianbao/pylib at the end. I personally don't know how wsgi+virtualenv works together (I use buildout normally). so you'll have to ask around for that. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: Drag and drop functionality?

2011-08-24 Thread Reinout van Rees
don't know if that also works for items dragged from outside the browser window. But get step 1 working first. Step 2 will need that functionality in place to be able to do something :-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org

Re: Admin staticfiles stubbornly hiding behind 404s

2011-08-24 Thread Reinout van Rees
ll getting the right js/css out of the box. Handy! Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message becaus

Re: Error: cannot import name settings

2011-08-24 Thread Reinout van Rees
-- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Djan

Re: Problems on using multiple databases

2011-08-24 Thread Reinout van Rees
On 23-08-11 01:31, Jim wrote: django.db.utils.DatabaseError: no such table: django_content_type Which django version, btw? Early 1.2 beta versions had a bug: https://code.djangoproject.com/ticket/12999 Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein

Re: Admin staticfiles stubbornly hiding behind 404s

2011-08-24 Thread Reinout van Rees
# django-staticfiles: STATIC_URL = '/static_media/' Alias /static_media/ /path/to/your/collected/static/files/ Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do,

Re: Problems on using multiple databases

2011-08-24 Thread Reinout van Rees
ur special deatabase. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the G

Re: mod_wsgi cannot load MySQLdb

2011-08-24 Thread Reinout van Rees
sgi script for instance. Just some brainstorming. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this

Re: why can't I access a dictionary with an initial form field value from my django template?

2011-08-23 Thread Reinout van Rees
e first item. That's the basic problem. Best solution probably: just do the MYDICT[myform.somefield.value] in your view and pass the value to the template? Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ &quo

Re: Django 1.3 logging not working as I'd expect

2011-08-22 Thread Reinout van Rees
. Just as a simple test, put such a logging statement inside one of your view methods and hit it in your browser. Just to make sure your logging setup as such works. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen

Re: Django admin site and DEBUG flag.

2011-08-19 Thread Reinout van Rees
-- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups "Django users&

Re: Django admin site and DEBUG flag.

2011-08-19 Thread Reinout van Rees
DEBUG:" around where the admin site is mounted in your urls. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received

Re: problem with a graph image in template

2011-08-19 Thread Reinout van Rees
the 500 error text. Seeing the traceback ought to show you the problem. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- Yo

Re: Anyone use mod_security with Django?

2011-08-18 Thread Reinout van Rees
just fine ;-) Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http://www.nelen-schuurmans.nl/ "If you're not sure what to do, make something. -- Paul Graham" -- You received this message because you are subscribed to the Google Groups &

Re: Anyone use mod_security with Django?

2011-08-18 Thread Reinout van Rees
to gain knowledge on what mod_security actually does and how to configure it. Personally, I've never heard of anyone using it for Django and I'd be surprised if it is needed. Reinout -- Reinout van Reeshttp://reinout.vanrees.org/ rein...@vanrees.org http

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

2011-08-18 Thread Reinout van Rees
a 'dict' object instead of a real django request object. Do you have some middleware or so that does something to the request? Does your view modify the request, inadvertently modifying it into a dict? Just brainstorming about possible causes :-) Reinout -- Reinout van Rees

Re: problem with a grph image in template

2011-08-18 Thread Reinout van Rees
t;python syntax error". Perhaps there's a difference that your first example is a POST to that image? And means a GET request? by putting in the template a simple tag in the template That src attribute again doesn't seem to match your original url. Reinout -- Reinout van Rees

  1   2   >