MagicStack / MagicStack/asyncpg

Does COPY FROM gaurentee no partial rows?

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

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

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

説明

A quick question, since this is not very obvious from the postgres or asyncpg docs: under what circumstances, if any, does `copy_from_query` guarantee that no partial rows will be delivered to the `output` coroutine?

In my experience this hasn't happened, and I could try some more exhaustive testing, but I imagine/hope that someone might just already know the answer.

To me the options seem to be:
- If the networking code reads one line at a time, then the 'text' format guarantees full rows, but not necessarily 'csv' or 'binary'
- Asyncpg itself or postgres itself may explicitly implement such a guarantee?
- Otherwise, there is no guarantee.

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

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

はじめの一歩

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

調査の方向性

PostgreSQL と asyncpg の copy_from_query に関するドキュメントから始め、利用可能な asyncpg の資料でその出力コルーチンがどのように説明されているかを追跡してください。テキスト、CSV、バイナリの出力が部分的な行を回避する条件がある場合はそれを文書化し、その保証をユーザーに明確に示してください。

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

評価

技術スタック
postgresql, python
領域
databases
issue の種類
ドキュメント
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
35/100

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

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