MagicStack / MagicStack/asyncpg

Split library into two parts: DB-API 2.0 compatible and Asyncio style

オープン
#20 コメント 15 件 リアクション 4 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

enhancement
主要言語
Python
スター
8.1k
フォーク
468
PR マージ指標
30日以内にマージされた PR はありません

説明

I am very interested in using this library since type support in `psycopg2` is awful to work with. However, some projects still use Python 2.7, and will for another 4 years. Would it be possible to split `asyncpg` into two parts, one with an asynchronous API, usable with Python 3.5 and above, and one synchronous API that can be compatible across both 2.7 and 3.5 and above?

My proposal is a DB-API 2.0 ([PEP 249](https://www.python.org/dev/peps/pep-0249/)) compatible API that can be utilized by the `asyncio` part of the library. The benefits is that applications that do not need asynchronous calls can use the same underlying library as those who do. With this code that doesn't rely on co-routines can use the type support provided by `asyncpg`.

I haven't used this project yet, or dived into its internals, and don't know whether it is feasible at all to do this. I am just venting my ideas.

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

この issue では実装ファイルやテストが指定されていません。まず asyncpg の既存の asyncio API を確認し、提案されている同期 DB-API 2.0 インターフェースを PEP 249 および Python 2.7 との互換性と比較してください。これは探索的なアーキテクチャ提案であるため、maintainer はまず実現可能性、スコープ、測定可能な完了状態を定義する必要があります。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
postgresql, python
領域
databases
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
15/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。