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.2.tar.gz
(28.9 kB
view hashes)
Built Distribution
Close
Hashes for project-utils-django-1.0.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | e8e029dd35f1ff74ffd7b3329e1b6f01fdd2aad22934c14bb661484b46cfc674 |
|
MD5 | 919adeebada6557ac5625b9fde10a9ef |
|
BLAKE2b-256 | ec9cdd03f86c6365d0418583a709796b100e17ffdd468b0ba119edcb20951f0f |
Close
Hashes for project_utils_django-1.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | abfca9b41ec0712d2662fe765929a3f2308485c811df2767d30a4b62b64bd8a9 |
|
MD5 | e1fa97821adccddfb84c4a546e422c73 |
|
BLAKE2b-256 | b2b8be7ddd1125849b2b23bdb0a3ecb8818270c6ed4ac8779d52f6e29d84584f |