Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I really like a microframework in Python called Flask. I have used it for the past 2 months, and I find it excellent. Now, I would like to use it in deployment, but, there are a few things I'm afraid of. Firstly, even though its a microframework, it depends on Werkzeug (a WSGI framework type of thing), which, in case I run into a problem, makes it more difficult to debug stuff. Second, its not extremely popular, which means that support would be difficult to get.

So, what I was thinking is I could roll my own microframework in Python that doesn't have all the features of Flask, but, only the ones I need, and I would know it through and through and could fix any problems that I might encounter, I estimate this will take 1000-2000 lines, and about 2-3 weeks for me, and probably a lot less with a team of 2.

What do you guys suggest?

share|improve this question
Have you looked at other Python microframeworks, such as – user16764 Apr 7 '13 at 16:11
up vote 4 down vote accepted

Personally, I would use a previously existing microframework, rather than invent one from scratch. While they may not have perfect support, the amount of testing and debugging that has gone into them is pretty sufficient for deploying a production app, and I'd feel more safe knowing that.

in case I run into a problem, makes it more difficult to debug stuff

I'd argue that a framework like Flask actually makes an app easier to debug. Flask is distributed with a small builtin webserver with the express purpose of development and debugging. As long as you have separate development/production environments, you should be good to go. Additionally, if something does mess up on production, there are logging modules you can use.

its not extremely popular, which means that support would be difficult to get.

I suppose this is the best argument against using something like Flask; however, they do have an active mailing list. Additionally, there are other microframeworks like cherrypy, and bottle that could do what you want and are used more often.

share|improve this answer

Web frameworks encode a lot of domain knowledge about building web apps. I know this because I (a Ruby/Rails developer) once wrote a Ruby web app without a framework (as mandated by my employer). I learned a lot about web application design as a result. However, my employer ended up paying for a lot of software development which would have been free if we had gone with the framework.

You will probably find that you will learn a lot if you roll your own. But then, you will start uncovering new things which would fit better into your framework. That 2000 lines of code will quickly expand.

If you want to get into the framework business, then write one by all means. But if you want to stay in the business of building and evolving your app, learn the existing framework.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.