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.7.tar.gz
(28.9 kB
view hashes)
Built Distribution
Close
Hashes for project-utils-django-1.0.7.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 012a7113b1490f0ba3c565276e7abb4300f8c02564fd6e17750cf73d8d1528f2 |
|
MD5 | 19a438574a9f96e1994d12cb3fccefb2 |
|
BLAKE2b-256 | 70f49fefe116f2d18c68b0a734b2cea469787bbda9820717e79abea6153c51a6 |
Close
Hashes for project_utils_django-1.0.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e7c1a8c1b4733ac18a0a6b32b733779a077a83a323e389a1b438debe3aec59d |
|
MD5 | 08d7256aed73f3a3a3a2adb3bee98250 |
|
BLAKE2b-256 | e988c150ba9d49ac79d16e80b7641947095766be467f66f323acba93f63ccb3c |