Code Monkey home page Code Monkey logo

tarantool-python's Introduction

Python driver for Tarantool

https://github.com/tarantool/tarantool-python/actions/workflows/testing.yml/badge.svg?branch=master https://github.com/tarantool/tarantool-python/actions/workflows/packing.yml/badge.svg?branch=master

This package is a pure-python client library for Tarantool.

Documentation | Downloads | PyPI | GitHub | Issue tracker

Download and install

With pip (recommended)

The recommended way to install the tarantool package is using pip.

$ pip3 install tarantool

With dnf

You can install python3-tarantool RPM package if you use Fedora (34, 35, 36).

Add the repository

$ curl -L https://tarantool.io/OtKysgx/release/2/installer.sh | bash

and then install the package

$ dnf install -y python3-tarantool

With apt

You can install python3-tarantool deb package if you use Debian (10, 11) or Ubuntu (20.04, 22.04).

Add the repository

$ curl -L https://tarantool.io/OtKysgx/release/2/installer.sh | bash

and then install the package

$ apt install -y python3-tarantool

ZIP archive

You can also download zip archive, unpack it and run:

$ make install

Development version

You can also install the development version of the package using pip.

$ pip3 install git+https://github.com/tarantool/tarantool-python.git@master

What is Tarantool?

Tarantool is an in-memory computing platform originally designed by VK and released under the terms of BSD license.

Features

  • ANSI SQL, including views, joins, referential and check constraints
  • Lua packages for non-blocking I/O, fibers, and HTTP
  • MessagePack data format and MessagePack-based client-server protocol
  • Two data engines:
    • memtx โ€“ in-memory storage engine with optional persistence
    • vinyl โ€“ on-disk storage engine to use with larger data sets
  • Secondary key and index iterator support (can be non-unique and composite)
  • Multiple index types: HASH, BITSET, TREE, RTREE
  • Asynchronous master-master replication
  • Authentication and access control

See More

NOTE

This driver is synchronous, so connection mustn't be shared between threads/processes.

If you're looking for an asynchronous Python driver based on asyncio, consider using asynctnt . See also the feature comparison table.

Run tests

On Linux:

$ make test

On Windows:

  • Setup a Linux machine with Tarantool installed. This machine will be referred to as remote in this instruction.
  • (On remote) Copy test/suites/lib/tarantool_python_ci.lua to /etc/tarantool/instances.available.
  • (On remote) Run tarantoolctl start tarantool_python_ci.
  • Set the following environment variables: * REMOTE_TARANTOOL_HOST=..., * REMOTE_TARANTOOL_CONSOLE_PORT=3302.
  • Run make test.

Build docs

To build documentation, first you must install its build requirements:

$ pip3 install -r docs/requirements.txt

Then run

$ make docs

You may host local documentation server with

$ python3 -m http.server --directory build/sphinx/html

Open localhost:8000 in your browser to read the docs.

License

BSD-2-Clause. See the LICENSE file.

tarantool-python's People

Contributors

differentialorange avatar coxx avatar bigbes avatar totktonada avatar rtsisyk avatar shveenkov avatar amdrozdov avatar ligurio avatar artembo avatar kostja avatar funny-falcon avatar vemel avatar grishnov avatar askalt avatar denis-ignatenko avatar oleg-jukovec avatar ylobankov avatar runsfor avatar vmarunov avatar kbelyavs avatar olegrok avatar mejedi avatar xhaskx avatar monolithed avatar avtikhon avatar bekhzod91 avatar unera avatar zimnukhov avatar curiousgeorgiy avatar ilmarkov avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.