Summary: Python version Overview

Source: Internet
Author: User

Python's share in the programming field has been steadily rising. After all, it is a leader in development languages. It is favored by some programmers for its ease of operation and simple code, the following describes the Python version.

The background functions are basically automatically available. For example, I used a second-hand information publishing platform, category is a second-hand information type, and there is also an information class, and category are many-to-one relationships. In the background, crud of category and information will be automatically produced.

Because the category itself is a self-Association, when you add a category in admin, admin will define it according to my model. A parentCategory is automatically required. On the add information page, admin requires me to select a category to create an information. In java, all these tasks must be done by yourself.

Of course, there are also many tools that can automatically produce crud, but these open-source tools are basically for a single model, and the generated code must be greatly modified to truly run the function, the most important thing is that the management of associations cannot be automatically generated. Of course, I have also seen some companies make database-driven code producers.

It can generate complete and available code and pages, as well as link processing. However, due to the differences in language features, during development, we still need to constantly restart the server to display the results. Technically, it is not difficult to implement this function for ssh.

However, it will take a lot of time. If it takes a lot of time, few companies will contribute to it. Therefore, I personally think that django is doing very well in this function, especially this function can save developers a lot of time. In some cases, the project can be executed on two lines.

The user enters data through admin, And the Python programmer develops the front-end. After the front-end functions are completed, the data is also available and can be tested and launched. This feature is especially important for small projects that require rapid development, because django is generated based on this scenario.

Of course, sometimes the background is not so simple, but fortunately, admin provides the extended function. We can write the extended code ourselves and then integrate it into admin, however, apart from the admin template. We cannot change any admin code, but I often think about it.

It would be nice if admin supports the automatic generation of code. We can modify the background functions at will. Otherwise, we need to write the code by ourselves, it is not as convenient to expand the generated code. To use admin, you must open the permission module of django. Here is a brief introduction to the permission module. django comes with a permission module, the model in this permission module is no longer familiar to those who are familiar with permissions.

Python version, group, permission, user, and group are many-to-many, and group and permission are many-to-many. In acegi, we usually define user, role, and resource as follows. This is the same as the permissions in django. However, the default permission granularity in django is very coarse, and is based on the model. If we want more detailed permission modules, you need to expand it yourself.

  • Learn Python source files
  • How to define Python Functions
  • How to Write Python correctly
  • Powerful Python language Introduction
  • Big secrets about Python programs

Python is free and open-source, and can be transplanted to multiple operating systems. As long as you do not need to use features dependent on specific operating systems, Python programs can run on various platforms without modification. Python has all the powerful functions of modern programming languages. The Python standard library is very large and can help developers deal with various tasks, such: graphic user interface, file processing, multimedia, regular expressions, document generation, unit testing.

Thread, database, network communication, web browser, CGI, FTP, email, XML, HTML, WAV file, password system, Tk, and other system-related operations. As long as Python is installed, these functions are available in addition to the standard library, there are many other high-quality libraries, such as wxPython, Twisted, and Python graphics libraries.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.