Hello!

It is required to transfer a large (with a very complex structure) web project to the Python platform. The application is something like a social network or community for corporate use.

The database will not change (MySQL), but its structure is even more so. Therefore, the future system should be written with an eye on the already existing data and database.

The system should be very flexible and convenient for all kinds of changes.

Originally planned to look at Django . But having a little got acquainted - were confused:

  1. The structure of users (and not only) in the database should strictly fall on the existing one. The structure of Django does not suit us. Or it is necessary to rewrite the standard structure and correct it (which is how we understand it is extremely not recommended).
  2. The same applies to access rights, logs, partly sessions (not fundamentally), and other goodies that go to jango "out of the box"
  3. Admin out of the box is not suitable for all sorts of reasons. From design usability to structure. Because of this, we cry at night ...
  4. ORM is good, but there are places where they will have to be neglected.

It follows that most of the features that Django has (or may have in the future with the installation of suitable plug-ins or extensions) are not relevant for us.

Therefore, the question is: what is the development of the application?

Flask and Pylons were considered as options, but information about them (and especially frames) was much less. Therefore, we will be happy to comment on this.

Confirm, disprove our thoughts, or suggest some kind of solution to your problem. We will be very grateful for the detailed response.

Maybe we missed some important points for understanding the essence of the problem - write, be sure to add.

Closed due to the fact that it is necessary to reformulate the question so that you can give an objectively correct answer to the party PashaPash ♦ 15 Aug '16 at 9:58 .

The question gives rise to endless debates and discussions based not on knowledge, but on opinions. To get an answer, rephrase your question so that it can be given an unambiguously correct answer, or delete the question altogether. If the question can be reformulated according to the rules set out in the certificate , edit it .

  • 2
    @avalock, if it's not a secret, what is the profit from switching to python? - etki
  • I also wonder why? - VasyOk
  • If I knew)) So I see: our boss wakes up at 3 o'clock in the morning and in a cold sweat nervously writes on a torn piece of paper: “Transfer the site to the python!”)) In general, this event was prepared for a long time due to, with extreme wretchedness of the php version of the system (I do not want to lie, like so). Why didn't you decide to rewrite to the same Yii or CodeIgniter for example - I don’t know - avalock
  • @avalock, because the application on Yii or CodeIgniter will inevitably have to be rewritten again) And about the python, I would try to talk with the boss on this topic, find out what advantages he sees in this. Just as for me it was a stitching for soap - although this, of course, depends on what and how the current version is written. - etki
  • one
    @avalock, you, of course, know it better, but apart from the "wretchedness", I have not seen any valid reason why you need to "tear the claws" from php. Yes, the language is not a gift, but lately ( I think so ), the developers have taken it up with the mind. There is still a lot to be corrected there, but progress is present. If you wrote your project a long time ago and on the old version of php, can you start to refactor, move to a fresh version of php? Speaking of Python, by the way, why didn't you consider Ruby? > Why didn’t they decide to rewrite to the same Yii or CodeIgniter for example - I don’t know Duc is the same php)) - Deonis

2 answers 2

I will express my opinion:

1) For large projects, use JAVA or C #

2) Some use PYTHON (like Yandex) someone and PHP

3) PHP - is spinning in this direction (sites and social networks)

4) "Wretchedness of PHP" is by no means justified, it is a fairly quick language and there are a lot of sites on it (until recently, VC stood on PCP and there were no problems)

5) PCP is updated dynamically, which gives after some time the optimization of those functions that currently do not work so smoothly.

6) since you have a mega-network there, it is easier to buy a second car that will take part of the load than rewrite everything.

7) support PCP (for me as) easier.

8) Want speed? get out kphp

  • one
    @Manitikyl, and yet neither the question text nor the author’s comments contain a single word about insufficient speed. As I understand it, we are talking about the fact that the existing project cannot be supported (apparently by existing forces). Therefore, it was decided to redo everything (except for the accumulated base). - avp

I'll insert my 5 kopecks ..

On Flask and Pylons, I have no experience, because I will give only counter-arguments to yours on Django:

  1. The structure of users can be rewritten, if we are talking about a large project, this is not the most difficult task to be faced with. What is a framework at all? - this is the environment, this is a set of tools. No one obliges to use all the tools. If at least a little more than half of the tools presented by one or another framework suits you, then it already makes sense to use it. And ideally, no universal framework for a specific project will work, IMHO.
  2. The system of access rights must be done by itself. For three years, I never once saw that someone in Djangovskaya seriously used, well, of course, with the exception of the basic options (superuser, staff status).
  3. Well, again, Django-admin is for convenience at the development stage or for full-fledged use in small projects, although you can customize it quite deeply, and there are a number of third-party packages on this subject. But in your case, you still need to write your own corporate system.
  4. ORM is good because it is convenient in terms of speed and simplicity in simple popular cases, but no one promised that it is suitable absolutely everywhere, where it will be easier for you, then write to yourself the health of raw queries.

PS: If your team is just starting to learn new tools and there are no developed habits yet, then you can take Flask because it is known to be minimalistic, you will write to it what you need and there will be no redundancy in your case. But if in the future it will be necessary to recruit new developers, then it seems to me to find a specialist on Django to be much easier than on any exotic.