pymgclient 1.0.0 Release
Introduction
It’s been a little over a year since we announced the first version of official Memgraph drivers for Python and C. We have since launched a number of new Memgraph features including replication, and an improved storage engine, while the language drivers remained mostly the same. The mgclient (C driver) and pymgclient (Python driver) were updated to use the latest Bolt protocol, but that wasn’t a major change.
For many of you, working with Memgraph’s drivers, especially the pymgclient (Python driver) was a bit tricky at times, and so we made it our priority to release a new and improved version as soon as possible.
Today, we’re happy to announce the release of pymgclient 1.0.0. In this post we’ll go over what’s new and how it will be useful to you in your next Memgraph project.
Easier and cross-platform installation
Many of you told us that you found it cumbersome to have to install and update the correct version of mgclient just to be able to use pymgclient. We heard your message loud and clear and we delivered! From now on, pymgclient includes mgclient, therefore you don’t need to worry about installing it first.
Next comes cross-platform installation. Since mgclient is now cross-platform, it was obvious that pymgclient had to follow. Although the decision was easy, the implementation proved to be tricky due to the differences between operating systems and details related to the Python ecosystem.
You can read how to install pymgclient in our documentation, but we can tell you that if you’re using one of the most common operating systems (Windows 10, macOS 10.15+, various Linux distributions such as Debian 9+, Ubuntu 18.04+ or CentOS 8+), you can install pymgclient with a single command:
$ pip3 install pymgclient
Easy-peasy, isn’t it? If for some reason it doesn’t work out of the box, please have a look at the documentation for detailed instructions. If you still cannot figure out how to install it, feel free to ask us on our [community forum].
Improved stability
Although we are always aiming to bring the best possible software, we are still humans. And what do humans usually do? You are right, humans make mistakes. As a result, there were a few bugs that made their way into the first version of pymgclient.
In this release, we completed a few important bug fixes (no worries, no bugs were harmed, they still live happily in the history of the pymgclient git repository) that made pymgclient much more stable. As a results, we:
- Drastically reduced the memory usage in some cases by eliminating memory leaks.
- Ensured that transactions are correctly handled when an error happens in explicit transaction mode.
If you find anything we missed, please submit a pull request on GitHub!