python project_utils tools
Project description
project-utils
介绍
project-utils 基于python3 的工具包
软件架构
使用时继承相应类即可
安装教程
pip3 install project-project_utils-2023
使用说明
- 安装以下格式创建工程
-
config
- config.ini
[BASE] data_url = data log_url = logs output_url = output tmp_url = tmp [MYSQL] host = port = user = password = database = [REDIS] host = port = password = db = [SYSTEM] path =
- config.ini
-
data
-
logs
-
output
-
src
-
tmp
-
example
import asyncio
from project_utils.web.django import CeleryConfig
from new_utils import settings
class Config(CeleryConfig):
settings = settings
max_length = 256
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.loop = asyncio.get_event_loop()
def django_setting_init(self):
super().django_setting_init()
# self.settings.DEBUG = False
self.add_allowed_hosts("*")
self.add_app("rest_framework")
self.add_app("user")
self.add_middleware("middleware.my_middle.MyMiddleware")
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
project-utils-django-1.0.4.tar.gz
(28.9 kB
view hashes)
Built Distribution
Close
Hashes for project-utils-django-1.0.4.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | c78fa10d40fe8243d4a690f40f30ca59c20b08fe7c16560fc28c588b1128f9a4 |
|
MD5 | e65fb53a777335af6a33b00f1b0f6340 |
|
BLAKE2b-256 | 08b97acc93d2d43c1c7714fe0f003deb6a9e8020a8a8d71dac4af14ce53b8865 |
Close
Hashes for project_utils_django-1.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 554488b6e019e6dcee9ba6f25f11ccab200154a14382497a992abb1b89389cef |
|
MD5 | e2a855ffaa9f771b120707744f9f8fe2 |
|
BLAKE2b-256 | 7a094e778f5cafbe70aa4ff5f90bd474fd799fdd56284dd65763b7b2e0ad299e |