V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
abersheeran
V2EX  ›  Python

我写了目前 Python 里唯一一个能正常进行无错误类型推导的 ODM

  •  
  •   abersheeran ·
    abersheeran · 15 天前 · 1695 次点击

    https://github.com/abersheeran/typedmongo

    这个 ODM 的主要功能是类型推导和少量的类型校验与转换,还有好用的查询表达式。另外我有意去除了 None 类型在其中。

    2 条回复    2024-04-30 23:47:38 +08:00
    frostming
        1
    frostming  
       15 天前
    大佬赶紧把 motor 换了,不能让它再假装 aio 了
    abersheeran
        2
    abersheeran  
    OP
       15 天前 via Android
    @frostming 我对追求极致性能这件事兴趣不大。这个 ODM 也是 pymongo 和 motor 都支持,我自己一般是用同步的 pymongo
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   1023 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 20:31 · PVG 04:31 · LAX 13:31 · JFK 16:31
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.