Personal tools

Contact Us 24/7 > 1 866.SIX FEET
Sections

Skip to content. | Skip to navigation

Home > Blog > Why Choose Pyramid For Rapid Web Development Projects
12/01/16

EVERYONE.NET SCHEDULED MAINTENANCE 

Everyone.net will be performing maintenance on their databases Friday December 2nd, 2016 between 9:00PM PT to 3:00AM PT / 12:00AM ET to 06:00AM ET. During this time, all services including web mail, POP, IMAP, and SMTP relay may experience degraded performance and inbound mail delivery delays. We apologize for any inconvenience.

Blog

Why Choose Pyramid For Rapid Web Development Projects

written by Calvin Hendryx-Parker on Tuesday August 28, 2012

If you have a web project with simple requirements that needs to launch quickly, which framework will you pick?

Pyramidframework.jpgPHP or Python?

PHP is generally inconsistent across its naming of methods in the language. Naming schemes don't match cross-libraries inside the standard library and sometimes the methods don't return what you might expect. Therefore it is harder to leverage the tools that are included in the PHP libraries because you basically have to memorize their names, which is error-prone.

In Python, things are very consistent across all the standard libraries and generally all of the frameworks too, so this is our programming language of choice, unless it makes sense to reuse an existing product or framework to fulfill a specific business need and that product or framework is built on another language (think Wordpress or Solr).

"Full stack" or "micro" web frameworks?

Some of the more mature web frameworks, like Django and Zope, are fairly monolithic. They make architectural decisions for developers, such as what type of ORM to use with your database, what templating language to use, etc. While these preset choices save time initially getting started for larger projects, they tend to back fire for smaller projects because they provide more knobs to tweak and tame. Developers end up "fighting the framework" a lot for smaller projects, which is counterproductive if you aren't going to leverage the advanced tools that come with the framework in question.

Larger frameworks also come with bugs that always seem to crop up with your specific edge case. Developers sometimes waste a lot of time working around legacy issues or investigating a piece of code they didn't even work on themselves. Within a larger project, there is usually room to address those bugs, but that's not the case for a small and rapid development project.

On the other hand, "micro" frameworks like Bottle and Flask stand out with their  minimalistic approach. Yet they don't offer much out-of-the-box and their communities are still fairly small.

Pyramid and CherryPy

Between the "full-stack" and the "micro" frameworks, you'll find CherryPy and Pyramid.

CherryPy can be a solid option for rapid web development projects. But we recommend choosing a Python web framework that has more tools out-of-the-box and also has a larger community of developers.

The three-year-old Pyramid web framework is a minimalistic approach inspired by Zope, Pylons and Django. It makes very little assumptions right off the bat, and focuses on providing developers with the tools they need to make their own decisions.

With Pyramid, programers have more flexibility. Developers can choose their own templating language, choose from the numerous form generations libraries, or choose their own database layer: do they want to use NoSQL or SQLAlchemy for with relational database? Pyramid is all open.

Pyramid is also one of the two available Python frameworks running on Python 3, which means it is built with the ability to keep up with technology improvements, unlike most other frameworks.

And Pyramid ranks really well in benchmark tests:

helloworldrequestspersecondtest.png

How large is the Pyramid community?

What used to be the repoze.bfg and the Pylons communities has combined into this new Pyramid community. Most Zope and Plone developers are already working on Pyramid-based projects. And many Django programers now admit a secret preference to Pyramid (ours definitely do!).

There is a tremendous amount of knowledge backing up the Pyramid community. The framework benefits greatly from the years of experience its creators and contributors utilize when building the product. The Pyramid creator himself, Chris McDonough, gained a lot of experience at Zope Corporation and then supporting Zope applications. Pyramid is born out of his understanding of the benefits and shortcomings of Zope. McDonough is now working full-time on advancing the framework, setting the overall project direction, and leading the way about its architecture.

Another important trait to consider: the Pyramid community is very active, boasting regular commits and releases. And Pyramid developers have learned their lesson: they are putting a lot of emphasis on creating high-quality documentation.

"Legacy Bugs", Did You Say?

Pyramid is fully tested. The main premise, in this community, is that, if a line of code isn't tested, it is considered broken. Pyramid core developers run coverage tests so that every line of code has a written test that covers it.

Where to start?

If you are new to Pyramid, the official Pyramid website has a few resources that can help you get up to speed right away:

 
Posted by Vlad on Jan 03, 2013 12:42 PM
Thanks. Good article.
Posted by Mauricio Schneider on May 25, 2013 04:55 PM
I was looking for a performance comparison like the one you added to this post, and I'm glad to see some PHP frameworks along with the Python ones. I'm using Yii Framework and I was wondering how would Pyramid would do against it. Pretty useful information, thanks for the post!
Posted by Chris on May 15, 2014 01:23 AM
"Check out the Pyramid FAQ" - Link is 404!
Posted by jim on May 15, 2014 09:48 AM
Thanks Chris. Looks like they moved the page. I updated the link.
Posted by Ben Ackland on Sep 05, 2014 05:35 AM
Any idea roughly how many developers currently make up the Pyramid community worldwide?
Posted by jim on Sep 05, 2014 10:27 AM
Hi Ben, Not sure there is a way to figure that out, but you can monitor the number of times Pyramid has been downloaded from PyPi https://pypi.python.org/pypi/pyramid/1.5.1 You can check the #pyramid and #pylons chat rooms on Freenode. You can also check Github for activity. There are 175 contributors as of 9/5/14. So it is certainly popular if you are looking for a Python microframework or need to do things that aren't easy in Django.
Posted by Giorgio Pieretti on Nov 10, 2014 05:51 AM
Thank you very much for this article. I'm testing some python based frameworks and these infos helped me to choose pyramid for my needs.
Add comment

You can add a comment by filling out the form below. Plain text formatting.

puzzle
Calvin Hendryx-Parker
Chief Technology Officer
Calvin's Recent Posts:
Django CMS vs Plone (10/31/2016)

Next Steps


Select a type of support:

Contact our sales team

First name:
Last name:
Email:
Phone Number:
Message:
Fight spam:
What is + ?
 
Call Us 1 866.SIX FEET
Sections