Skip to main content

Aryan

简介

简单介绍一下本项目有何优点以及为何值得使用

  • 本项目写的很烂源码通俗易懂 方便阅读与使用
  • 作者(也就是我)单纯 善良 可爱 迷人 友善...(省略一万字)

安装

pip install aryan
或使用包管理工具poetry
poetry add aryan

部署

配置mirai-api-http(mah)

本项目要求使用mah v2.0 并开启http与websocket(别问 问就是我懒

配置你的python文件

import asyncio
from aryan import Mirai, MiraiSession, BotConfiguration, Bot
from aryan import GroupMessage, GlobalEventChannel

app = Mirai(
    MiraiSession(
        verify_key="verifyKey",  # 配置mirai-api-http时保存的verifyKey
        host="localhost:8080",  # mah存在的地址
    ),
    loop=asyncio.new_event_loop(),
    bots=[
        Bot(BotConfiguration(account=...)),
        Bot(BotConfiguration(account=...))
    ]
)


async def main(event: GroupMessage):
    print("received event:", type(event))


GlobalEventChannel.INSTANCE.subscribeAlways(GroupMessage, main)

app.launch_blocking()

查看更多用法可以参考这里

如果在使用本项目中遇到任何问题,请不要生气,不要砸电脑,可以提个issue|pr或者加入qq交流群喷项目交流

qq交流群

Release files for aryan 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aryan 0.1.0
File Size Uploaded
aryan-0.1.0.tar.gz 34.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aryan 0.1.0
File Interpreter ABI Platform
aryan-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 78.9 kB

Release files / aryan-0.1.0.tar.gz

Download URL aryan-0.1.0.tar.gz
Size 34.1 kB
Tags Source
SHA-256 checksum
How to use checksums
56e17eed2efe9d3ecb420415e2686f69eca2559b2448afb84e6a92374139c064
BLAKE2b-256 checksum
How to use checksums
637920cb6d16e0703d1d93e60361507a136092ae1a60e1b7174525c39ec01834
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.12 CPython/3.9.10 Windows/10

Release files / aryan-0.1.0-py3-none-any.whl

Download URL aryan-0.1.0-py3-none-any.whl
Size 44.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ad2330ddfd65245428e5e98500cbebeb2aff598f833c00397b629e584c5647b3
BLAKE2b-256 checksum
How to use checksums
4be2b30ec1c5672757f7c6358e959b1a2da1778fece2dd7738eeab79e598f1b4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.12 CPython/3.9.10 Windows/10

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

0.0.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page