MeiCan 美餐
同时支持 Python 3.6+ 与命令行调用的美餐点餐非官方库
山上的朋友! 树上的朋友! 有选择困难症的朋友! 每周都忘记点饭的朋友! 每天都想点同一个套餐的朋友!
👻 懒人们! 快快解放双手来点美餐吧~
背景
最开始是因为我司用的美餐服务, 所以就写了个命令行脚本内部点餐用。
后来发现其实大家会有自己动手实现点单逻辑的需求, 就做成了这个开源库啦。
安装
通过pip:
pip install meican
代码调用
from meican import MeiCan, MeiCanLoginFail, NoOrderAvailable
try:
meican = MeiCan('username@domain', 'hunter2') # login
dishes = meican.list_dishes()
if any(dish for dish in dishes if dish.name == '香酥鸡腿'):
print('今天有香酥鸡腿 :happy:')
else:
print('今天没有香酥鸡腿 :sad:')
except NoOrderAvailable:
print('今天没有开放点餐')
except MeiCanLoginFail:
print('用户名或者密码不正确')
命令行调用
meican # 查询下次点啥菜
meican -o 香酥 # 点包含 香酥 关键字的菜,比如香酥鸡腿
贡献
不论是任何疑问、想要的功能还是想吃的套餐都欢迎直接提 issue
假如你们公司是用熙香点餐的, 隔壁也有熙香的库噢~
😉 欢迎各种 PR
协议
宽松的 MIT 协议:
- ✔ 支持各种改写
- ✔ 支持你把代码作者都改成自己
- ✖ 不支持每天中午免费吃西贝莜面村
- ✖ 也不支持点大羊腿、掌中宝
Metadata
Release files for meican 0.4.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| meican-0.4.3.tar.gz | 8.0 kB | Without provenance | Details for meican-0.4.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| meican-0.4.3-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for meican-0.4.3-py2.py3-none-any.whl |
Total release size: 16.9 kB
Release files / meican-0.4.3.tar.gz
| Download URL | meican-0.4.3.tar.gz |
|---|---|
| Size | 8.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7688d059d9cca4be28e1f7443aebb0df2472d25e3c7dc373353ad1ddc3051503
|
|
BLAKE2b-256 checksum How to use checksums |
11292026f966938e7fe697659070d989aecaa05ac9e7855426cf28a6dd5ac7ff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.9.2
|
Release files / meican-0.4.3-py2.py3-none-any.whl
| Download URL | meican-0.4.3-py2.py3-none-any.whl |
|---|---|
| Size | 8.9 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
26881a8e7620fa0c1430528e3c08aa910ab2131ad937e066ca166d7ece575545
|
|
BLAKE2b-256 checksum How to use checksums |
974e20ce729fe005640e564c8f2587b0eee917d936f58116aed4673f4b6dc767
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.9.2
|
Security for meican 0.4.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.