Skip to content

invalid length of startup packet #396

New issue

Have a question about this project? No Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “No Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? No Sign in to your account

Closed
francoricci opened this issue Dec 30, 2018 · 2 comments
Closed

invalid length of startup packet #396

francoricci opened this issue Dec 30, 2018 · 2 comments

Comments

@francoricci
Copy link

  • asyncpg version: 0.18.2
  • PostgreSQL version: 9.6.8
  • Do you use a PostgreSQL SaaS? If so, which? Can you reproduce
    the issue with a local PostgreSQL install?
    : NO
  • Python version: 3.6.7
  • Platform: FreeBSD 11.2
  • 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?
    : YES

import asyncio
import asyncpg
import uvloop

async def run():
conn = await asyncpg.connect(host='127.0.0.1', port='5432', user='root', password='pippo', database='postgres', ssl=None)
values = await conn.fetch("SELECT * FROM pg_type")
await conn.close()

asyncio.set_event_loop_policy(uvloop.EventLoopPolicy())
loop = asyncio.get_event_loop()
loop.run_until_complete(run())

returns:

asyncpg.exceptions.ConnectionDoesNotExistError: connection was closed in the middle of operation
and postgresql:
LOG: invalid length of startup packet

With previous asyncpg version 0.17.0 all works well.
See issue #313

elprans added a commit that referenced this issue Jan 2, 2019
This is a regression of #313, since pgproto had picked up an unfixed
version of hton.h

Fixes: #396
@elprans elprans closed this as completed in ab0bc71 Jan 2, 2019
@elprans
Copy link
Member

elprans commented Jan 2, 2019

Fix released in 0.18.3.

@francoricci
Copy link
Author

Great.
Thanks a lot!!!

No Sign up for free to join this conversation on GitHub. Already have an account? No Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants