MagicStack / MagicStack/asyncpg
copy_from_query output function receives bytearray
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Python
- Sterne
- 8.1k
- Forks
- 468
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
* **asyncpg version**: 0.25.0
* **PostgreSQL version**: 13.4 (Ubuntu 13.4-1.pgdg21.04+1) + Timescale 2.4.2
* **Do you use a PostgreSQL SaaS? If so, which? Can you reproduce
the issue with a local PostgreSQL install?**:
* **Python version**: 3.9.7
* **Platform**: Ubuntu 21.10
* **Do you use pgbouncer?**: No
* **Did you install asyncpg with pip?**: Yes
* **If you built asyncpg locally, which version of Cython did you use?**:
* **Can the issue be reproduced under both asyncio and
[uvloop](https://github.com/magicstack/uvloop)?**: Could not try without uvloop because of https://github.com/MagicStack/asyncpg/issues/240
Hi! The [documentation](https://magicstack.github.io/asyncpg/current/api/index.html?highlight=copy_from_query#asyncpg.connection.Connection.copy_from_query) states that a coroutine function passed as `output` argument will receive a `bytes` argument, but when I do this I get `bytearray`. Seems like a bug either with documentation or the code.
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Start with the Connection.copy_from_query entry point and its API documentation, which state that the output coroutine receives bytes. Trace the value passed to output and compare it with the documented behavior. Done means confirming whether the code or documentation is incorrect and covering the agreed behavior with a regression test.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- postgresql, python
- Bereich
- databases
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 45/100