Sonel
Sonel

Reputation: 11

PyCharm exit code -1073741819

I'm using PyChram version 2023.2, Windows 10 and PostgreSQL 15 (SQLAlchemy 1.3.24 and gino 1.0.1 to connect) I get the error Process finished with exit code -1073741819 (0xC0000005) when I try to run the code in debug mode Ctrl + F5. How can I fix this problem?

from gino import Gino
import asyncio

db = Gino()


class User(db.Model):
    __tablename__ = 'users'

    id = db.Column(db.Integer(), primary_key=True)
    nickname = db.Column(db.Unicode(), default='noname')


async def main():
    await db.set_bind('postgresql://postgres:admin@localhost/gino')
    await db.gino.drop_all()
    await db.gino.create_all()


asyncio.get_event_loop().run_until_complete(main())
# asyncio.run(main())

Everything works in VS Code. If replace async io.get_event_loop().run_until_complete(main()) with synco.ru (main()), then the code will also run in PyCharm.

Upvotes: 1

Views: 104

Answers (0)

Related Questions