Publish package on pypi

In the project directory, do the following: Profile: import io import os from setuptools import setup, find_packages with io.open(os.path.join("docs", 'index.rst'), encoding='utf-8') as f: readme = f.read() with io.open('requirements.txt') as f: requirements = f.readlines() setup( name="xxx", version="0.0.1", url='https ...

Posted on Wed, 01 Apr 2020 06:05:35 -0700 by IchBin

036 thread process (important)

Compared with Java, python is much simpler, which can be understood by one example###########################There are two ways to create a thread. The first is to directly create a thread and put the method into it. This is the first way:Create a thread object, set the parameters of the method to be executed and the parameters of the method, a ...

Posted on Tue, 31 Mar 2020 18:59:33 -0700 by vestax1984

Add python installation information to the registry

Add python installation information to the registry background After reinstalling the system, I found that the python installed on disk E can be used directly. I just added the installation directory of Python to the environment variable, but I didn't care about it all the time. I found it was not successful when I ...

Posted on Tue, 31 Mar 2020 17:36:05 -0700 by pozer69

web development based on hi nginx (python) -- cookie and session management

Hi nginx manages sessions through redis. Three things need to be done to start management. First open userid: userid on; userid_name SESSIONID; userid_domain localhost; userid_path /; userid_expires 300s; This function is built in nginx and can ...

Posted on Tue, 31 Mar 2020 17:10:29 -0700 by Avi

python learning notes (2): numpy Foundation

Counter function can count the number of data in the list Most common (10) can extract the top ten bits from collections import Counter a = ['q','q','w','w','w'] count = Counter(a) count.most_common(1) [('w', 3)] count Counter({'q': 2, 'w': 3}) The series object in panda has a value "counts method to count The. fillna() function can rep ...

Posted on Tue, 31 Mar 2020 16:48:30 -0700 by ChrisF79

python full stack development - Day3 string

python full stack development - Day3 string 1, Expand string learning according to the following points Chen 1: basic use 1, use #First of all, the main function of string: name, gender, nationality, address and other description information2. How to define In single quotation mark \ double quotation mark \ triple quotation mark, it is composed ...

Posted on Tue, 31 Mar 2020 13:31:05 -0700 by sstangle73

Python learning notes (10) Python collection (1)

review int/float/str/list/tuple/dict Integers and floats are immutable, not sequences Strings are immutable, they are sequences List is variable, it's sequence Tuples are immutable. They are sequences Dictionaries are changeable, but not sequential   The basic concept of set Set is A basic mathematical concept. It is the research object of set ...

Posted on Tue, 31 Mar 2020 08:26:00 -0700 by drath

3.21 study database design of python operation database authority system

pip3 download pymysql Python operation Mysql #pypi inside pip3 install pymysql 2. Use pymysql def yanga11ang(): #------------------1. Execute SQL--------------------------- import pymysql # Create connection conn = pymysql.connect(host='127.0.0.1', port=3306, user='root', passwd='654321', db='t1',charset='utf8') # ...

Posted on Tue, 31 Mar 2020 07:04:26 -0700 by Errant_Shadow

python from introduction to practice Chapter 6 exercises (Advanced Programming Technology week3-2)

python from introduction to practice Chapter 6 exercises (Advanced Programming Technology week3-2) This lesson is mainly about the use of dictionary data structure in python. Basic use of dictionary 6-1 person dict={ "first_name" : "Walker", "last_name" : "Mike", "age" : "18", "city" : "New York", } p ...

Posted on Tue, 31 Mar 2020 06:43:19 -0700 by scratchwax2003

Django FBV/CBV, middleware, GIT use

s5day82 //Content review: 1. Http Request essence Django Procedure: socket Server side a. Server monitoring IP And port c. Acceptance request \r\n\r\n: Request header and body \r\n & request.POST ...

Posted on Tue, 31 Mar 2020 01:58:35 -0700 by ruano84