


Python development tools and framework installation example steps
Introduction:
In fact, before I knew Python, I only knew about this language. Most of them were developed using .net. I also learned MVC+EF development before, but since I didn’t use it at work, I didn’t record what I learned on the blog.
I recently came into contact with the crawler technology, and then I learned that Python seems to be very powerful in developing crawlers. So I became interested, and interest is an important thing, so I slowly started to get in touch with Python.
Then start with the most basic configuration of the development environment. Suddenly I found that it is really convenient to do .net. You don’t have to worry about the development environment at all. You only need to install Visual Studio and MSSQL Server on the Windows system to develop.
Of course, it may not be as simple as I said. Closer to home, let’s start with the most basic installation of development tools and configuration of the development environment.
Step one: Install development tools
Here I chose JetBrains Pycharm IDE, which is an IDE specially developed for Python by JetBrains company.
Download address (JetBrains official website):
After the download is completed, run the downloaded file and install it step by step according to the instructions. The installation process is very simple, but I still record my installation steps.
After running the downloaded .exe file, the following interface will appear, click Next directly.
Then select the installation address and Next again.
#Then choose to create a desktop shortcut and create an association. Of course, you can also choose Next without checking it by default. random.
Then wait a few minutes for the installation to be completed. Click Finish below to complete the installation.
How about it? Is the installation very simple? The next step is activation.
run. The following prompt will appear when you open it for the first time, which probably means choosing to import settings. Generally, if you use it for the first time, just select the second one without importing settings, and then click OK.
The following interface will appear. This is the most important step, activation. There are three options (the first is to enter the JetBrains account, which will not be introduced here).
The second method is to enter the registration code. You can find the registration code online. For example:
Here I choose the third option, using a server address authorized by the terminal. You can configure this server yourself, or you can find it online. I just found it online. . .
Can refer to: Or
The following is the last step, which is to choose the shortcut key of which development tool to use , IDE theme, font and color settings, etc. I chose the default and clicked OK.
The installation of development tools has come to an end. Next, configure the Python development environment, that is, install the Python code parser.
For the installation of Python, you can refer to this installation of Python. It is very detailed and I won’t go into too much introduction.
After completing the installation of Python, let’s start installing the Python web development framework.
There are many development frameworks for Python, you can learn about them by yourself. I learned about both Flask and Django.
Beginners are generally recommended to learn Flask, a relatively lightweight web development framework, and Django, a heavyweight web development framework that belongs to MVC. (I won’t install this here, after all, I am also a beginner...)
First install Flask, a lightweight web development framework.
First run the windows command line. (i.e. cmd)
Input: pip install flask
After the installation is completed, test whether it is successful. Enter: python
Then enter: from flask import Flask
If no error is reported, the installation is successful. . Continue to the next step. Install flask-sqlalchemy package, sqlalchemy I understand it as an ORM framework, similar to .net's EF framework.
First install sqlalchemy. Input: pip install sqlalchemy
After the installation is complete, then install flask-sqlalchemy. Enter: pip install flask_sqlalchemy
and then test whether the installation is successful. Input: from flask_sqlalchemy import SQLAlchemy
If there is still no error, the installation is successful. At this point, the Flask web development framework is installed.
The above is the detailed content of Python development tools and framework installation example steps. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

PHP is mainly procedural programming, but also supports object-oriented programming (OOP); Python supports a variety of paradigms, including OOP, functional and procedural programming. PHP is suitable for web development, and Python is suitable for a variety of applications such as data analysis and machine learning.

PHP is suitable for web development and rapid prototyping, and Python is suitable for data science and machine learning. 1.PHP is used for dynamic web development, with simple syntax and suitable for rapid development. 2. Python has concise syntax, is suitable for multiple fields, and has a strong library ecosystem.

Python is more suitable for beginners, with a smooth learning curve and concise syntax; JavaScript is suitable for front-end development, with a steep learning curve and flexible syntax. 1. Python syntax is intuitive and suitable for data science and back-end development. 2. JavaScript is flexible and widely used in front-end and server-side programming.

PHP originated in 1994 and was developed by RasmusLerdorf. It was originally used to track website visitors and gradually evolved into a server-side scripting language and was widely used in web development. Python was developed by Guidovan Rossum in the late 1980s and was first released in 1991. It emphasizes code readability and simplicity, and is suitable for scientific computing, data analysis and other fields.

VS Code can run on Windows 8, but the experience may not be great. First make sure the system has been updated to the latest patch, then download the VS Code installation package that matches the system architecture and install it as prompted. After installation, be aware that some extensions may be incompatible with Windows 8 and need to look for alternative extensions or use newer Windows systems in a virtual machine. Install the necessary extensions to check whether they work properly. Although VS Code is feasible on Windows 8, it is recommended to upgrade to a newer Windows system for a better development experience and security.

VS Code can be used to write Python and provides many features that make it an ideal tool for developing Python applications. It allows users to: install Python extensions to get functions such as code completion, syntax highlighting, and debugging. Use the debugger to track code step by step, find and fix errors. Integrate Git for version control. Use code formatting tools to maintain code consistency. Use the Linting tool to spot potential problems ahead of time.

VS Code extensions pose malicious risks, such as hiding malicious code, exploiting vulnerabilities, and masturbating as legitimate extensions. Methods to identify malicious extensions include: checking publishers, reading comments, checking code, and installing with caution. Security measures also include: security awareness, good habits, regular updates and antivirus software.

Running Python code in Notepad requires the Python executable and NppExec plug-in to be installed. After installing Python and adding PATH to it, configure the command "python" and the parameter "{CURRENT_DIRECTORY}{FILE_NAME}" in the NppExec plug-in to run Python code in Notepad through the shortcut key "F6".
