Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #95240 > unrolled thread

Re: Is Django the way to go for a newbie?

Started byMichael Torrie <torriem@gmail.com>
First post2015-08-10 21:29 -0600
Last post2015-08-14 11:44 +1000
Articles 7 — 4 participants

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Is Django the way to go for a newbie? Michael Torrie <torriem@gmail.com> - 2015-08-10 21:29 -0600
    Re: Is Django the way to go for a newbie? Rustom Mody <rustompmody@gmail.com> - 2015-08-10 21:08 -0700
      Re: Is Django the way to go for a newbie? Michael Torrie <torriem@gmail.com> - 2015-08-13 19:05 -0600
        Re: Is Django the way to go for a newbie? Rustom Mody <rustompmody@gmail.com> - 2015-08-13 18:30 -0700
          Re: Is Django the way to go for a newbie? Michael Torrie <torriem@gmail.com> - 2015-08-13 21:10 -0600
          Re: Is Django the way to go for a newbie? Laura Creighton <lac@openend.se> - 2015-08-14 06:23 +0200
      Re: Is Django the way to go for a newbie? Chris Angelico <rosuav@gmail.com> - 2015-08-14 11:44 +1000

#95240 — Re: Is Django the way to go for a newbie?

FromMichael Torrie <torriem@gmail.com>
Date2015-08-10 21:29 -0600
SubjectRe: Is Django the way to go for a newbie?
Message-ID<mailman.60.1439263774.3627.python-list@python.org>
On 08/10/2015 07:49 PM, Dwight GoldWinde wrote:
> Thank you, Gary, for this new information.
> 
> I will be looking into virtualenv and vertualenvwrapper.
> 
> I thought that Django was an IDE. But, it seems that an IDE is one more
> thing that I need that I didn¹t know I needed!?

Django is a programming _library_ (also called a framework) that makes
web development easier/possible in Python (well it's some tools as well
as a library).  Basically check out the introductory documents at their
website:  https://www.djangoproject.com/start/

Depending on your definition of IDE, many Python programmers and Django
developers don't use an IDE at all, but just a nice programmer's text
editor.  Many people enjoy using the commercial Sublime Text editor.
Personally I use ViM.

An IDE could be useful for doing web development in Django, with code
completion as Django has many sub libraries and lots of APIs to
remember.  Do a search for Python IDEs.  Some are free, some are not.

[toc] | [next] | [standalone]


#95243

FromRustom Mody <rustompmody@gmail.com>
Date2015-08-10 21:08 -0700
Message-ID<6f2dc159-146b-44b8-b72e-fa34c4dc43cf@googlegroups.com>
In reply to#95240
On Tuesday, August 11, 2015 at 8:59:47 AM UTC+5:30, Michael Torrie wrote:
> On 08/10/2015 07:49 PM, Dwight GoldWinde wrote:
> > Thank you, Gary, for this new information.
> > 
> > I will be looking into virtualenv and vertualenvwrapper.
> > 
> > I thought that Django was an IDE. But, it seems that an IDE is one more
> > thing that I need that I didn¹t know I needed!?
> 
> Django is a programming _library_ (also called a framework)

Please dont conflate library and framework.
Library, framework, DSL are different approaches for solving similar problems.
I personally tend to prefer DSL's, dislike frameworks and am neutral to libraries.
Which is why I would tend to start with flask + template-language + ORM
rather than start with a framework.
Others may have for very good reasons different preferences and that is fine¹.

But if you say equate all these, discussion becomes a mess.
-----------------
¹ html + js + css is a good example of how/why the DSL approach can lead to a mess. Curl shows a better way https://en.wikipedia.org/wiki/Curl_%28programming_language%29 aside from the politics

[toc] | [prev] | [next] | [standalone]


#95362

FromMichael Torrie <torriem@gmail.com>
Date2015-08-13 19:05 -0600
Message-ID<mailman.181.1439514315.3627.python-list@python.org>
In reply to#95243
On 08/10/2015 10:08 PM, Rustom Mody wrote:
> On Tuesday, August 11, 2015 at 8:59:47 AM UTC+5:30, Michael Torrie wrote:
>> On 08/10/2015 07:49 PM, Dwight GoldWinde wrote:
>>> Thank you, Gary, for this new information.
>>>
>>> I will be looking into virtualenv and vertualenvwrapper.
>>>
>>> I thought that Django was an IDE. But, it seems that an IDE is one more
>>> thing that I need that I didn¹t know I needed!?
>>
>> Django is a programming _library_ (also called a framework)
> 
> Please dont conflate library and framework.
> Library, framework, DSL are different approaches for solving similar problems.
> I personally tend to prefer DSL's, dislike frameworks and am neutral to libraries.
> Which is why I would tend to start with flask + template-language + ORM
> rather than start with a framework.
> Others may have for very good reasons different preferences and that is fine¹.
> 
> But if you say equate all these, discussion becomes a mess.

Ahh. Well at least you didn't rail on me for being too lazy to
capitalize acronyms like html.

Given that until recently he thought Django was an IDE, I think calling
Django a library is fair, as it describes to him how it relates to
Python.  You download it and install it and it goes in site-packages
along with all the other libraries you might install.  Of course it
comes with utilities as well (which I mentioned).  Making the
distinctions you are making, in this context, is probably ultimately
going to be confusing to him at this stage of the game.  As he gets
familiar with django I don't think he'll find this original
simplification confusing, nor has it seemed to make this discussion a mess.

As to the DSL, I'm not quite sure which part of django you're getting
at.  Are you referring to the (optional) templating system?

[toc] | [prev] | [next] | [standalone]


#95363

FromRustom Mody <rustompmody@gmail.com>
Date2015-08-13 18:30 -0700
Message-ID<a54382b5-d3e4-400e-ab64-dd60c191072a@googlegroups.com>
In reply to#95362
On Friday, August 14, 2015 at 6:35:27 AM UTC+5:30, Michael Torrie wrote:
> On 08/10/2015 10:08 PM, Rustom Mody wrote:
> > On Tuesday, August 11, 2015 at 8:59:47 AM UTC+5:30, Michael Torrie wrote:
> >> On 08/10/2015 07:49 PM, Dwight GoldWinde wrote:
> >>> Thank you, Gary, for this new information.
> >>>
> >>> I will be looking into virtualenv and vertualenvwrapper.
> >>>
> >>> I thought that Django was an IDE. But, it seems that an IDE is one more
> >>> thing that I need that I didn¹t know I needed!?
> >>
> >> Django is a programming _library_ (also called a framework)
> > 
> > Please dont conflate library and framework.
> > Library, framework, DSL are different approaches for solving similar problems.
> > I personally tend to prefer DSL's, dislike frameworks and am neutral to libraries.
> > Which is why I would tend to start with flask + template-language + ORM
> > rather than start with a framework.
> > Others may have for very good reasons different preferences and that is fine¹.
> > 
> > But if you say equate all these, discussion becomes a mess.
> 
> Ahh. Well at least you didn't rail on me for being too lazy to
> capitalize acronyms like html.

No I am not trolling :-)

> 
> Given that until recently he thought Django was an IDE, I think calling
> Django a library is fair, as it describes to him how it relates to
> Python.  You download it and install it and it goes in site-packages
> along with all the other libraries you might install.  Of course it
> comes with utilities as well (which I mentioned).  Making the
> distinctions you are making, in this context, is probably ultimately
> going to be confusing to him at this stage of the game.  As he gets
> familiar with django I don't think he'll find this original
> simplification confusing, nor has it seemed to make this discussion a mess.
> 

True.
Purposive, directed lying is usually better pedagogy than legalistic correctness.

> As to the DSL, I'm not quite sure which part of django you're getting
> at.  Are you referring to the (optional) templating system?

Nothing specifically Django I am getting at.
Just that learning
- a templating engine -- eg Cheetah, Mako
- an ORM eg SQLAlchemy
- etc

is more fun than learning to chant the right mantras that a framework
demands without any clue of what/why/how

<admission>
I dont know Django. Used RoR some years ago and it was frightening.
And Ruby is not bad. So I assume Rails is.
I just assumed -- maybe ignorantly -- that Django and RoR are generically
similar systems
</admission>

[toc] | [prev] | [next] | [standalone]


#95369

FromMichael Torrie <torriem@gmail.com>
Date2015-08-13 21:10 -0600
Message-ID<mailman.2.1439521847.4764.python-list@python.org>
In reply to#95363
On 08/13/2015 07:30 PM, Rustom Mody wrote:
> Nothing specifically Django I am getting at.
> Just that learning
> - a templating engine -- eg Cheetah, Mako
> - an ORM eg SQLAlchemy
> - etc
> 
> is more fun than learning to chant the right mantras that a framework
> demands without any clue of what/why/how

Indeed.  It's this very thing that you speak of that makes web
development very discouraging to me because it does demand knowledge of
quite a few separate but interconnected domains and their specific
languages.  In my original post I had forgotten to mention ORM, though I
did mention SQL.  Adding abstraction in theory makes things easier.  In
practice it's often kind of like the old saying about solving a problem
using regular expressions.

[toc] | [prev] | [next] | [standalone]


#95370

FromLaura Creighton <lac@openend.se>
Date2015-08-14 06:23 +0200
Message-ID<mailman.4.1439526228.4764.python-list@python.org>
In reply to#95363
In a message of Thu, 13 Aug 2015 18:30:17 -0700, Rustom Mody writes:
><admission>
>I dont know Django. Used RoR some years ago and it was frightening.
>And Ruby is not bad. So I assume Rails is.
>I just assumed -- maybe ignorantly -- that Django and RoR are generically
>similar systems
></admission>

It's web2py that is the Python web framework that was inspired and
influenced by RoR.  And they are about as different as can be and
still both be Full Stack Frameworks, to the extent that most people
(at least all the ones I know) who really like one framework also
really dislike the other.

Laura

[toc] | [prev] | [next] | [standalone]


#95364

FromChris Angelico <rosuav@gmail.com>
Date2015-08-14 11:44 +1000
Message-ID<mailman.182.1439516685.3627.python-list@python.org>
In reply to#95243
On Fri, Aug 14, 2015 at 11:05 AM, Michael Torrie <torriem@gmail.com> wrote:
> Given that until recently he thought Django was an IDE, I think calling
> Django a library is fair, as it describes to him how it relates to
> Python.  You download it and install it and it goes in site-packages
> along with all the other libraries you might install.  Of course it
> comes with utilities as well (which I mentioned).  Making the
> distinctions you are making, in this context, is probably ultimately
> going to be confusing to him at this stage of the game.  As he gets
> familiar with django I don't think he'll find this original
> simplification confusing, nor has it seemed to make this discussion a mess.
>
> As to the DSL, I'm not quite sure which part of django you're getting
> at.  Are you referring to the (optional) templating system?

My view, for what it's worth: Django is a library, but it's also a
framework. The difference isn't really that great, and most frameworks
are implemented using libraries. The "library vs framework"
distinction, from an application's standpoint, broadly one of how you
structure your code - do you write a bunch of top-level code that
calls on library functions, or do you write a bunch of functions that
the framework calls on? The distinction can blur some, too.

And as Michael says, the slight simplification isn't causing problems,
so it's really only a technical correctness issue. (Pedantry, in the
best sense of the word.) I've often explained things using
technically-incorrect language, because going into immense detail
won't help; we don't explain quantum mechanics and the nuances of
electrical engineering when we explain how an HTTP request arrives at
your app, because it doesn't matter. Saying "The system hands you a
request to process" is slightly sloppy even from a network admin's
perspective (what you actually get is a socket connection, and then
you read from that until you reckon you have the whole request, yada
yada), but it's what you most likely care about.

On Fri, Aug 14, 2015 at 11:30 AM, Rustom Mody <rustompmody@gmail.com> wrote:
> Purposive, directed lying is usually better pedagogy than legalistic correctness.

Right :) Only I wouldn't call it "lying", as that term indicates an
intent to deceive. Purposeful inaccuracy, let's say.

ChrisA

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web