Friday, May 31, 2013

Re: (error) tutorial 2: local admin page not working

Doesn't what you have posted tell you enough of what you need to do?



On 1 June 2013 00:20, Issam Laradji <issamou01@gmail.com> wrote:
After setting up the database using the command:

"python manage.py syncdb"

I ran "python manage.py runserver" to launch the server

But then when I try open the admin page " http://127.0.0.1:8000/admin/"

I keep getting this error,                  


Of course, you haven't actually done any work yet. Here's what to do next:

  • If you plan to use a database, edit the DATABASES setting in mysite/settings.py.
  • Start your first app by running python manage.py startapp [appname].

You're seeing this message because you have DEBUG = True in your Django settings file and you haven't configured any URLs. Get to work!



Thanks in advance...

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Django & Ember

Hello,

So I'm thinking about bundling together Django and Ember. The reason is my front end is going to be lots of data in realtime. Think like overlaying a map with information for an example. Lots of data needs to be handled on the front end. Things need to be extremely dynamic.

I love Django and the interface with the database and all that. I'm thinking a powerful solution might be tagging Django and Ember together. Has anyone done this? Anyone have any advice? My questions really are (like the questions on my mind are) like lets say I query the database and get this resulting queryset or list in a variable. In Django you hand that list off to the template. Like I'm not sure how to hand things back and forth between Django and Ember. How I would hand the result from the query to Ember aka JS and then display that to the front end.

Does this sound like a powerful solution for handling large amounts of data? Really any information would be wonderful, better than nothing for sure...

I need high performance and power for processing quickly and giving the users a seamless experience and I'm wondering if this might be the ticket?

Thanks so much,

JJ Zolper

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

SQL from Model ?

hi!
is possible generate the SQL ("create table/index/....") in hardcode?
example:
class Book(models.Model):
title = models.CharField(...)
price = models.DecimalField(...)
print django_generate_sql_model( Book ) # <--- here

?? anyway? idea?

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

(error) tutorial 2: local admin page not working

After setting up the database using the command:

"python manage.py syncdb"

I ran "python manage.py runserver" to launch the server

But then when I try open the admin page " http://127.0.0.1:8000/admin/"

I keep getting this error,                  


Of course, you haven't actually done any work yet. Here's what to do next:

  • If you plan to use a database, edit the DATABASES setting in mysite/settings.py.
  • Start your first app by running python manage.py startapp [appname].

You're seeing this message because you have DEBUG = True in your Django settings file and you haven't configured any URLs. Get to work!



Thanks in advance...

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: linux or windows

I don't count this as 'voluntary', except in the sense that I wasn't forced at the point of a gun, but I can say that it is possible to back a Django site with SQL Server. I do not recommend it, and the details vary based on which particular stack you are running.

My recommendations are: don't, if you don't have to; if you do, pay attention to your firewall, and do not blindly apply OS patches. Of course, the same can be said for any of the Unix flavors, but production Windows is substantially less pleasant to administer, in my experience, and the patch policy reflects limiting Microsoft's exposure to bad press, which is not the same thing as production sites' best interest.

This is my own opinion, I do not speak for anyone else.

-j

On May 31, 2013, at 6:27 AM, Javier Guerra Giraldez <javier@guerrag.com> wrote:

> On Fri, May 31, 2013 at 7:55 AM, Mike Dewhirst <miked@dewhirst.com.au> wrote:
>> I don't know of anyone voluntarily using Windows as a Django production
>> server platform.
>
>
> not sure if it counts as "voluntarily", but if you _have_ to use MS
> SQL Server, the DB client options on Linux aren't getting any better,
> so soon the best option will be to put the appserver on windows too.
>
> so it seems a very good reason to avoid MS SQL Server. it's sad,
> since that was by far the best server product from MS. Fortunately,
> the other big DBs (PostgeSQL, DB2, Oracle) count Linux frienship as a
> core strategy
>
>
> --
> Javier
>
> --
> You received this message because you are subscribed to the Google Groups "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: linux or windows

Same here. In a perfect world I'd develop on Mac and deploy to Linux, as compiling anything on Windows is a pain and the command prompt is a sorry excuse for a shell (yes, I could use cygwin, and do at times...). Can't use pip to install anything with a compile step. Once you have everything installed, it's not bad.

_Nik

On 5/31/2013 9:19 AM, Jason Arnst-Goodrich wrote:
I'd just like to chime in as another "develop on windows, deploy to linux" guys. It's worked fine for me for years. Like people have said, sometimes it's hard to get certain libraries for Windows installed but it's usually not to hard to find a packaged solution if you google (and in simple projects, pip install works for just about everything).


On Friday, May 31, 2013 4:11:23 AM UTC-7, Kakar wrote:
Hi!
I know this question is one absurd question, but just out of curiosity, is it important to use linux other than the windows, related to django. Cause i'm in windows, and if it is, then i was thinking to use Ubuntu. Please advise.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: Workshop: Don't Be Afraid to Commit, Cardiff, UK

On Fri, May 31, 2013, Rahul Ramesh <msg4rahul@gmail.com> wrote:

>I think what you're doing is really great. Do you have recorded videos
>available online or do you plan to record your next session? It'd be great
>for people like me who can't attend the workshop.

I don't think that a recording of it would work well, but the tutorial documentation <https://dont-be-afraid-to-commit.readthedocs.org/> should work just as well without me.

Everything in the workshop's in there, and I wrote it all step-by-step. You could try that. From the start the idea was that people should be able to use the document as an alternative to attending the workshop.

I'm on the #django irc channel on irc.freenode.net most of the time, as either EvilDMP or SuperDMP, so feel free to call on me for help if you need it.

Daniele

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: linux or windows

forgot to include a vagrant video how-to

http://www.youtube.com/watch?v=MiRMvB65U1Y

Best,

Phillip


On 31/05/13 21:53, phillip@bailey.st wrote:
> Hi Kakar,
>
> if you want to use Linux within Window, I strongly advise you to
> use Vagrant http://docs-v1.vagrantup.com/v1/docs/getting-started/
>
> Vagrant will bring up and running a Linux virtual server within minutes.
>
> Best,
>
> Phillip
>
>
> On 31/05/13 12:11, Kakar Arunachal Service wrote:
>> Hi!
>> I know this question is one absurd question, but just out of curiosity,
>> is it important to use linux other than the windows, related to django.
>> Cause i'm in windows, and if it is, then i was thinking to use Ubuntu.
>> Please advise.
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send
>> an email to django-users+unsubscribe@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at http://groups.google.com/group/django-users?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>
>


--
www.bailey.st

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: linux or windows

Hi Kakar,

if you want to use Linux within Window, I strongly advise you to
use Vagrant http://docs-v1.vagrantup.com/v1/docs/getting-started/

Vagrant will bring up and running a Linux virtual server within minutes.

Best,

Phillip


On 31/05/13 12:11, Kakar Arunachal Service wrote:
> Hi!
> I know this question is one absurd question, but just out of curiosity,
> is it important to use linux other than the windows, related to django.
> Cause i'm in windows, and if it is, then i was thinking to use Ubuntu.
> Please advise.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to django-users+unsubscribe@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>


--
www.bailey.st

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: django , python and ides

Sure thing :) I'll even give you the stuff that makes my prompt and all that:

$HOME/.bashrc (partial): http://collabedit.com/bnxfx

<virtualenv_path>/bin/postactivate: http://collabedit.com/6bvfr

$HOME/.screenrc-<project_name>: http://collabedit.com/kuj8d

Enjoy!

--
Joey "JoeLinux" Espinosa



On Fri, May 31, 2013 at 2:39 PM, Chris Lawlor <lawlor.chris@gmail.com> wrote:
Joey,

Would you be interested in sharing your virtualenvwrapper setup? I assume you're using some custom postactivate hooks, looks nice.

Chris


On Friday, 31 May 2013 14:23:23 UTC-4, JoeLinux wrote:

I've used both PyCharm and SublimeText extensively for months each at a time,

and I swap back and forth every now and then just to see how the other is doing.

PyCharm:

Pros vs Sublime:

- Everything in one package (almost)

- Debugging capabilities are excellent and built-in

-
Virtualenv support and library inspection

Sublime:

Pros vs PyCharm:

- Fast. Fast, fast, fast! Almost every shortcut/function/correction/refactoring/feature happens faster in Sublime than PyCharm (sometimes by orders of magnitude)

- Vintage (Sublime's Vim keymap) is WAY better than IdeaVIM (PyCharm's). Vim support is crucial for me.

- Fonts and colors and animations and basically anything your eyes can look at is ten times more pleasing to the eyes than in PyCharm (Java font rendering is laughably bad)


PyCharm cons:

- Slow

- If you quit/close/upgrade/kill while it's indexing, you'll screw it up and have to select "Invalidate Caches"

- Environment variables are not always handled correctly (this will really frustrate you sometimes), and you'll have to define them yourself, or toss them in your virtualenv's postactivate script

- Costs $99, with a $59 annual renewal fee


Sublime cons:

- You are responsible for your own environment (this means runserver, debugging, etc)

- Autocompletion does not always work the way you want it to (I've had snippets, Emmet, and CodeIntel conflict with each other many times)

- Costs $70 (though it's a one-time fee, compared to PyCharm... and you don't HAVE to pay to use it, as long as you ignore the occasional prompt)


One note about Sublime: the first "con" is a big one, because most people don't want to set up their development environment in pieces (I felt the same way at first). However, over time I've learned to love that very aspect, and I appreciate how everything works together better now. I am more content now to leave those programs that are good at something to do what they're good at, rather than let an IDE like PyCharm do it not-as-good (Mercurial support is virtually unusable, for instance). Instead, I've grabbed a few tips from around the web, come up with a few of my own, and now when I drop to the command line and type "workon <project_name>", I'll be greeted with a custom prompt, and a GNU Screen session with several open (and labeled) windows indicating to me what is available in each one (including a runserver, and a Python shell with my virtualenv/Django environment loaded and every installed app/model automatically imported). Looks something like this:


Inline image 1

(I blurred a few things out because I'm working on a project that isn't public yet)


The prompt shows me my user account and computer name, my current directory, and my current branch (works on both Mercurial and Git, so I don't have to do anything special depending on the scm tool I'm using). A little lightning bolt will show up next to the branch name to indicate that I have uncommitted changes, which is pretty cool. Also, it's multi-line, so I have the entire width of the terminal to work on.

The bottom bar is my "info bar". It has the name of the project on the left (or initials or whatever), then a list of windows and their names, my computer name, my system load, the date, and time.


So day-to-day, I now use SublimeText pretty much exclusively. Sometimes (rarely, but it does happen), I open up PyCharm, but usually only if I desperately need to debug Python variables in the middle of rendering a Django template. It's pretty good for that. Otherwise, Sublime is amazing.


Especially amazing if you watch this video in its entirety and learn about SublimeText thoroughly: http://www.youtube.com/watch?v=TZ-bgcJ6fQo

HTH

--
Joey "JoeLinux" Espinosa
Python Developer
http://about.me/joelinux

On May 31, 2013 1:23 PM, "Nikolas Stevenson-Molnar" <nik.m...@consbio.org> wrote:
+1 for PyCharm. I know many here like Sublime Text also (though it's a
super text editor, not an IDE). Neither are open source, but both work
hard to earn the $$ you spend on them.

_Nik

On 5/31/2013 7:19 AM, Masklinn wrote:
> On 2013-05-31, at 12:54 , tony gair wrote:
>> Python and Django are not my first languages and currently I am using it
>> like I would a compiled language inside gedit on debian wheezy. I was
>> actually quite surprised to find a lot of people using it on windows and
>> macs when I went to my local python user group but enough digression!.
>> I was wondering if anyone using debian wheezy can recommend a nice ide
>> (hopefully opensource but if not then relatively inexpenisive) for django
>> and python?
> PyCharm works very well, though it's not open-source. Inexpensive is
> more of a relative judgement, I've found it worth the price and
> jetbrains regularly does sales on their products. YMMV.
>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: django , python and ides

I use Aptana... Ninja its good too


2013/5/31 Ezequiel Bertti <ebertti@gmail.com>
+1 pycharm


On Fri, May 31, 2013 at 3:39 PM, Chris Lawlor <lawlor.chris@gmail.com> wrote:
Joey,

Would you be interested in sharing your virtualenvwrapper setup? I assume you're using some custom postactivate hooks, looks nice.

Chris


On Friday, 31 May 2013 14:23:23 UTC-4, JoeLinux wrote:

I've used both PyCharm and SublimeText extensively for months each at a time,

and I swap back and forth every now and then just to see how the other is doing.

PyCharm:

Pros vs Sublime:

- Everything in one package (almost)

- Debugging capabilities are excellent and built-in

-
Virtualenv support and library inspection

Sublime:

Pros vs PyCharm:

- Fast. Fast, fast, fast! Almost every shortcut/function/correction/refactoring/feature happens faster in Sublime than PyCharm (sometimes by orders of magnitude)

- Vintage (Sublime's Vim keymap) is WAY better than IdeaVIM (PyCharm's). Vim support is crucial for me.

- Fonts and colors and animations and basically anything your eyes can look at is ten times more pleasing to the eyes than in PyCharm (Java font rendering is laughably bad)


PyCharm cons:

- Slow

- If you quit/close/upgrade/kill while it's indexing, you'll screw it up and have to select "Invalidate Caches"

- Environment variables are not always handled correctly (this will really frustrate you sometimes), and you'll have to define them yourself, or toss them in your virtualenv's postactivate script

- Costs $99, with a $59 annual renewal fee


Sublime cons:

- You are responsible for your own environment (this means runserver, debugging, etc)

- Autocompletion does not always work the way you want it to (I've had snippets, Emmet, and CodeIntel conflict with each other many times)

- Costs $70 (though it's a one-time fee, compared to PyCharm... and you don't HAVE to pay to use it, as long as you ignore the occasional prompt)


One note about Sublime: the first "con" is a big one, because most people don't want to set up their development environment in pieces (I felt the same way at first). However, over time I've learned to love that very aspect, and I appreciate how everything works together better now. I am more content now to leave those programs that are good at something to do what they're good at, rather than let an IDE like PyCharm do it not-as-good (Mercurial support is virtually unusable, for instance). Instead, I've grabbed a few tips from around the web, come up with a few of my own, and now when I drop to the command line and type "workon <project_name>", I'll be greeted with a custom prompt, and a GNU Screen session with several open (and labeled) windows indicating to me what is available in each one (including a runserver, and a Python shell with my virtualenv/Django environment loaded and every installed app/model automatically imported). Looks something like this:


Inline image 1

(I blurred a few things out because I'm working on a project that isn't public yet)


The prompt shows me my user account and computer name, my current directory, and my current branch (works on both Mercurial and Git, so I don't have to do anything special depending on the scm tool I'm using). A little lightning bolt will show up next to the branch name to indicate that I have uncommitted changes, which is pretty cool. Also, it's multi-line, so I have the entire width of the terminal to work on.

The bottom bar is my "info bar". It has the name of the project on the left (or initials or whatever), then a list of windows and their names, my computer name, my system load, the date, and time.


So day-to-day, I now use SublimeText pretty much exclusively. Sometimes (rarely, but it does happen), I open up PyCharm, but usually only if I desperately need to debug Python variables in the middle of rendering a Django template. It's pretty good for that. Otherwise, Sublime is amazing.


Especially amazing if you watch this video in its entirety and learn about SublimeText thoroughly: http://www.youtube.com/watch?v=TZ-bgcJ6fQo

HTH

--
Joey "JoeLinux" Espinosa
Python Developer
http://about.me/joelinux

On May 31, 2013 1:23 PM, "Nikolas Stevenson-Molnar" <nik.m...@consbio.org> wrote:
+1 for PyCharm. I know many here like Sublime Text also (though it's a
super text editor, not an IDE). Neither are open source, but both work
hard to earn the $$ you spend on them.

_Nik

On 5/31/2013 7:19 AM, Masklinn wrote:
> On 2013-05-31, at 12:54 , tony gair wrote:
>> Python and Django are not my first languages and currently I am using it
>> like I would a compiled language inside gedit on debian wheezy. I was
>> actually quite surprised to find a lot of people using it on windows and
>> macs when I went to my local python user group but enough digression!.
>> I was wondering if anyone using debian wheezy can recommend a nice ide
>> (hopefully opensource but if not then relatively inexpenisive) for django
>> and python?
> PyCharm works very well, though it's not open-source. Inexpensive is
> more of a relative judgement, I've found it worth the price and
> jetbrains regularly does sales on their products. YMMV.
>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Ezequiel Bertti
E-Mail: ebertti@gmail.com
Cel: (21) 9188-4860

VÁ PARA BÚZIOS!!!
http://www.agh.com.br/
Ane Guest House

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Rafael E. Ferrero
Claro: (03562) 15514856

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: django , python and ides

+1 pycharm


On Fri, May 31, 2013 at 3:39 PM, Chris Lawlor <lawlor.chris@gmail.com> wrote:
Joey,

Would you be interested in sharing your virtualenvwrapper setup? I assume you're using some custom postactivate hooks, looks nice.

Chris


On Friday, 31 May 2013 14:23:23 UTC-4, JoeLinux wrote:

I've used both PyCharm and SublimeText extensively for months each at a time,

and I swap back and forth every now and then just to see how the other is doing.

PyCharm:

Pros vs Sublime:

- Everything in one package (almost)

- Debugging capabilities are excellent and built-in

-
Virtualenv support and library inspection

Sublime:

Pros vs PyCharm:

- Fast. Fast, fast, fast! Almost every shortcut/function/correction/refactoring/feature happens faster in Sublime than PyCharm (sometimes by orders of magnitude)

- Vintage (Sublime's Vim keymap) is WAY better than IdeaVIM (PyCharm's). Vim support is crucial for me.

- Fonts and colors and animations and basically anything your eyes can look at is ten times more pleasing to the eyes than in PyCharm (Java font rendering is laughably bad)


PyCharm cons:

- Slow

- If you quit/close/upgrade/kill while it's indexing, you'll screw it up and have to select "Invalidate Caches"

- Environment variables are not always handled correctly (this will really frustrate you sometimes), and you'll have to define them yourself, or toss them in your virtualenv's postactivate script

- Costs $99, with a $59 annual renewal fee


Sublime cons:

- You are responsible for your own environment (this means runserver, debugging, etc)

- Autocompletion does not always work the way you want it to (I've had snippets, Emmet, and CodeIntel conflict with each other many times)

- Costs $70 (though it's a one-time fee, compared to PyCharm... and you don't HAVE to pay to use it, as long as you ignore the occasional prompt)


One note about Sublime: the first "con" is a big one, because most people don't want to set up their development environment in pieces (I felt the same way at first). However, over time I've learned to love that very aspect, and I appreciate how everything works together better now. I am more content now to leave those programs that are good at something to do what they're good at, rather than let an IDE like PyCharm do it not-as-good (Mercurial support is virtually unusable, for instance). Instead, I've grabbed a few tips from around the web, come up with a few of my own, and now when I drop to the command line and type "workon <project_name>", I'll be greeted with a custom prompt, and a GNU Screen session with several open (and labeled) windows indicating to me what is available in each one (including a runserver, and a Python shell with my virtualenv/Django environment loaded and every installed app/model automatically imported). Looks something like this:


Inline image 1

(I blurred a few things out because I'm working on a project that isn't public yet)


The prompt shows me my user account and computer name, my current directory, and my current branch (works on both Mercurial and Git, so I don't have to do anything special depending on the scm tool I'm using). A little lightning bolt will show up next to the branch name to indicate that I have uncommitted changes, which is pretty cool. Also, it's multi-line, so I have the entire width of the terminal to work on.

The bottom bar is my "info bar". It has the name of the project on the left (or initials or whatever), then a list of windows and their names, my computer name, my system load, the date, and time.


So day-to-day, I now use SublimeText pretty much exclusively. Sometimes (rarely, but it does happen), I open up PyCharm, but usually only if I desperately need to debug Python variables in the middle of rendering a Django template. It's pretty good for that. Otherwise, Sublime is amazing.


Especially amazing if you watch this video in its entirety and learn about SublimeText thoroughly: http://www.youtube.com/watch?v=TZ-bgcJ6fQo

HTH

--
Joey "JoeLinux" Espinosa
Python Developer
http://about.me/joelinux

On May 31, 2013 1:23 PM, "Nikolas Stevenson-Molnar" <nik.m...@consbio.org> wrote:
+1 for PyCharm. I know many here like Sublime Text also (though it's a
super text editor, not an IDE). Neither are open source, but both work
hard to earn the $$ you spend on them.

_Nik

On 5/31/2013 7:19 AM, Masklinn wrote:
> On 2013-05-31, at 12:54 , tony gair wrote:
>> Python and Django are not my first languages and currently I am using it
>> like I would a compiled language inside gedit on debian wheezy. I was
>> actually quite surprised to find a lot of people using it on windows and
>> macs when I went to my local python user group but enough digression!.
>> I was wondering if anyone using debian wheezy can recommend a nice ide
>> (hopefully opensource but if not then relatively inexpenisive) for django
>> and python?
> PyCharm works very well, though it's not open-source. Inexpensive is
> more of a relative judgement, I've found it worth the price and
> jetbrains regularly does sales on their products. YMMV.
>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Ezequiel Bertti
E-Mail: ebertti@gmail.com
Cel: (21) 9188-4860

VÁ PARA BÚZIOS!!!
http://www.agh.com.br/
Ane Guest House

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: request_finished signal not being called with Django 1.5.1 with uwsgi

The problem is mainly that the current LTS of Ubuntu ships this ancient version of uwsgi via apt. So it's very easy to end up with a system that's not capable of running Django 1.5 properly (sysadmins seem to prefer apt over pip). Seems sensible to at least specify the minimum uWSGI version in the docs, kind of like the minimum python version.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: django , python and ides

Joey,

Would you be interested in sharing your virtualenvwrapper setup? I assume you're using some custom postactivate hooks, looks nice.

Chris

On Friday, 31 May 2013 14:23:23 UTC-4, JoeLinux wrote:

I've used both PyCharm and SublimeText extensively for months each at a time,

and I swap back and forth every now and then just to see how the other is doing.

PyCharm:

Pros vs Sublime:

- Everything in one package (almost)

- Debugging capabilities are excellent and built-in

-
Virtualenv support and library inspection

Sublime:

Pros vs PyCharm:

- Fast. Fast, fast, fast! Almost every shortcut/function/correction/refactoring/feature happens faster in Sublime than PyCharm (sometimes by orders of magnitude)

- Vintage (Sublime's Vim keymap) is WAY better than IdeaVIM (PyCharm's). Vim support is crucial for me.

- Fonts and colors and animations and basically anything your eyes can look at is ten times more pleasing to the eyes than in PyCharm (Java font rendering is laughably bad)


PyCharm cons:

- Slow

- If you quit/close/upgrade/kill while it's indexing, you'll screw it up and have to select "Invalidate Caches"

- Environment variables are not always handled correctly (this will really frustrate you sometimes), and you'll have to define them yourself, or toss them in your virtualenv's postactivate script

- Costs $99, with a $59 annual renewal fee


Sublime cons:

- You are responsible for your own environment (this means runserver, debugging, etc)

- Autocompletion does not always work the way you want it to (I've had snippets, Emmet, and CodeIntel conflict with each other many times)

- Costs $70 (though it's a one-time fee, compared to PyCharm... and you don't HAVE to pay to use it, as long as you ignore the occasional prompt)


One note about Sublime: the first "con" is a big one, because most people don't want to set up their development environment in pieces (I felt the same way at first). However, over time I've learned to love that very aspect, and I appreciate how everything works together better now. I am more content now to leave those programs that are good at something to do what they're good at, rather than let an IDE like PyCharm do it not-as-good (Mercurial support is virtually unusable, for instance). Instead, I've grabbed a few tips from around the web, come up with a few of my own, and now when I drop to the command line and type "workon <project_name>", I'll be greeted with a custom prompt, and a GNU Screen session with several open (and labeled) windows indicating to me what is available in each one (including a runserver, and a Python shell with my virtualenv/Django environment loaded and every installed app/model automatically imported). Looks something like this:


Inline image 1

(I blurred a few things out because I'm working on a project that isn't public yet)


The prompt shows me my user account and computer name, my current directory, and my current branch (works on both Mercurial and Git, so I don't have to do anything special depending on the scm tool I'm using). A little lightning bolt will show up next to the branch name to indicate that I have uncommitted changes, which is pretty cool. Also, it's multi-line, so I have the entire width of the terminal to work on.

The bottom bar is my "info bar". It has the name of the project on the left (or initials or whatever), then a list of windows and their names, my computer name, my system load, the date, and time.


So day-to-day, I now use SublimeText pretty much exclusively. Sometimes (rarely, but it does happen), I open up PyCharm, but usually only if I desperately need to debug Python variables in the middle of rendering a Django template. It's pretty good for that. Otherwise, Sublime is amazing.


Especially amazing if you watch this video in its entirety and learn about SublimeText thoroughly: http://www.youtube.com/watch?v=TZ-bgcJ6fQo

HTH

--
Joey "JoeLinux" Espinosa
Python Developer
http://about.me/joelinux

On May 31, 2013 1:23 PM, "Nikolas Stevenson-Molnar" <nik.m...@consbio.org> wrote:
+1 for PyCharm. I know many here like Sublime Text also (though it's a
super text editor, not an IDE). Neither are open source, but both work
hard to earn the $$ you spend on them.

_Nik

On 5/31/2013 7:19 AM, Masklinn wrote:
> On 2013-05-31, at 12:54 , tony gair wrote:
>> Python and Django are not my first languages and currently I am using it
>> like I would a compiled language inside gedit on debian wheezy. I was
>> actually quite surprised to find a lot of people using it on windows and
>> macs when I went to my local python user group but enough digression!.
>> I was wondering if anyone using debian wheezy can recommend a nice ide
>> (hopefully opensource but if not then relatively inexpenisive) for django
>> and python?
> PyCharm works very well, though it's not open-source. Inexpensive is
> more of a relative judgement, I've found it worth the price and
> jetbrains regularly does sales on their products. YMMV.
>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Developing Django Apps - best practices?

All,

I'd like to get some feedback from the community on the current best practices for developing standalone Django apps. To clarify, by 'standalone' I mean a codebase that is just the application itself, to be installed into a Django project via setup.py / pip, not working on the app directly within a Django project. It seems that people love to discuss ideas related to projects (layout, settings, etc.), but I haven't seen much discussion focusing on app development.

For example, do you have some boilerplate that you use when starting a new app? For projects, we have project templates, but as far as I'm aware there is no particular application boilerplate that is in wide use.

Here are some other questions you might consider:

* How do you organize tests? Do you include a test project?

* How do you link your standalone apps to your current projects? Install via pip, add the app src directory to your PYTHONPATH, something else?

* What tools / libraries / other resources do you find most useful?

There is some documentation on the topic here (https://docs.djangoproject.com/en/dev/intro/reusable-apps/), which is a great start, but it glosses over deployment and completely ignores testing.

My goal here is simply to start a discussion. Hopefully, if some general consensus emerges, we might identify some ideas that could possibly be documented elsewhere, whether we inspire a blog post or add to the Django documentation itself.

Thank you,

Chris

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: linux or windows

Django itself is completely platform agnostic. Years ago I used to develop on Windows, and typically where I would run into problems was trying to find binaries for third party libraries like PIL and psycopg2. They'd usually be available from somewhere or another, thanks to some kindhearted soul who managed to build them and shared the binaries online, just difficult to track down. Building from source is certainly possible, but setting up the correct toolchain for a successful build is a non-trivial endeavor. This may have improved in the last few years though, I couldn't say.

Also (and this isn't directly related), the awesome virtualenvwrapper, which is a core part of my workflow nowadays, is not available in Windows, Virtualenv itself does work on Windows though.

Personally, I think it is best to develop on a system as close to your production environment as possible. It's certainly possible to develop on Windows, and deploy to Linux (or vice-versa), but you increase your risk of encountering bugs that only occur on one platform, which can be difficult to troubleshoot.

On Friday, 31 May 2013 07:11:23 UTC-4, Kakar wrote:
Hi!
I know this question is one absurd question, but just out of curiosity, is it important to use linux other than the windows, related to django. Cause i'm in windows, and if it is, then i was thinking to use Ubuntu. Please advise.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Developer for help on a project

Hi Django-users,

I'm looking for an experienced django-dev to help me out on my first django-project.  It's a 1.5 w/ custom user model, facebook and google+ integration, and a REST API for passing messages between users on native phone apps.  Nothing too crazy.

Thus far it is mostly "working" and the models are laid out, with some workflows complete end-to-end, but I keep running into django-newbie problems and need to get this baby out the door.  So I'm looking for someone to help.

Code is on GitHub.  PM or email me your hourly rates and availability and we'll chat.

Thanks!
-Eric

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: problem with extending django registration form



On Thursday, May 30, 2013 2:08:46 PM UTC+1, Tundebabzy wrote:
Hi,
Have you been able to sort out this issue?
Why don't you create your own backend and shoe horn it into
django-registration. You'll need to implement register, activate,
registration_allowed, get_form_class, post_registration_redirect and
post_activation_redirect methods (as needed) though.

Sent from my Windows Phone

-----Original Message-----
From: Okorie Emmanuel
Sent: 5/21/2013 3:04 PM
To: django...@googlegroups.com
Subject: problem with extending django registration form

hi

I have tried extending django registration page with little progress.
I can now add new user from the admin but cannot do that on the
front end. the problem is that the url does not display the from,
but raises exception, "the page cannot be found". Do I need to create a view.py
to be able to use  django registration app?

here is my code

http://pastebin.com/JBa8J1ry

is there anything i have not



thanks tundebabzy for your reply

I have not solved the problem
The issue is that i don't understand how to implement the backend like you suggest
can you give me a clue on this. thanks
 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: request_finished signal not being called with Django 1.5.1 with uwsgi

> I've created a ticket https://code.djangoproject.com/ticket/20537
>
> Not sure if this can be fixed in Django or a stern warning in the
> documentation can suffice.


Honestly (i am the main uWSGI author) whoever is using a uWSGI version <
1.2.6 should be worried by dozens more things (no more support, no more
security updates, known bugs, basically broken newrelic support, broken
threads and i do not even know what scary things you can find in it ...)

We are talking about a package of 2 years ago... and this specific problem
is caused by a (serious) bug in ancient uWSGI releases with WSGI specs, so
why django should bother ?


--
Roberto De Ioris
http://unbit.it

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Re: request_finished signal not being called with Django 1.5.1 with uwsgi

I've created a ticket https://code.djangoproject.com/ticket/20537

Not sure if this can be fixed in Django or a stern warning in the documentation can suffice.

Op donderdag 30 mei 2013 17:15:29 UTC+2 schreef ja...@eight.nl het volgende:
I'm being hit by the same issue. I don't really understand why it worked with older versions of Django though? That seems to be a bug.

Op vrijdag 12 april 2013 01:28:42 UTC+2 schreef Lewis Sobotkiewicz het volgende:
So figured it out.

Apparently Ubuntu 12.04 packages uwsgi 1.0.3 in their apt repository, which doesn't support calling close() on the WSGI application object returned by Django. I had installed that uWsgi version, then installed a more up-to-date version with pip. ie.

pip install uwsgi==1.4.4

Subsequently, running uwsgi from the command line gives the later version:

$ uwsgi --version
1.4.4

However, when starting uwsgi with /etc/init.d/uwsgi, it was using Ubuntu's older, pre-packaged version. I assumed that pip would overwrite that version. Silly me. Fixed by editing /etc/init.d/uwsgi to point DAEMON=/usr/bin/uwsgi to the version installed by pip.

On Wednesday, April 10, 2013 4:55:51 PM UTC-7, Lewis Sobotkiewicz wrote:
Hi there,

I'm noticing some strange behaviour with Django 1.5.1 and uwsgi - The builtin signal django.core.signals.request_finished isn't being triggered. I've tried various versions of uwsgi, and they all have the same behaviour.

Also, when I downgrade to Django 1.4.5, the normal behaviour resumes.

Any idea why this might be happening? It's causing my DB connections to remain open after a request.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: Multiple Users Logged into a page at the same time

You could also use middleware instead of the view code to do the same thing. That way you wouldn't have to put that code in every view

On Friday, May 31, 2013 10:06:00 AM UTC-5, C. Kirby wrote:
Just going of the top of my head here:
Create a model like:

class OnPage(Model):
     user = foreignkey(User)
     page = TextField()

In each of your  your views do something like:

     op, created OnPage.objects.get_or_create(user = request.user)
     op.page = thispage (The view name, the url, you can decide how to grab this)

You would also want an ajax call that triggers when the browser window is closed, running a view that does:
     try:
         OnPage.objects.get(user = request.user).delete()
     else:
         pass

On Friday, May 31, 2013 8:40:33 AM UTC-5, Alan wrote:
Hi,

For a site that I am building, I want multiple users to be able to log in to a page at the same time. Something with the experience being very similar to what we have in Google Docs where I can see the users who are currently logged into and are active on the page. 

I'd want to be able to display all the active users on a page.

How do I go about building this in my Django-based website?

Help and suggestions would be appreciated. Thanks. :)

Thanks,
Alan

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Re: Multiple Users Logged into a page at the same time

Just going of the top of my head here:
Create a model like:

class OnPage(Model):
     user = foreignkey(User)
     page = TextField()

In each of your  your views do something like:

     op, created OnPage.objects.get_or_create(user = request.user)
     op.page = thispage (The view name, the url, you can decide how to grab this)

You would also want an ajax call that triggers when the browser window is closed, running a view that does:
     try:
         OnPage.objects.get(user = request.user).delete()
     else:
         pass

On Friday, May 31, 2013 8:40:33 AM UTC-5, Alan wrote:
Hi,

For a site that I am building, I want multiple users to be able to log in to a page at the same time. Something with the experience being very similar to what we have in Google Docs where I can see the users who are currently logged into and are active on the page. 

I'd want to be able to display all the active users on a page.

How do I go about building this in my Django-based website?

Help and suggestions would be appreciated. Thanks. :)

Thanks,
Alan

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.