Re: Starting a new Python blog

2012-01-30 Thread Kevin
@Aaron, good suggestion, I'll definitely look into it for a future update, if only Twitter supported RSS feeds. @Kate, yes I have considered changing the style of the site. I had no idea the template would be so awkward when I first tested it. Now that there's content, the styling really hurts n

Creating a hierarchy of objects in my api.py

2012-01-30 Thread St@n
Hello, I am playing around with tastypie and i want to create a hierarchy of data. What i currently have is this: class keywordResource(ModelResource): tweets = fields.ToManyField(timelineResource, 'tweets', full=True) class Meta: queryset = Keyword.objects.all() resourc

Proper way of building model classes in app using 2 databases

2012-01-30 Thread Piotr Wierzgała
Hi, I'm writting an app which uses 2 databases and I'm wondering how I should build model classes for tables from second database (which I only use to read data). I have a models.py module in my app's package where I defined all the model classes I needed. I also defined there model classes from

Re: admin list_filter: limit choices to model values?

2012-01-30 Thread JHeasly
In 1.4/trunk, looks like filterspec.py gets replaced by filters.py (as part of adding the ability to filter a list_filter), so we'll just sit tight and wait for 1.4 to be released (rather than have to go back and remove the defunct filterspec code). — John -- You received this message becaus

Re: I need help with Python Tools for Visual Studio 2010 and Django

2012-01-30 Thread JJ Zolper
I have never heard of Guess Additions thanks for the tip! Right now I am going to remove my Ubuntu installation and re-install to give it more RAM and Video memory as well as install guest Additions! Thanks, JJ -- You received this message because you are subscribed to the Google Groups "Dja

Re: Routing to database based on user

2012-01-30 Thread akaariai
I forgot one thing: be cautious with transactions. The transaction middleware will start a transaction only on 'default' alias. So, you will probably need to use the transactions.commint_on_success / commit_manually with the using parameter to make this work reliably. Or write your own transaction

Re: Routing to database based on user

2012-01-30 Thread akaariai
On Jan 31, 12:01 am, Tom Eastman wrote: > Hey guys, > > I'm writing a django project that will require me to route queries to > certain large databases based on who the logged in user is. > > So all the tables for django.contrib.auth and session and stuff will be > in the 'central' database, as we

Routing to database based on user

2012-01-30 Thread Tom Eastman
Hey guys, I'm writing a django project that will require me to route queries to certain large databases based on who the logged in user is. So all the tables for django.contrib.auth and session and stuff will be in the 'central' database, as well as a table that maps users to which database they

Re: Django Admin completely empty

2012-01-30 Thread darwin_tech
hmmm. I am the superuser, but I went ahead and tried the createuser command to make another. Still the same in the admin. No models or user/privilege options. The strange thing is there are boxes where you would expect apps/models top be, but they are totally empty. Any other suggestions? Sam On

Re: Django Deploy - Some Questions regarding it

2012-01-30 Thread akaariai
I don't know much about nginx, but here are some pointers: First, this page seems good source of information: https://code.djangoproject.com/wiki/DjangoAndNginx Now, take note of the "location /site_media" directive in the above link. This is basically telling the server that when there is a requ

Re: Django Admin completely empty

2012-01-30 Thread Andres Reyes
Do you have permissions on the models you want to see? You can create a new superuser with python manage.py createsuperuser 2012/1/30 darwin_tech : > Hi, > > On my development server my Django Admin works as expected, showing > all my > models and the auth models. However, on the production ser

Re: Print list with select related with reverse foreign key

2012-01-30 Thread akaariai
On Jan 29, 6:23 pm, Gabriel Carneiro Novaes wrote: > I have two modelshttp://paste.ideaslabs.com/show/BN0e2z4NSa > > I want to print a list of ads (title,slug, and thumb_photo) > > How can I make this list, since the key is reverse? > > Something like this SQL:http://paste.ideaslabs.com/show/Iw8ii

Re: Question regarding ticket #17062

2012-01-30 Thread akaariai
On Jan 30, 11:21 am, Ashe wrote: > Hello, > > I have been using django 1.3.1 for some months. > I had a long time bug and I finally took some hours to track it. > Sometimes in my admin interface (not the default django one), all the > query based on datetime object have a very strange behavior. >

Full Time Developer Position - NYC - Django

2012-01-30 Thread Michael Scovetta
Hi! We'd like to hire an experienced developer to work on a few major projects: - Mobile development (iOS, Android, Boxee, NeoTV, XBOX, GoogleTV...) - Django / MySQL / Redis - jQueryMobile - Phonegap, Titanium, etc. Looking for someone who wants to work in a "startup" inside a very large m

Re: Question regarding ticket #17062

2012-01-30 Thread Ashe
On Jan 30, 4:54 am, Ramiro Morales wrote: > On Mon, Jan 30, 2012 at 6:21 AM, Ashe wrote: > > Could you help me make this modification working in the 1.3.1 ? I > > looked at the file modified in the changeset 17128, but it looks like > > it changed a lot between the release and this changeset. >

Django Caching appended character issue

2012-01-30 Thread bfrederi
I've noticed that occasionally XML files that we create and server through Django get a character appended onto the file when Django caching is turned on. If I restart memcached on the remote server, the appended character (in the last case I saw, it was a "W") disappears and the XML file appears n

Re: django-db-log import Exception

2012-01-30 Thread Timothy Makobu
Naa, looks too bloaty for me. I'll just write midleware and do the logging inside process_exception() On Mon, Jan 30, 2012 at 7:45 PM, Babatunde Akinyanmi wrote: > Hi Tim, > Django-db-log is no longer maintained. Its like its not compatible > with 1.3. Use django-sentry instead. > > On 1/30/12, T

Re: Hosting Alwaysdata: install dajax libraries

2012-01-30 Thread Praveen Krishna R
*You can always copy the source folder of the dajax or whatever app into your project folder.* * * On Mon, Jan 30, 2012 at 7:19 PM, ElDoge wrote: > Hi, I am a newbie of Django and I have to try a web application (not > made by me, but founded in the web) that manages the shifts rounds of > the v

Re: Hosting Alwaysdata: install dajax libraries

2012-01-30 Thread Babatunde Akinyanmi
Alwaysdata allows you to install your own apps. Alwaysdata also IMHO the best customer support available. First search the forum at http://forum.alwaysdata.com and if you don't get the instructions there, log in to your admin account (http://admin.alwaysdata.com), click on support and then raise a

Re: django-db-log import Exception

2012-01-30 Thread Babatunde Akinyanmi
Hi Tim, Django-db-log is no longer maintained. Its like its not compatible with 1.3. Use django-sentry instead. On 1/30/12, Timothy Makobu wrote: > right. > > Hi guys. If someone could kindly alert the dev? I emailed him already > but no response yet. Pip needs to pick up the fixed dangodbl

Hosting Alwaysdata: install dajax libraries

2012-01-30 Thread ElDoge
Hi, I am a newbie of Django and I have to try a web application (not made by me, but founded in the web) that manages the shifts rounds of the volunteers of my association. I installaed it into alwaysdata.com free hosting, but the web app need the dajax and dajaxice library. It is possible to ins

Additional fields in Django-Registration

2012-01-30 Thread Zach
Hi, I have been trying to add first_name and last_name to django registration but I can't get the information to save. It appears on the form but something isn't right. I have been looking at different solutions online but for some reason it is not working. Please help. Thank you! My post on S

Re: django-db-log import Exception

2012-01-30 Thread Timothy Makobu
right. Hi guys. If someone could kindly alert the dev? I emailed him already but no response yet. Pip needs to pick up the fixed dangodblog as a dep where the app is hosted. It's all automated. On Mon, Jan 30, 2012 at 6:45 PM, Babatunde Akinyanmi wrote: > Oh I see. I was reading djangodbl

Re: django-db-log import Exception

2012-01-30 Thread Babatunde Akinyanmi
Oh I see. I was reading djangodblog as django-dblog instead of django-db-log so I was thinking djangodblog was a directory you created yourself. As long as Paginator remains on that line there's no way to go forward. If I was you, I'd try to go through the source and figure out if Paginator should

Re: django-db-log import Exception

2012-01-30 Thread Timothy Makobu
This is how Paginator is imported https://docs.djangoproject.com/en/dev/topics/pagination/ from django.core.paginator import Paginator (this is part of django.core on my 1.3, so doesn't need installing) This is how djangodblog is trying to import it: from django.contrib.admin.views.main import

Re: Starting a new Python blog

2012-01-30 Thread wC
Agree with Katie. Also make bookmarks open in a new tab. Nice anyway Gr -- 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-us

Django Admin completely empty

2012-01-30 Thread darwin_tech
Hi, On my development server my Django Admin works as expected, showing all my models and the auth models. However, on the production server, even though the whole application works fine, when I log into the admin I see nothing. No models, no auth. Just a stack of empty boxes. If anyone has any id

Re: Is it possible to return an HttpResponse in django with text & a json object?

2012-01-30 Thread darwin_tech
I blogged about this quite recently: http://djangosteps.wordpress.com/2012/01/12/filtered-menus-in-django/ Hope this helps, Sam On Jan 30, 1:13 am, lokesh wrote: > To do this use serializers or you need to make it a plain text iterate > over objects and make it a string and return httprespons

Re: Django models

2012-01-30 Thread Stanwin Siow
ok got it. I read the document and it was good stuff. Just got confused with copying pasting into my models.py. Thanks alot once again. :) Best Regards, Stanwin Siow On Jan 30, 2012, at 10:02 PM, Michael Elkins wrote: > On Mon, Jan 30, 2012 at 09:53:18PM +0800, Stanwin Siow wrote: >> but o

Re: Django models

2012-01-30 Thread Michael Elkins
On Mon, Jan 30, 2012 at 09:53:18PM +0800, Stanwin Siow wrote: but once my terminal creates the model classes do i have to copy it into my app's model.py? yes, you will need to copy the output to your models.py. you may need to edit it to put the models in order so that dependencies like for

Re: Starting a new Python blog

2012-01-30 Thread Katie Cunningham
Have you considered changing the styling of your site? It's a bit awkward to look at, since it looks like it was only made to fit on a much smaller screen. Perhaps you could look at Bootstrap, which is a much more flexible CSS framework? Katie On Mon, Jan 30, 2012 at 8:45 AM, Aaron Cannon wrote:

Re: django-db-log import Exception

2012-01-30 Thread Babatunde Akinyanmi
**scratching head** So are you saying you have paginator installed already? Cos your traceback says you have a admin.py file in a djangodblog directory and that file is trying to import paginator which it can't find. That's the root of the error being thrown On 1/30/12, Timothy Makobu wrote: > It

Re: Django models

2012-01-30 Thread Stanwin Siow
sorry to bother you again michael but once my terminal creates the model classes do i have to copy it into my app's model.py? I wanted to be sure. Best Regards, Stanwin Siow On Jan 30, 2012, at 9:35 PM, Michael Elkins wrote: > On Mon, Jan 30, 2012 at 09:26:10PM +0800, Stanwin Siow wrote:

Re: Starting a new Python blog

2012-01-30 Thread Aaron Cannon
For me, Twitter is the new RSS. Any chance of setting up a feed for new content notifications? Thanks. Aaron On 1/30/12, Kevin wrote: > It is good to see some subscribers this early on. Thank you. I have > rolled out the updates for Tutorials and set the foundation for the > Review system by

Re: django-db-log import Exception

2012-01-30 Thread Timothy Makobu
It's trying to import it from django.contrib.admin.views.main On Mon, Jan 30, 2012 at 4:29 PM, Babatunde Akinyanmi wrote: > Seems like the app depends on paginator. Why not install the paginator app? > > > On 1/30/12, Timothy Makobu wrote: > > Hi all, > > > > I'm on Django 1.3 > > > > I just no

Re: Django models

2012-01-30 Thread Stanwin Siow
Thank you so much. This information is very useful. It work like a charm for me. Thank you once again mike. Cheers Best Regards, Stanwin Siow On Jan 30, 2012, at 9:35 PM, Michael Elkins wrote: > On Mon, Jan 30, 2012 at 09:26:10PM +0800, Stanwin Siow wrote: >> However what does this error sa

Re: Django models

2012-01-30 Thread Michael Elkins
On Mon, Jan 30, 2012 at 09:26:10PM +0800, Stanwin Siow wrote: However what does this error say? ImportError: Settings cannot be imported, because environment variable DJANGO_SETTINGS_MODULE is undefined. If you have a manage.py for your project, you can just run "manage.py inspectdb" and it

Re: django-db-log import Exception

2012-01-30 Thread Babatunde Akinyanmi
Seems like the app depends on paginator. Why not install the paginator app? On 1/30/12, Timothy Makobu wrote: > Hi all, > > I'm on Django 1.3 > > I just now installed django-db-log via pip, but after adding it to > installed_apps, I get this Exception: > > Traceback (most recent call last): >

Re: Django models

2012-01-30 Thread Stanwin Siow
hi michael, Thanks for the tip. It is a huge step in my progress. However what does this error say? ImportError: Settings cannot be imported, because environment variable DJANGO_SETTINGS_MODULE is undefined. Best Regards, Stanwin Siow On Jan 30, 2012, at 8:37 PM, Michael Elkins wrote: > O

Re: Question regarding ticket #17062

2012-01-30 Thread Ramiro Morales
On Mon, Jan 30, 2012 at 6:21 AM, Ashe wrote: > Could you help me make this modification working in the 1.3.1 ? I > looked at the file modified in the changeset 17128, but it looks like > it changed a lot between the release and this changeset. Are you sure?. I've just tried and this is what I've

Re: Django model problem

2012-01-30 Thread Michael Elkins
On Sun, Jan 29, 2012 at 08:22:40PM -0800, St@n wrote: I am trying to create a RESTful API with a django website i have running. The project folder is called rosebud and inside the folder r2 lies my application. I have tried to retrieve objects by calling the Users table in django's default authe

Re: Django models

2012-01-30 Thread Michael Elkins
On Mon, Jan 30, 2012 at 04:13:50AM -0800, St@n wrote: How do i ask django to query for a table that is already created in the database but not part of the models.py? the models.py is used to described the database and to create tables with that models.py. However i already have my tables created

Django models

2012-01-30 Thread St@n
Hello, How do i ask django to query for a table that is already created in the database but not part of the models.py? the models.py is used to described the database and to create tables with that models.py. However i already have my tables created prior to creating the django app. How then do

Question regarding ticket #17062

2012-01-30 Thread Ashe
Hello, I have been using django 1.3.1 for some months. I had a long time bug and I finally took some hours to track it. Sometimes in my admin interface (not the default django one), all the query based on datetime object have a very strange behavior. After some research, I ended up with the conclu

Django model problem

2012-01-30 Thread St@n
Hi there, I am trying to create a RESTful API with a django website i have running. The project folder is called rosebud and inside the folder r2 lies my application. I have tried to retrieve objects by calling the Users table in django's default authentication model. But i have problems retriev

django-db-log import Exception

2012-01-30 Thread Timothy Makobu
Hi all, I'm on Django 1.3 I just now installed django-db-log via pip, but after adding it to installed_apps, I get this Exception: Traceback (most recent call last): File "/bundles/port-8233/app_image/epio_wsgi.py", line 32, in __call__ output = wsgi_entrypoint(environ, self.start_response

Re: superuser unable to delete an object

2012-01-30 Thread kenneth gonsalves
On Mon, 2012-01-30 at 12:39 +0530, kenneth gonsalves wrote: > def has_delete_permission(self, request, obj=None): > # Same as change permission > self.has_change_permission(request, obj=obj) > > when I login as superuser and try to delete a child object I get a 403 > forbidden erro

Re: I need help with Python Tools for Visual Studio 2010 and Django

2012-01-30 Thread Sam Lai
On 29 January 2012 16:49, JJ Zolper wrote: > Sam, > > I have set up VirtualBox with Python and Django. Things have gone > flawlessly. > > Only thing I've noticed is it seems to be running a tad bit slow. I feel > this way because I had a native installation before and it ran quite well. Have you

Re: Tutorial for dev version not working (Polls app): admin

2012-01-30 Thread Ramiro Morales
On Sun, Jan 29, 2012 at 12:15 AM, Alec Taylor wrote: > > Going through the tutorial using the latest trunk in a virtualenv. > > I am getting stuck in this section: > https://docs.djangoproject.com/en/dev/intro/tutorial02/#s-customize-the-admin-form > > No matter how I rearrange the fields (even wh