正确的sqlite连接类型?

时间:2017-02-02 09:02:47

标签: python python-3.x types type-hinting

仍然是Python打字新手,更换???的正确类型是什么?这里吗?

def update_sqlite(result: dict, db_connection: ???):
    pass

with sqlite3.connect('../data/Reports.db') as report_db:
    update_sqlite(result, report_db)

1 个答案:

答案 0 :(得分:2)

啊,你在谈论PEP 484?正确的类型是sqlite3.Connection