Our new startup site build on Django and GAE is now live!

2011-06-02 Thread maverick
We build a pretty cool website LOCQL (www.LOCQL.com) purely on Django and run on GAE has just went live! I would say development with Django is purely enjoyable experience, however the Google Apps Engine does bring us some headache esp. we are a location based service, the geo-location related sea

Re: Is there an HTML editor that's Django-aware

2011-06-02 Thread Derek
On May 31, 3:26 pm, Tom Evans wrote: > On Mon, May 30, 2011 at 2:41 PM, Jacob Kaplan-Moss wrote: > > On Monday, May 30, 2011, BobX wrote: > >> If anyone from the Django Project itself is listening then can I (very > >> humbly) suggest that some editor recommendations would make a real > >> fine

Re: adding objects via admin section from ipad/iphone

2011-06-02 Thread i...@webbricks.co.uk
i think that approach is a little advanced for me, im not sure where id start! why would he need reeducating? Matt On Jun 1, 4:39 pm, Tom Evans wrote: > On Wed, Jun 1, 2011 at 4:07 PM, i...@webbricks.co.uk > > > > > > wrote: > > i wonder if anyone has any suggestions around this issue. > > > I

Cleaned Data Different Access?

2011-06-02 Thread Daniel Roseman
What makes you think that? .get() is a dictionary method. It's just useful when you're not sure the specific key exists, which is the case in the general clean() method. -- DR. -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this disc

Re: Our new startup site build on Django and GAE is now live!

2011-06-02 Thread Tom Evans
On Thu, Jun 2, 2011 at 8:02 AM, maverick wrote: > We build a pretty cool website LOCQL (www.LOCQL.com) purely on Django > and run on GAE has just went live! > > I would say development with Django is purely enjoyable experience, > however the Google Apps Engine does bring us some headache esp. we

Re: adding objects via admin section from ipad/iphone

2011-06-02 Thread Tom Evans
On Thu, Jun 2, 2011 at 9:06 AM, i...@webbricks.co.uk wrote: > i think that approach is a little advanced for me, im not sure where > id start! > > why would he need reeducating? > > Matt > Converting a wordpress web service call into the equivalent action for your own CMS sounds a lot simpler to

Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Kann
Dear all, In order to run django on the server, I need to specify the file containing all the configuration and export it as a system variable called "DJANGO_SETTINGS_MODULE". Also, the documentation on django project website also stated that the value of DJANGO_SETTINGS_MODULE should be in "Pytho

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Oscar Carballal
You can import "setting_new.py" from "settings.py", that way you still only need to stablish settings.py as the DJANGO_SETTINGS_MODULE. It's strange though, the development server of django (python manage.py runserver) should import automatically the settings module and add it to the python path.

Internationalization in Django.

2011-06-02 Thread Anand Agarwal
Hi All we are trying to translate our website in french. Django has a good framework for internationalization. Only problem is django model translation. Is there a good way to handle django model translation, without inserting new columns in data table? problem with inserting new column is everyt

Re: Internationalization in Django.

2011-06-02 Thread Kenneth Gonsalves
On Thu, 2011-06-02 at 16:46 +0530, Anand Agarwal wrote: > problem with inserting new column is everytime you add support for new > language, you need to insert one more column, which is messy. there is no other way afaik -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugc

Re: How to create user on mobile app for Django site?

2011-06-02 Thread Malcolm Box
On 31 May 2011, at 12:35, Ivo Brodien wrote: > What is the correct way to do the following: > > 1) Mobile App from which a user can create a user/profile on the Django site > 2) Allow authenticated users to create on the site and query personalized > data from the site > > This is what I guess

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Kann
> You can import "setting_new.py" from "settings.py", that way you still > only need to stablish settings.py as the DJANGO_SETTINGS_MODULE. Yep, but what if I just want to load all configurations from the entirely new file. What should be the proper value for me to give to the DJANGO_SETTINGS_MO

Re: Disable debug logging for django.db.backends?

2011-06-02 Thread Malcolm Box
Alternatively, configure your logging handlers to send the db logging somewhere else (ie another file), and not to pass it on. So in settings.py have: LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'handlers': { 'file_logging': { 'level' : 'DEBUG',

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Oscar Carballal
2011/6/2 Kann : > Yep, but what if I just want to load all configurations from the > entirely new file. What should be the proper value for me to give to > the DJANGO_SETTINGS_MODULE? Take a look to https://docs.djangoproject.com/en/dev/topics/settings/ You can load the new settings via "runserv

Re: Odp: Re: signals pre_save vs model's save()

2011-06-02 Thread Malcolm Box
On 29 May 2011, at 15:53, Mateusz Harasymczuk wrote: > W dniu niedziela, 29 maja 2011, 15:36:13 UTC+2 użytkownik Malcolm Box napisał: > On 28 May 2011 11:05, Mateusz Harasymczuk wrote: > I am thinking about splitting my model's save() method over few signals. > > For example, stripping spaces an

Aw: Internationalization in Django.

2011-06-02 Thread Martin Brochhaus
There are dozens of approaches for this: http://djangopackages.com/grids/g/model-translation/ Most of them are old, not documented, outdated, abandonned or just slow. The newest player in this field is django-nani and I would recommend you to give it a try! Best regards, Martin -- You receive

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Kann
Thanks Oscar, I read the page already, but am still not totally understood. The page said the value of DJANGO_SETTINGS_MODULE should be "Python path syntax", e.g. mysite.settings. What exactly is "Python path syntax"? Would it be ok if I just provide the value as a file name? Perhaps, "new_setting

Template - counter for if loop

2011-06-02 Thread jai_python
I need to show the heading only one time when forloop executed along with if-loop; example: - data.html -- {% for val in data %} {% ifnotequal val 2 %} My Heading {{val}} {% endifnotequal %} {% endfor %} Input data=[1,2,3,4,5,2,6] Ex

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Kirill Spitsin
On Thu, Jun 02, 2011 at 05:29:01AM -0700, Kann wrote: > Thanks Oscar, I read the page already, but am still not totally > understood. The page said the value of DJANGO_SETTINGS_MODULE should > be "Python path syntax", e.g. mysite.settings. What exactly is > "Python path syntax"? Would it be ok if

Re: Confusion about DJANGO_SETTINGS_MODULE

2011-06-02 Thread Kenneth Gonsalves
On Thu, 2011-06-02 at 05:29 -0700, Kann wrote: > Thanks Oscar, I read the page already, but am still not totally > understood. The page said the value of DJANGO_SETTINGS_MODULE should > be "Python path syntax", e.g. mysite.settings. What exactly is > "Python path syntax"? Would it be ok if I just

Re: Template - counter for if loop

2011-06-02 Thread Tim Shaffer
I think you might want the heading outside the loop: My Heading {% for val in data %} {% ifnotequal val 2 %} {{val}} {% endifnotequal %} {% endfor %} -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discus

Re: Django 1.3 docs PDF

2011-06-02 Thread Andre Terra
I'm going to repeat myself and say +1 on having links to 'official' PDFs available somewhere in djangoproject.com. Sincerely, André Terra On Thu, Jun 2, 2011 at 1:07 AM, Oscar Carballal wrote: > Didn't know that django had a page on readthedocs.org. But even when > the RTD API generates the sa

howto remove request.GET parameter

2011-06-02 Thread ozgur yilmaz
Hi, I have a custom templatetag function like this: @register.filter(name='rem_get_request') def rem_get_request(getrequest,name): req = getrequest.copy() for get_item in name.split('&'): if get_item in req and req[get_item]: get_item = get

Circular import on every backend except sqlite

2011-06-02 Thread Gloria W
I am experiencing this: https://code.djangoproject.com/ticket/16136 and the only way I can prevent it is by using sqlite. Does anyone have a patch for this, or more info? Thank you in advance, Gloria -- You received this message because you are subscribed to the Google Groups "Django users" grou

Re: Circular import on every backend except sqlite

2011-06-02 Thread Tom Evans
On Thu, Jun 2, 2011 at 12:44 PM, Gloria W wrote: > I am experiencing this: > https://code.djangoproject.com/ticket/16136 > and the only way I can prevent it is by using sqlite. > Does anyone have a patch for this, or more info? > Thank you in advance, > Gloria > WFM, + everyone else. Reinstall dj

Re: howto remove request.GET parameter

2011-06-02 Thread ozgur yilmaz
I realized that, there's nothing wrong with the removing code. The problem is the return statement. when the dictionary req is empty the def returns u"" and somehow old request.GET remains unchanged. So i should return a specific value, when the dictionary req is null. 2011/6/2 ozgur yilmaz : > Hi

Re: save out a test database?

2011-06-02 Thread Margie Roginski
Karen Tracy, if you are reading this, could you comment? As the person that seems to be most knowledgable about django testing (your Django 1.1 Testing book is fantastic - I highly recommend it!), can you confirm that something like this is the best way to go? It seems strange to me that there is

DjangoCon US 2011: Call for Tutorial Proposals

2011-06-02 Thread Steve Holden
The DjangoCon US team is looking at running half-day tutorials for the first time this year. We are therefore seeking proposals from well-qualified speakers who would like to present tutorials on Monday, September 5. This year we anticipate running at most four tutorials, though that number may be

Question about using imports within functions/methods

2011-06-02 Thread Cal Leeming [Simplicity Media Ltd]
Hey guys, This is more of a python question, than a Django specific one, but it's been bugging me for years now lol. I'm trying to figure out if it is better to do imports at the top of the file, or within the function/methods themselves. I guess the questions I'm asking are: - Is there any

Re: Question about using imports within functions/methods

2011-06-02 Thread Brian Bouterse
Yes relative imports are explicitly discouraged in PEP 8. Look for the imports section. I do not recommend importing at runtime which is what you are doing when you put imports inside function/methods. There are performance problems when calling imports

Re: Question about using imports within functions/methods

2011-06-02 Thread Tom Evans
On Thu, Jun 2, 2011 at 3:39 PM, Cal Leeming [Simplicity Media Ltd] wrote: > Hey guys, > > This is more of a python question, than a Django specific one, but it's been > bugging me for years now lol. > > I'm trying to figure out if it is better to do imports at the top of the > file, or within the

Re: Question about using imports within functions/methods

2011-06-02 Thread Matías Aguirre
Imports are cached by python that way things get imported only the first time. Try this simple test, create a file a.py with this content: print "Importing a.py" Then create b.py with this other content: import a Then create c.py with this other content: def x(): import a

django apps

2011-06-02 Thread podio
Hi, where can i found django apps for learning, i'm trying to make the management of a club, list of partners and collect monthly fees, I have something make but I need lots of corrections List only RelationshipInline if the afiliado model have tipo_estitu = True. Export the list in every adm

Re: Question about using imports within functions/methods

2011-06-02 Thread Cal Leeming [Simplicity Media Ltd]
Thanks to Tom / Matias / Brian for taking the time to reply, and for providing some good links, this was *exactly* what I needed. In regards to circular import issues, this is pretty much the main reason I've put imports inside function/method before, and I agree that most of the time it can be re

Re: Cleaned Data Different Access?

2011-06-02 Thread Robin
Daniel, I'm afraid it's just inexperience / ignorance that makes me think that I was no longer dealing with a dictionary. I saw get() and went to the model in my mind. I looked at the source code for the forms module and it didn't seem that it was all of a sudden not a dictionary, and your respon

Re: Question about using imports within functions/methods

2011-06-02 Thread Shawn Milochik
On 06/02/2011 11:09 AM, Cal Leeming [Simplicity Media Ltd] wrote: Pretty shameful that after almost 6 years of (fairly advanced) Python coding, I still finding myself not knowing some of the basic 101 stuff.. Slightly off topic but, does anyone else have that issue when coding? (i.e. doing re

Re: mod_wsgi on cPanel/WHM gets easier

2011-06-02 Thread Nan
Man, wish I had something like that a couple years ago. Please keep us posted on further developments! On Jun 1, 12:08 pm, shacker wrote: > If you run a cPanel/WHM server, and have manually compiled mod_wsgi in > the past, you know that updating apache/php for the rest of  your > server is a pa

Re: Django 1.3 docs PDF

2011-06-02 Thread tech tech
Oscar - thanks so much for this. Just a few hours ago, I was frantically trying to download the django site offline in preparation for two overnight train journeys from Bombay to Himachal Pradesh. The internet is spotty at best whilst on the train, and it is non-existent in the mountains of Himach

Re: Question about using imports within functions/methods

2011-06-02 Thread Cal Leeming [Simplicity Media Ltd]
On Thu, Jun 2, 2011 at 4:46 PM, Shawn Milochik wrote: > On 06/02/2011 11:09 AM, Cal Leeming [Simplicity Media Ltd] wrote: > >> >> Pretty shameful that after almost 6 years of (fairly advanced) Python >> coding, I still finding myself not knowing some of the basic 101 stuff.. >> Slightly off topic

Reasons to use managers

2011-06-02 Thread Amit Sethi
Hi all , I have a situation in which i am contemplating using an extra field although the same thing can be done using a manager(although the function may take some time). In this situation normalization isn't actually a priority. Are there some other reasons to use a manager. Also what would be th

Re: Seeking a Django 1.3 and syslog configuration example

2011-06-02 Thread Matteius
# Configure Project Logging using Django Logging setting and specifying # Dict-Config to Python 1.6 LOGGING = { 'version': 1, 'formatters': { 'simple': { 'format': '%(asctime)s %(levelname)s %(module)s [%(name)s] - %(message)s \n', }, 'verbose': {

Re: Our new startup site build on Django and GAE is now live!

2011-06-02 Thread Matteius
Yes I would appreciate a more integrated login approach or standard accounts. Facebook login is possible without having to give you access to post to my wall. Very restrictive in the current phase, but looks interesting underneath the login request. -Matteius On Jun 2, 4:05 am, Tom Evans wrote

DEBUG=False issue

2011-06-02 Thread Bobby Roberts
hey - i've got a weird issue with a django app. The app runs great on both the front end and in the /admin section when DEBUG=True in my settings.py file. However, whenever I set DEBUG=False in the settings file so that i get tracebacks by email, the entire /admin section 404s. Any idea what co

Re: DEBUG=False issue

2011-06-02 Thread Casey Greene
You are probably registering your models for the admin section in models.py instead of an admin.py file. This works in DEBUG where all of the models files but not when DEBUG is off. https://docs.djangoproject.com/en/dev/ref/contrib/admin/#modeladmin-objects Hope this helps, Casey On 06/02/20

Re: Our new startup site build on Django and GAE is now live!

2011-06-02 Thread Cal Leeming [Simplicity Media Ltd]
+1 On Thu, Jun 2, 2011 at 6:53 PM, Matteius wrote: > Yes I would appreciate a more integrated login approach or standard > accounts. Facebook login is possible without having to give you > access to post to my wall. Very restrictive in the current phase, but > looks interesting underneath the

Best CSS/JS compressor?

2011-06-02 Thread Mike
What is everyone using to combine CSS/JS? Has anyone tried mod_pagespeed? Perhaps Django-Compressor? All the discussions I found were quite dated. Thanks -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to dja

Re: Best CSS/JS compressor?

2011-06-02 Thread Maksymus007
we use yui for both js and css. but we have it a bit different,i mean we use django tag for including files and some script that compress and join files and both share the same naming algorithm. Pozdrawiam, Maksymilian Pawlak 02-06-2011 21:08 użytkownik "Mike" napisał: > What is everyone using to

debug=false issue

2011-06-02 Thread Bobby Roberts
hey - i've got a weird issue with a django app. The app runs great on both the front end and in the /admin section when DEBUG=True in my settings.py file. However, whenever I set DEBUG=False in the settings file so that i get tracebacks by email, the entire /admin section 404s. Any idea what co

Re: How to create user on mobile app for Django site?

2011-06-02 Thread Ivo Brodien
Hey Malcom, thanks for the answer. Glad, I was more or less on right way. >> How would I authenticate against the Django site? > > Your choices are either to use username/passwords or OAuth. If you're using > username/passwords you can hook straight into the standard Django > authentication -

Odp: Re: Odp: Re: signals pre_save vs model's save()

2011-06-02 Thread Mateusz Harasymczuk
That was a very good and convincing post :} I am testing a solution with .clean(), which IMHO is a better place to clean data before save() -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://group

Re: How to create user on mobile app for Django site?

2011-06-02 Thread Eric Chamberlain
On May 31, 2011, at 4:35 AM, Ivo Brodien wrote: > What is the correct way to do the following: > > 1) Mobile App from which a user can create a user/profile on the Django site > 2) Allow authenticated users to create on the site and query personalized > data from the site > > This is what I gu

Re: How to create user on mobile app for Django site?

2011-06-02 Thread Alex Kamedov
On Fri, Jun 3, 2011 at 5:05 AM, Eric Chamberlain wrote: > Currently, we are looking at tastypie, piston is currently bogged down with > a who will maintain it and where debate. > > I have some expirience with piston about the half year ago. It isn't allow to use difrent field sets of the same mod

Pre-deployment steps for Django apps?

2011-06-02 Thread shantp
Hi all, I am almost ready to make my app live. I am curious what steps you all take while getting your app ready to deploy. Other than setting DEBUG=False, what steps do you take with your app? Any reusable apps you add? Are there extra things I need to do for security? I'm not asking for depl

Aw: Reasons to use managers

2011-06-02 Thread Martin Brochhaus
>From the documentation: Adding extra Manager methods is the preferred way to add "table-level" functionality to your models. (For "row-level" functionality -- i.e., functions that act on a single instance of a model object -- use *Model methods*

Aw: Best CSS/JS compressor?

2011-06-02 Thread Martin Brochhaus
I'm using django_compressor and I am very happy with it! Best regards, Martin -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/eUlxYkp0NXdEQkVK. To post to

Re: Our new startup site build on Django and GAE is now live!

2011-06-02 Thread Gath
Great stuff!! Thumbs up. I like the concept! Please share you knowledge on how you did the Django/GAE integration. Gath On Jun 2, 10:02 am, maverick wrote: > We build a pretty cool website LOCQL (www.LOCQL.com) purely on Django > and run on GAE has just went live! > > I would say development w

django on cgi virtualenv

2011-06-02 Thread Mariano DAngelo
I'm trying to put my site in my hosting. I'm using awardspace: I create a virtualenv with the necesary packets but installing mysqldb I'm getting the error: Traceback (most recent call last): File "setup.py", line 15, in ? metadata, options = get_config() File "/home/www/MySQL-python-1.2.

Re: Our new startup site build on Django and GAE is now live!

2011-06-02 Thread CareerDhaba tech
Cool looking site, but it would be useful to allow people to browse the site a bit before having to register. On Fri, Jun 3, 2011 at 9:45 AM, Gath wrote: > Great stuff!! Thumbs up. > > I like the concept! > > Please share you knowledge on how you did the Django/GAE integration. > > Gath > > On J

Re: Best CSS/JS compressor?

2011-06-02 Thread Anoop Thomas Mathew
On 3 June 2011 00:01, Mike wrote: > What is everyone using to combine CSS/JS? > > Has anyone tried mod_pagespeed? Perhaps Django-Compressor? > Hi, +1 for django-compressor. Its very easy to use, and it servers its purpose well... There is a django-compress , but I found compressor more "deve

Re: Reasons to use managers

2011-06-02 Thread Amit Sethi
> functionality to your models. (For "row-level" functionality -- i.e., > functions that act on a single instance of a model object -- use Model > methods, not custom Manager methods.) > But what is the benefit of model methods compared to adding an extra field and getting almost the same thing do