Hi, for a new project, I have to make a website for classified ads with pyramid and I have to say I'm a bit lost. Im used to develop with django. very easy, it take all decision for u (template, auth, ...) Pyramid seems to be very powerfull, but also a bit complexe.
for my project, i need : -to deal with database : lets use sqlalchemy -to deal with url : url dispatched for this
till this, it is very simple, tutorial are really well done. but then ... - for forms : formalchemy seems to be good, easy for admin part, but difficult to find doc how to create form and validate them in front end. deform seems also ok, but it is bad that u cant easily change templating system and that u need to "redefine" your model when formalchemy create form from model.py - templating : mako, jinja2, .... ?? - user management : a lot of different possibilities here also
is there maybe a scaffold which could be use to have something optimized to deal with my needs because alchemy scaffold is not enough ?
On Fri, 2012-09-28 at 05:18 -0700, oto iashvili wrote:
> Hi,
> for a new project, I have to make a website for classified ads with
> pyramid and I have to say I'm a bit lost.
> Im used to develop with django. very easy, it take all decision for u
> (template, auth, ...)
> Pyramid seems to be very powerfull, but also a bit complexe.
I might suggest that you stick to Django if you like the choices it
makes for you. Django is a very nice system.
There is also Ptah, which is built on top of Pyramid, but makes more
choices for you. Also, Kotti.
> for my project, i need :
> -to deal with database : lets use sqlalchemy
> -to deal with url : url dispatched for this
> till this, it is very simple, tutorial are really well done.
> but then ...
> - for forms : formalchemy seems to be good, easy for admin part, but
> difficult to find doc how to create form and validate them in front
> end.
> deform seems also ok, but it is bad that u cant easily change
> templating system and that u need to "redefine" your model
> when formalchemy create form from model.py
> - templating : mako, jinja2, .... ??
> - user management : a lot of different possibilities here also
> is there maybe a scaffold which could be use to have something
> optimized to deal with my needs because alchemy scaffold is not
> enough ?
Nobody is going to be able to answer this question, because it's
hundreds of questions. It really sounds like you need a higher level
system to take some of the responsibility for making these choices out
of your hands.
problem with django is that orm is a bit limited for my needs. That is why I choosed pyramid (also because it is so powerfull ;-) )
my post was not to say that I prefer someone else to make choice for me, but more to ask for advices, for tips, telling me advantages and disadvantages of different packages. or maybe someone know existing projects dealing with such problematic than me and from which I could find example on how to use different packages.
On Friday, September 28, 2012 4:28:22 PM UTC+2, Chris McDonough wrote:
> On Fri, 2012-09-28 at 05:18 -0700, oto iashvili wrote: > > Hi, > > for a new project, I have to make a website for classified ads with > > pyramid and I have to say I'm a bit lost. > > Im used to develop with django. very easy, it take all decision for u > > (template, auth, ...) > > Pyramid seems to be very powerfull, but also a bit complexe.
> I might suggest that you stick to Django if you like the choices it > makes for you. Django is a very nice system.
> There is also Ptah, which is built on top of Pyramid, but makes more > choices for you. Also, Kotti.
> > for my project, i need : > > -to deal with database : lets use sqlalchemy > > -to deal with url : url dispatched for this
> > till this, it is very simple, tutorial are really well done. > > but then ... > > - for forms : formalchemy seems to be good, easy for admin part, but > > difficult to find doc how to create form and validate them in front > > end. > > deform seems also ok, but it is bad that u cant easily change > > templating system and that u need to "redefine" your model > > when formalchemy create form from model.py > > - templating : mako, jinja2, .... ?? > > - user management : a lot of different possibilities here also
> > is there maybe a scaffold which could be use to have something > > optimized to deal with my needs because alchemy scaffold is not > > enough ?
> Nobody is going to be able to answer this question, because it's > hundreds of questions. It really sounds like you need a higher level > system to take some of the responsibility for making these choices out > of your hands.
While Pyramid is very powerful, it is very low level and has no "bells and whistles". You could potentially rewrite Django on top of Pyramid.
To try and address this question, let's imagine that when building on Pyramid or Django, there are 3 main types of code :
- Core ( Pyramid or Django Itself + the directly supported packages : sqlalchemy, mako, etc ) - Third Party Pyramid Libraries ( turbogears , ptah, kotti, formalchemy, etc ; or any of the django plugins ) - Your Code
When compared to one another:
- The "Core" in Pyramid does less than in Django - A lot of the core functionalities in Django are in the Third-Party category for Pyramid
If you want to have lots of fancy Admin Backends, User Management, etc under Pyramid -- then you'll need to rely on a third party library. When you use those 3rd Party Libraries though, you'll be bound by their constraints. My point is that you're no longer comparing Pyramid to Django, but TurboGears/Kotti/Ptah to Django.
A lot of my consulting clients build applications on Rails & Django. Their workflow is generally this:
- start a new project - something is up and running on day 1 - every day of iteration, new features exist. the daily workflow is 2 hours to find django/railss module, 4 hours to override/monkeypatch it, 2 hours to actually code on the application - A few months in, and usually after the project launches, the daily workflow becomes 8hours of trying to recode around Django/Rails/Plugins limitations
When people build on Pyramid, the workflow is more like:
- start a new project - you might not see anything for a week - every day new features exist. the daily workflow is 7+ hours building application logic, <1hr dealing with Pyramid or 3rd party libraries - A few months in, and usually after the project launches, the daily workflow doesn't really change
I mention that because if you're coming to Pyramid from Django, you should understand that the cost of all the benefits that Pyramid gives you later on, is that it's a bit slower to start out with. You have more control of the foundations.
To address some of the points you made:
- You can use Mako or Jinja2 or whichever templates you prefer for your project, then use the Chameleon template with Deform as needed. You're not bound to using a single templating system with Pyramid. You can mix and match templates within the same project.
- User management is something that Pyramid doesn't really concern itself with. "Users" aren't something that pyramid is concerned with at all, outside of the optional authentication & authorization controls.
> While Pyramid is very powerful, it is very low level and has no "bells and
> whistles". You could potentially rewrite Django on top of Pyramid.
> To try and address this question, let's imagine that when building on
> Pyramid or Django, there are 3 main types of code :
> - Core ( Pyramid or Django Itself + the directly supported packages :
> sqlalchemy, mako, etc )
> - Third Party Pyramid Libraries ( turbogears , ptah, kotti, formalchemy,
> etc ; or any of the django plugins )
> - Your Code
> When compared to one another:
> - The "Core" in Pyramid does less than in Django
> - A lot of the core functionalities in Django are in the Third-Party
> category for Pyramid
> If you want to have lots of fancy Admin Backends, User Management, etc
> under Pyramid -- then you'll need to rely on a third party library. When
> you use those 3rd Party Libraries though, you'll be bound by their
> constraints. My point is that you're no longer comparing Pyramid to
> Django, but TurboGears/Kotti/Ptah to Django.
> A lot of my consulting clients build applications on Rails & Django.
> Their workflow is generally this:
> - start a new project
> - something is up and running on day 1
> - every day of iteration, new features exist. the daily workflow is 2
> hours to find django/railss module, 4 hours to override/monkeypatch it, 2
> hours to actually code on the application
> - A few months in, and usually after the project launches, the daily
> workflow becomes 8hours of trying to recode around Django/Rails/Plugins
> limitations
> When people build on Pyramid, the workflow is more like:
> - start a new project
> - you might not see anything for a week
> - every day new features exist. the daily workflow is 7+ hours building
> application logic, <1hr dealing with Pyramid or 3rd party libraries
> - A few months in, and usually after the project launches, the daily
> workflow doesn't really change
> I mention that because if you're coming to Pyramid from Django, you should
> understand that the cost of all the benefits that Pyramid gives you later
> on, is that it's a bit slower to start out with. You have more control of
> the foundations.
> To address some of the points you made:
> - You can use Mako or Jinja2 or whichever templates you prefer for your
> project, then use the Chameleon template with Deform as needed. You're not
> bound to using a single templating system with Pyramid. You can mix and
> match templates within the same project.
> - User management is something that Pyramid doesn't really concern itself
> with. "Users" aren't something that pyramid is concerned with at all,
> outside of the optional authentication & authorization controls.
> --
> You received this message because you are subscribed to the Google Groups
> "pylons-discuss" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/pylons-discuss/-/N8nw26FztegJ.
> To post to this group, send email to pylons-discuss@googlegroups.com.
> To unsubscribe from this group, send email to
> pylons-discuss+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/pylons-discuss?hl=en.
> When people build on Pyramid, the workflow is more like:
> - start a new project > - you might not see anything for a week > - every day new features exist. the daily workflow is 7+ hours building > application logic, <1hr dealing with Pyramid or 3rd party libraries > - A few months in, and usually after the project launches, the daily > workflow doesn't really change
I find this is true only the first time you use Pyramid. After you know what components you prefer (which DB, etc..) and you know how to plug them in, there's no reason why a Pyramid app should take any long than a Django app. The time sink with Pyramid is the learning curve...learning about root objects, INI files, traversal, decorators, authorization/authentication, is NOT trivial with Pyramid. The documentation is very good, but it's also very verbose. Fortunately the Pyramid community is great and has helped me out quite a bit.
to some extent yes. but the levels of automation and magic you see in a Django app vs a Pyramid app early on are a stark contrast. With django you can enable a handful of extensions, and have a role-permisisoned forum site with blog posts and comments, complete with admin and user interfaces - then you just tweak it. With Pyramid, you don't get any of that stuff unless you use a 3rd party framework on top, and even then the level of magic isn't nearly as intense.
The time and effort to build a mature, stable, app with Django and Pyramid is probably equal. My point was just that you'll have to invest more on the foundations in Pyramid - and end up building it correctly from scratch; while with Django you'll bootstrap on a ton of random stuff, then try to configure it into your app, then start to offload it for performance and business logic reasons.
Personally, one of those paths is a lot less frustrating to me...
On Thursday, October 4, 2012 10:07:50 PM UTC-4, Zak wrote:
> When people build on Pyramid, the workflow is more like:
>> - start a new project >> - you might not see anything for a week >> - every day new features exist. the daily workflow is 7+ hours building >> application logic, <1hr dealing with Pyramid or 3rd party libraries >> - A few months in, and usually after the project launches, the daily >> workflow doesn't really change
> I find this is true only the first time you use Pyramid. After you know > what components you prefer (which DB, etc..) and you know how to plug them > in, there's no reason why a Pyramid app should take any long than a Django > app. The time sink with Pyramid is the learning curve...learning about root > objects, INI files, traversal, decorators, authorization/authentication, is > NOT trivial with Pyramid. The documentation is very good, but it's also > very verbose. Fortunately the Pyramid community is great and has helped me > out quite a bit.
thanks a lot, that really a great explanation. It is much more clear for me now. still, if someone can give me some example of application with such needs as I, it would be a pleasure ;-)
On Tuesday, October 2, 2012 6:13:57 PM UTC+2, Jonathan Vanasco wrote:
> While Pyramid is very powerful, it is very low level and has no "bells and > whistles". You could potentially rewrite Django on top of Pyramid.
> To try and address this question, let's imagine that when building on > Pyramid or Django, there are 3 main types of code :
> - Core ( Pyramid or Django Itself + the directly supported packages : > sqlalchemy, mako, etc ) > - Third Party Pyramid Libraries ( turbogears , ptah, kotti, formalchemy, > etc ; or any of the django plugins ) > - Your Code
> When compared to one another:
> - The "Core" in Pyramid does less than in Django > - A lot of the core functionalities in Django are in the Third-Party > category for Pyramid
> If you want to have lots of fancy Admin Backends, User Management, etc > under Pyramid -- then you'll need to rely on a third party library. When > you use those 3rd Party Libraries though, you'll be bound by their > constraints. My point is that you're no longer comparing Pyramid to > Django, but TurboGears/Kotti/Ptah to Django.
> A lot of my consulting clients build applications on Rails & Django. > Their workflow is generally this:
> - start a new project > - something is up and running on day 1 > - every day of iteration, new features exist. the daily workflow is 2 > hours to find django/railss module, 4 hours to override/monkeypatch it, 2 > hours to actually code on the application > - A few months in, and usually after the project launches, the daily > workflow becomes 8hours of trying to recode around Django/Rails/Plugins > limitations
> When people build on Pyramid, the workflow is more like:
> - start a new project > - you might not see anything for a week > - every day new features exist. the daily workflow is 7+ hours building > application logic, <1hr dealing with Pyramid or 3rd party libraries > - A few months in, and usually after the project launches, the daily > workflow doesn't really change
> I mention that because if you're coming to Pyramid from Django, you should > understand that the cost of all the benefits that Pyramid gives you later > on, is that it's a bit slower to start out with. You have more control of > the foundations.
> To address some of the points you made:
> - You can use Mako or Jinja2 or whichever templates you prefer for your > project, then use the Chameleon template with Deform as needed. You're not > bound to using a single templating system with Pyramid. You can mix and > match templates within the same project.
> - User management is something that Pyramid doesn't really concern itself > with. "Users" aren't something that pyramid is concerned with at all, > outside of the optional authentication & authorization controls.