django vs zope vs web2py

Discussion in 'Python' started by Alok Singh Mahor, Apr 21, 2013.

  1. Hi everyone,
    few months back I decided to adopt python for my all sort of work including web progra
     
    Alok Singh Mahor, Apr 21, 2013
    #1
    1. Advertising

  2. I am sorry by mistake I sent incomplete mail here is my mail.

    Hi everyone,
    few months back I decided to adopt python for my all sort of work includingweb programming. and I have wasted long time deciding which to adopt out of django, zope and web2py.
    I am from php and drupal background. which framework would be better for me.. I am open to learn anything, anything new. but I want to adopt best thingfull of features and lot of plugins/extensions and easy to use and have better documentation and books etc.

    please suggest me so without wasting more time I can start learning
    thanks in advance :)
     
    Alok Singh Mahor, Apr 21, 2013
    #2
    1. Advertising

  3. Alok Singh Mahor

    rusi Guest

    On Apr 21, 11:18 am, Alok Singh Mahor <> wrote:
    > I am sorry by mistake I sent incomplete mail here is my mail.
    >
    > Hi everyone,
    > few months back I decided to adopt python for my all sort of work including web programming. and I have wasted long time deciding which to adopt outof django, zope and web2py.
    > I am from php and drupal background. which framework would be better for me. I am open to learn anything, anything new. but I want to adopt best thing full of features and lot of plugins/extensions and easy to use and have better documentation and books etc.
    >
    > please suggest me so without wasting more time I can start learning
    > thanks in advance :)


    I am not the best person to advise on this area (hopefully others with
    more python-for-web knowledge will speak up)
    I see some implicit misconceptions/contradictions in your question so
    just saying something…

    Python is a general purpose programming language.
    php has some (poor?) pretensions to that title.
    Drupal cannot even pretend I guess.

    Therefore when switching to something like python its important to
    have high on your TODO list the need to grok what 'general purpose
    programming language' means.
    Many people use mega-frameworks like RoR, Django etc without really
    knowing much of the underlying programming language. This has some
    consequences:
    a. You function suboptimally, basically following the cookie-cutter
    approach
    b. When you have to switch out of Django into python (say) it can be
    very unnerving and frustrating because you suddenly find you dont know
    the 'ABC'

    So the longer but more fruitful in the long-run approach is to
    identify what are the general areas that web programming needs, study
    these in isolation and then switch to a mega-framework like django.
    Something like:

    - templating with cheetah
    - ORM with sqlalchemy connecting to some proper database
    - web-serving with cherrypy (web.py?, bottle? flask?)

    [I am not claiming that this list is complete or the examples are
    good. Of the above Ive only used cheetah]

    After your hands are a little dirty with the plumbing, you can switch
    to a mega-framework like django.

    Also for someone who has mostly web experience, its good to put aside
    web (for a while) and try out python for something completely un-web-
    ish (a game? a sysadmin script?) to get a feel for 'general purpose
    programming language'
     
    rusi, Apr 21, 2013
    #3
  4. Alok Singh Mahor

    Roy Smith Guest

    In article <>,
    Alok Singh Mahor <> wrote:

    > I am sorry by mistake I sent incomplete mail here is my mail.
    >
    > Hi everyone,
    > few months back I decided to adopt python for my all sort of work including
    > web programming. and I have wasted long time deciding which to adopt out of
    > django, zope and web2py.
    > I am from php and drupal background. which framework would be better for me.
    > I am open to learn anything, anything new. but I want to adopt best thing
    > full of features and lot of plugins/extensions and easy to use and have
    > better documentation and books etc.


    Zope is a much older framework, and much lower level than django. It's
    almost certainly not what you want.

    I'm not familiar with web2py, so I can't comment on that.

    Django is sort of the "killer app" these days in the python web world.
    That's not to say that it's necessarily the best, but at least it's well
    documented, and has a thriving user community of people who can help
    you. There's also a lot of add-on software available for it.

    The basic things you get from django are:

    1) A built-in ORM (Object Relational Mapper) layer. This is the thing
    which lets you ignore all the horrible details of how your underlying
    database works and just deal with Python objects.

    2) A structure for parsing incoming HTTP requests, and calling the right
    bit of your code to handle each request.

    3) A template language, to simplify the generation of your HTML pages.

    There are others besides the three you mentioned. You might want to
    start at http://wiki.python.org/moin/WebFrameworks to explore the
    possibilities.
     
    Roy Smith, Apr 21, 2013
    #4
  5. On Sun, Apr 21, 2013 at 11:48 AM, Alok Singh Mahor <>wrote:

    > I am sorry by mistake I sent incomplete mail here is my mail.
    >
    > Hi everyone,
    > few months back I decided to adopt python for my all sort of work
    > including web programming. and I have wasted long time deciding which to
    > adopt out of django, zope and web2py.
    > I am from php and drupal background. which framework would be better for
    > me. I am open to learn anything, anything new. but I want to adopt best
    > thing full of features and lot of plugins/extensions and easy to use and
    > have better documentation and books etc.
    >
    > please suggest me so without wasting more time I can start learning
    > thanks in advance :)
    > --
    > http://mail.python.org/mailman/listinfo/python-list
    >


    You see, in my experience, if you are trying to find the best before
    starting (to learn), probably might never going to start.
    I don't know what's your Python experience but Django is a decent option to
    start over! To start Django, the documentation is one of the best way to
    start over!!

    Since, you are already into web dev using php, drupal etc. Unless you are
    very particular in starting with Django... I suggest you to take a look
    into other areas of Python.

    May be Network programming or systems programming or getting around
    algorithms - trying to learn some mind blowing algos.. hack around on
    network..

    Come back and do Django.. you will see a lot of fresh ideas!!
     
    Surya Kasturi, Apr 21, 2013
    #5
  6. Alok Singh Mahor

    Modulok Guest

    > Hi everyone,
    > few months back I decided to adopt python for my all sort of work including
    > web programming...
    > --
    > http://mail.python.org/mailman/listinfo/python-list
    >


    Pick Django or web2py. You'll be happy with either. (I have no experience with
    zope.)

    They're both full featured do-everything-you-ever-wanted frameworks with great
    communities and lots of documentation. You can buy books on either. I'd say
    web2py is a little more elegant and easier to get started with. (An admittedly
    subjective claim.) Django has a little larger community and has more third
    party stuff.

    If you just need to "get it done" and don't care about how it happens, they're
    both excellent. You'll meet deadlines with either of them. The communities are
    smart the docs are great. You can't really go wrong any way you slice it.
    There's more third party documentation and books for Django right now but
    that's just because Django came out first. Give it another couple years and
    there won't be much difference.

    Basically, flip a coin and just go with it.



    And now for the gritty details approach...

    The problem with web frameworks is they are "magic", i.e. things just happen.
    It's the price we pay for using a high level abstraction. The higher the
    abstraction the more magic there is. Often times magic is good. It saves us
    time and money. However depending on your needs, other options are worth
    considering.

    If you are willing to invest a lot of time not being initially productive but
    learn a *ton* in exchange, you can use something like cherrypy. (Don't get me
    wrong, I love and often use cherrypy.) It's dirt simple and works. However,
    because it's so simple it doesn't do half of what you need for a non-trivial
    production site. Result? You'll have to fill in the tool chain gaps with other
    modules. This is what web frameworks do for you.

    If you go the cherrypy route you'll need to learn other things like like markup
    languages and some kind of way to talk to a database. Security is also entirely
    in your hands. You'll learn a ton about HTTP, SQL, markup languages, web
    security, encryption, etc. You'll be basically re-creating a web framework of
    your own brand. Again it's a time spent vs. knowledge gained trade off.

    For a template language I really liked wheezy.template but it's a little too
    new for me to feel comfortable using it on any big project. It has a very
    simple inheritance model, which is refreshing. I hope to use it more in the
    future.

    I usually use Mako for my templates. By 'template' I mean any template, not
    just HTML. I use mako for HTML, documentation, I even use mako to write SQL
    templates. The inheritance model of Mako takes a little more mental gymnastics
    to wrap your head around than the simpler (read nicer) wheezy.template model,
    but it's a more mature code base. (Not as mature as cheetah.) I had only minor
    experience with cheetah but found I preferred Mako. It was a matter of taste.
    There's nothing wrong with cheetah.

    As for database access: sqlalchemy is truly excellent and very flexible. For
    most things sqlalchemy is great. However for some projects it may contain too
    much magic. (Again we're going deeper.) Sometimes a backend-specific module is
    called for, in which case psycopg2 on postgresql is nice. The ability to use
    python context managers as transaction blocks is very clean.

    In short, how much do you want to learn? Do you prefer a top-down or bottom-up
    approach? Gritty details or elegant abstractions?

    -Modulok-
     
    Modulok, Apr 21, 2013
    #6
  7. On Sun, Apr 21, 2013 at 5:49 PM, Modulok <> wrote:

    > > Hi everyone,
    > > few months back I decided to adopt python for my all sort of work

    > including
    > > web programming...
    > > --
    > > http://mail.python.org/mailman/listinfo/python-list
    > >

    >
    > Pick Django or web2py. You'll be happy with either. (I have no experience
    > with
    > zope.)
    >
    > They're both full featured do-everything-you-ever-wanted frameworks with
    > great
    > communities and lots of documentation. You can buy books on either. I'd say
    > web2py is a little more elegant and easier to get started with. (An
    > admittedly
    > subjective claim.) Django has a little larger community and has more third
    > party stuff.
    >
    > If you just need to "get it done" and don't care about how it happens,
    > they're
    > both excellent. You'll meet deadlines with either of them. The communities
    > are
    > smart the docs are great. You can't really go wrong any way you slice it.
    > There's more third party documentation and books for Django right now but
    > that's just because Django came out first. Give it another couple years and
    > there won't be much difference.
    >
    > Basically, flip a coin and just go with it.
    >
    >
    >
    > And now for the gritty details approach...
    >
    > The problem with web frameworks is they are "magic", i.e. things just
    > happen.
    > It's the price we pay for using a high level abstraction. The higher the
    > abstraction the more magic there is. Often times magic is good. It saves us
    > time and money. However depending on your needs, other options are worth
    > considering.
    >
    > If you are willing to invest a lot of time not being initially productive
    > but
    > learn a *ton* in exchange, you can use something like cherrypy. (Don't get
    > me
    > wrong, I love and often use cherrypy.) It's dirt simple and works. However,
    > because it's so simple it doesn't do half of what you need for a
    > non-trivial
    > production site. Result? You'll have to fill in the tool chain gaps with
    > other
    > modules. This is what web frameworks do for you.
    >
    > If you go the cherrypy route you'll need to learn other things like like
    > markup
    > languages and some kind of way to talk to a database. Security is also
    > entirely
    > in your hands. You'll learn a ton about HTTP, SQL, markup languages, web
    > security, encryption, etc. You'll be basically re-creating a web framework
    > of
    > your own brand. Again it's a time spent vs. knowledge gained trade off.
    >
    > For a template language I really liked wheezy.template but it's a little
    > too
    > new for me to feel comfortable using it on any big project. It has a very
    > simple inheritance model, which is refreshing. I hope to use it more in the
    > future.
    >
    > I usually use Mako for my templates. By 'template' I mean any template, not
    > just HTML. I use mako for HTML, documentation, I even use mako to write SQL
    > templates. The inheritance model of Mako takes a little more mental
    > gymnastics
    > to wrap your head around than the simpler (read nicer) wheezy.template
    > model,
    > but it's a more mature code base. (Not as mature as cheetah.) I had only
    > minor
    > experience with cheetah but found I preferred Mako. It was a matter of
    > taste.
    > There's nothing wrong with cheetah.
    >
    > As for database access: sqlalchemy is truly excellent and very flexible.
    > For
    > most things sqlalchemy is great. However for some projects it may contain
    > too
    > much magic. (Again we're going deeper.) Sometimes a backend-specific
    > module is
    > called for, in which case psycopg2 on postgresql is nice. The ability to
    > use
    > python context managers as transaction blocks is very clean.
    >
    > In short, how much do you want to learn? Do you prefer a top-down or
    > bottom-up
    > approach? Gritty details or elegant abstractions?
    >
    > -Modulok-
    >

    thanks a lot Rusi, Roy Smith, Surya and Modulok
    I am sticking to django. In future I will touch web2py also
     
    Alok Singh Mahor, Apr 21, 2013
    #7
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Shane Hathaway
    Replies:
    2
    Views:
    335
    Michael Hudson
    Aug 29, 2003
  2. John Posner

    Question on Django and Django Book

    John Posner, Nov 13, 2010, in forum: Python
    Replies:
    0
    Views:
    339
    John Posner
    Nov 13, 2010
  3. Paul Watson

    Django or web2py

    Paul Watson, Sep 8, 2011, in forum: Python
    Replies:
    3
    Views:
    2,087
    Vineet
    Sep 9, 2011
  4. eGenix Team: M.-A. Lemburg
    Replies:
    0
    Views:
    150
    eGenix Team: M.-A. Lemburg
    Jun 18, 2013
  5. Gary Roach
    Replies:
    0
    Views:
    149
    Gary Roach
    Jan 2, 2014
Loading...

Share This Page