Advice needed: Adaptive/Responsive Images in Django?

2014-11-19 Thread ThomasTheDjangoFan
Hi guys, do you have a tip for implementing adaptive (responsive) images in django? Basically I want to server smaller images to mobile-users and bigger images to desktop users. I don't really now about best practices for SEO and Siteload-Performance. Are there any apps that you can recon for t

Re: ImportError: cannot import name 'GEOSException'

2014-11-19 Thread jogaserbia
Thanks for the help Carl. Also, thanks for filing the ticket. Every bit of info helps. I really do like Python and Django so far. I am just wondering whether I should just quit trying to make GeoDjango work on my windows machine (at work). I will be setting up a linux machine at home in t

Re: ImportError: cannot import name 'GEOSException'

2014-11-19 Thread Carl Meyer
Hi Ivan, On 11/19/2014 02:58 PM, jogaserbia wrote: > Hi Carl, > > Thanks very much for the response. > > I am trying to get GeoDjango up and running (for a couple of days now) > and am having a really hard time. Sorry about that :/ I know the dependencies for GeoDjango can be hard to set up

Re: ImportError: cannot import name 'GEOSException'

2014-11-19 Thread jogaserbia
Hi Carl, Thanks very much for the response. I am trying to get GeoDjango up and running (for a couple of days now) and am having a really hard time. I came across another question on the internet (that does not specifically have to do with my issue) that suggested putting this path variabl

Re: ImportError: cannot import name 'GEOSException'

2014-11-19 Thread Carl Meyer
Hello, On 11/18/2014 09:53 AM, jogaserbia wrote: > I just realized something. > > > This are all the files in django.contrib.gis.geos: > > Notice there is no GEOSException, nor is there GEOSGeometry. There is > however geometry.py (which as the class GEOSGeometry in it) and error.py >

Re: Deploying Django project

2014-11-19 Thread termopro
Thank you for your reply Daniel. On Wednesday, November 19, 2014 9:07:31 PM UTC+2, Daniel Roseman wrote: > > On Wednesday, 19 November 2014 10:22:25 UTC, termopro wrote: >> >> I have created a Django 1.7 project and would like to deploy it. I am >> reading about how to do it right and i have so

Re: Deploying Django project

2014-11-19 Thread Daniel Roseman
On Wednesday, 19 November 2014 10:22:25 UTC, termopro wrote: > > I have created a Django 1.7 project and would like to deploy it. I am > reading about how to do it right and i have some questions. > > If i understand correctly deployment should contain the following steps: > > 1) Initial remote ma

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Daniel Grace
> > > But based on your traceback, it seems like at some point in the past > when you made a migration, the field might have had a default value > which was a naive datetime. Is that possible? > > It might be necessary to look through your existing migrations for this > app to find the culprit

Re: Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
Progress: I moved the Polymer code tree to my static directory and replaced the URL with designer This at least lets me load the designer. Now on to see if I can build ajax calls to class based views or maybe there is another way? Cheers, Tim On Wed, Nov 19, 2014 at 1:59 PM, Timothy W. Coo

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Carl Meyer
Hi Daniel, On 11/19/2014 08:58 AM, Daniel Grace wrote: > On Wednesday, 19 November 2014 15:11:27 UTC, Carl Meyer wrote: > On 11/19/2014 08:07 AM, Daniel Grace wrote: > > I have already installed pytz (2014.17) and I have set > USE_TZ=True. I > > don't use any naive datetimes in my

Re: Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
Maybe I bit off too much to start. IT looks like this may be a better place to start. http://themikelewis.com/2014/10/01/django-and-polymer-the-basics-and-vulcanizing/ ... and not running the Django development server. On Wed, Nov 19, 2014 at 12:18 PM, Timothy W. Cook wrote: > > On Wed, Nov

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Daniel Grace
On Wednesday, 19 November 2014 15:11:27 UTC, Carl Meyer wrote: > > Hi Daniel, > > On 11/19/2014 08:07 AM, Daniel Grace wrote: > > I have already installed pytz (2014.17) and I have set USE_TZ=True. I > > don't use any naive datetimes in my application. This error is caused > > by something th

Re: Warning / Error when testing with W flag

2014-11-19 Thread Carl Meyer
Hi Daniel, On 11/18/2014 02:01 AM, Daniel Grace wrote: > Hi, > I get another warning / error with a test command as follows: >>python -W error manage.py test flow > Traceback (most recent call last): > File "manage.py", line 8, in > from django.core.management import execute_from_command_li

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Carl Meyer
Hi Daniel, On 11/19/2014 08:07 AM, Daniel Grace wrote: > I have already installed pytz (2014.17) and I have set USE_TZ=True. I > don't use any naive datetimes in my application. This error is caused > by something that the Django test command is doing automatically, if you > look at the tracebac

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Daniel Grace
I have already installed pytz (2014.17) and I have set USE_TZ=True. I don't use any naive datetimes in my application. This error is caused by something that the Django test command is doing automatically, if you look at the traceback you will see that it is something to do with migrations.

Re: What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Russell Keith-Magee
Hi Daniel, A naïve datetime is a datetime that doesn't have a timezone. If you have USE_TZ=True enabled in your settings file (which is the default for new projects), Django expects you to fully specify datetime objects with a timezone; if you don't, you get the warning you've seen, because the da

Re: Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
On Wed, Nov 19, 2014 at 12:10 PM, Avraham Serour wrote: > the line you posted is not a call to any template, it translates to a url > address given the view name. > > the top line means that the staticfiles module is loaded, you need that in > order to use it in the template below, my question is

Re: Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
What I am looking for is not necessarily an answer, since there is probably very few people that have tried this. I am hoping that someone can give me an idea 'how to troubleshoot' this issue. How do I break this down into steps to even see what is happening? Since platform.js and designer-eleme

Re: Webcomponents in Django

2014-11-19 Thread Avraham Serour
the line you posted is not a call to any template, it translates to a url address given the view name. the top line means that the staticfiles module is loaded, you need that in order to use it in the template below, my question is if you actually use it, how do you point to the js file for exampl

Re: Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
At the top of the both the main file where designer is called from and at the top of designer.html I have: {% load staticfiles i18n %} The call to the designer template is in a list with other calls that work fine: designer Thanks, Tim On Wed, Nov 19, 2014 at 10:54 AM, Avraham Serour wrote:

Re: Webcomponents in Django

2014-11-19 Thread Avraham Serour
looks like the html rendered is making the recursive requests, are you using {% static %} and {% url 'designer' %} ? On Wed, Nov 19, 2014 at 1:53 PM, Timothy W. Cook wrote: > > I have a Django app that I want to include a UI similar to the Polymer > designer https://www.polymer-project.org/tools

What on earth is causing this "naive datetime" warning?

2014-11-19 Thread Daniel Grace
Hi, Here is my model: class Flow(models.Model): ref = models.CharField(max_length=32) state = models.ForeignKey(State) flow_type = models.ForeignKey(Type) created = models.DateTimeField(db_index=True, auto_now_add=True) modified = models.DateTimeField(db_index=True, auto_now=Tr

Tricky Django QuerySet with Complicated ForeignKey Traversals

2014-11-19 Thread Rodney Lewis
Please check out my question on StackOverflow: http://stackoverflow.com/questions/27016026/tricky-django-queryset-with-complicated-foreignkey-traversals I really appreciate any help you can offer. -- Rodney Lewis http://www.youtube.com/pyrodney -- You received this message because you are sub

Webcomponents in Django

2014-11-19 Thread Timothy W. Cook
I have a Django app that I want to include a UI similar to the Polymer designer https://www.polymer-project.org/tools/designer/ Source code here: https://github.com/twcook/TdV-app-designer/tree/tdv plus the components installed via bower. I have built this designer as a standalone app and it wo

Re: Squid or Varnish for Django?

2014-11-19 Thread Avraham Serour
what do you mean by ESI? wikipedia has 7 definitions onlyon computer science In any case you can build you django application normally and scale in the future as needed. squid and varnish have different purposes and work on opposites sides of the pipe, varnish sits on the server side serving the

Re: FieldDoesNotExist Error in Tutorial Part 1

2014-11-19 Thread Adailton Nascimento
Use: import datetime class Question(models.Model): question_text = models.CharField(max_length=200) pub_date = models.DateTimeField(auto_now=True) class Meta: ordering = ['-pub_date'] def __str__(self): return self.question_text delete all objects of your pas

Deploying Django project

2014-11-19 Thread termopro
I have created a Django 1.7 project and would like to deploy it. I am reading about how to do it right and i have some questions. If i understand correctly deployment should contain the following steps: 1) Initial remote machine set up: - a) install os / server / database / cache ... -

ANN: eGenix mxODBC Connect 2.1.1 - Python Database Interface

2014-11-19 Thread eGenix Team: M.-A. Lemburg
ANNOUNCING eGenix.com mxODBC Connect Python Database Interface Version 2.1.1 mxODBC Connect is our commercially supported client-server product for