3 ms·
I just finished rewrite of big (400+K LOC) 10 year old pylons codebase to pyramid. We were able to share our models, services and 100% template code, and about
by ergo14 7y ago
I just finished rewrite of big (400+K LOC) 10 year old pylons codebase to pyramid. We were able to share our models, services and 100% template code, and about 80% of view code was untouched.
What you want to do is follow this recipe:
https://docs.pylonsproject.org/projects/pyramid-cookbook/en/latest/porting/legacy.html https://docs.pylonsproject.org/projects/pyramid-cookbook/en/...
You put a 404 handler in pyramid to delegate not found views to pylons, and move views one by one.
In a pyramid tween you can push pyramid session, settings, request,response to pylons app globals.
This approach works really well - you don't have to do total rewrite.
You have same request/response objects, same sqlalchemy ORM, so you can certainly take advantage of that during migration. I don't think anyone at our company regreted the path we took and it was a massive codebase that was making money - no one can afford rewriting that from scratch in $WHATEVERISCOOL today solution.
It certainly is possible - if you need any hints contact me.
- scarygliders 7y agoAwesome reply :) This project has reached its end of life, as far as the owners of the site are concerned. I've just completed a 4 month revamp on it, basically giving it a facelift by moving it from hand-crafted CSS, javascript and crufty old templates, to Bootstrap 4 and a more modern look, with some new features; project "Lipstick on a pig". The company in question has plans for new areas of business for which this site won't be able to handle. It's simply not worth spending the time, bother (and money) trying to hammer that round peg into new square holes, and hence not worth rewriting to Pyramid. The revamp mentioned above will tide them over until something more suitable (and bespoke) is created, which is where Django comes in.
- deleted 7y ago[deleted]