surrealdb/surrealdb.py

WebSocket client revision

Ce11an opened this issue ยท 1 comments

Hello everyone! ๐Ÿ‘‹๐Ÿป

I have been using SurrealDB more frequently and also looking at the other client libraries in the Surreal family. Recently, I tried my hand at writing my own SurrealDB WebSocket client using websockets to handle the boilerplate, pydantic for validation, and closely following the syntax of the JavaScript library. You can find the code in my Gist ๐Ÿ‘จ๐Ÿปโ€๐Ÿ’ป

I was hoping that the community could take a look and suggest any improvements that could be implemented into the main Python library. This is my first time working with WebSockets in Python, so I would appreciate any feedback ๐Ÿ˜„

Packages used:

You can set up a user table by following this tutorial. This Python implementation was greatly influenced by the JavaScript equivalent.

Thanks ๐Ÿš€

Thanks a ton for the suggestions and code in the gist! โค๏ธ , most of it has been merged now, so I'm closing this issue