Are there plans to develop an official Python driver for Realm?

Are there plans to develop an official Python driver for Realm?

1 Like

Not at this time, although there is a Python driver for Atlas here:

Hi @Platon_workaccount - thanks for your question!

As Ian says, there aren’t any imminent plans to work on a Python driver. But I was wondering if you could tell us what kind of thing you wanted to build with one?

Mark

I am developing a bioinformatics toolkit and I want to replace SQLite with serverless NoSQL-DBMS, which provides the most pythonic syntax (without any ORM). My other ongoing and planned projects also need this solution.

Oh, in that case I think you probably want to look at the Python drivers for MongoDB that @Ian_Ward recommended - I think they’re what you want. Check out MongoDB Atlas for a hosted database-as-a-service!

I develop software for ordinary personal computers (e.g. laptops). MongoDB is redundant for most of my projects. It is a huge enterprise product for large servers. Atlas is a commercial product that is not suitable for integration into FLOSS. TinyDB would be a good fit, but it is not capable of creating indices. SQLite is the best solution at the moment. But the SQL instructions integrated into Python code look ugly. ORMs give an inadequate complex syntax. Realm looks attractive, but for some reason it does not have a driver of the very popular Python language.

Ah, I see.

MongoDB is a server product, but I wouldn’t describe it as a huge enterprise product (although it can totally be run that way). We support the Raspberry Pi as a host platform! On the other hand, it sounds like you need an embedded database along the lines of SQLite, but without the SQL.

The reason Realm doesn’t currently support Python is because it’s traditionally been a mobile library, and so iOS and Android were the target platforms, hence Java/Kotlin and Swift were the supported language. We’ve been adding more support for other platforms but it’s still relatively early days. As a Python developer myself, I definitely hope we add Python support to Realm in the not-too-distant future!

Have you tried using SQLAlchemy on top of SQLite to work with your models? I think it may give you some of what you’re looking for, but you would need to set up the object-table mappings yourself.

3 Likes

Thanks for the answers!

In my practice, ORMs make the code bloated, difficult to maintain, exposed to bugs.

Seems like you have a cool use case! I just searched feedback.mongodb.com and didn’t find any feedback about a Python SDK for Realm but I bet you’re not the only one out there who would love to use Realm in their Python apps.

I recommend that you create a new suggestion on the Realm section of the feedback site so that others can upvote the idea to help the team get a better feel for how many folks want a Python SDK. I’ll upvote it!

5 Likes

Unfortunately, https://feedback.mongodb.com/ does not open. Its IP 104.17.30.92 is blocked in Russia.

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.