Add your description here
Project description
asa
一个示例 Python 库,用来演示如何打包和发布到 PyPI。
安装
通过 PyPI 安装时,项目名是 asabot:
pip install asabot
安装后导入名仍然是 asa:
from asa import Bot, on_group_message, on_keyword, Event
bot = Bot(
ws_url="ws://127.0.0.1:3001",
http_url="http://127.0.0.1:3000",
token="your-napcat-token", # 也可以用环境变量 NAPCAT_TOKEN
)
@on_group_message
@on_keyword("ping", "测试")
async def handle_ping(event: Event, bot: Bot):
# 这里处理收到的消息
print("got message:", event.text)
bot.run()
开发
pip install -e .[dev]
pytest
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
asabot-0.1.0.tar.gz
(12.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
asabot-0.1.0-py3-none-any.whl
(16.5 kB
view details)
File details
Details for the file asabot-0.1.0.tar.gz.
File metadata
- Download URL: asabot-0.1.0.tar.gz
- Upload date:
- Size: 12.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0b7542977f14b7551657fab3ebe720daa639727b5a6a2cac05b4970af26a57fa
|
|
| MD5 |
a543d5c3778456ab4f2b0fc64d9c6e03
|
|
| BLAKE2b-256 |
c51e83a9e8e50cb695793e79f458ce18cc227b55a28f6c6084f5c4bc8772180c
|
File details
Details for the file asabot-0.1.0-py3-none-any.whl.
File metadata
- Download URL: asabot-0.1.0-py3-none-any.whl
- Upload date:
- Size: 16.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3631d8a2a616cbb7262a6a4586fa2cdc630faba533c05a99f1a58c834216d5b5
|
|
| MD5 |
deefd2cf8023764abed7299720957a47
|
|
| BLAKE2b-256 |
075005a41bdc07a8e67e8a808bf32663cd8b0b7afec3e4a4354c0fcdb5dd9aeb
|