Skip to main content

Table support for the replit database

Reason this release was yanked:

dependencies not changed

Project description

repltable

PyPI - Downloads code style

this is a project is to make it so that you can have tables in the replit db.

the main annoyance (for me) with replit is that it reverts a lot of database file changes, which forces you to use the repl.it database.

installation

pip install repltable

usage

import repltable
from replit import db

database = repltable.Database(db)

# repltable databases work like a dictionary
database['table'].get(foo='bar')
>>> [{'foo': 'bar'}]

# repltable auto-creates tables if they don't exist
table = database['nonexistenttable']
table.insert(dict(foo='bar'))

# you can get one, or get all matching documents
table.get_one(foo='bar')
>>> {'foo': 'bar'}

contributing

to contribute, fork the repo, make a branch, and send a pull request.

for local development, you can install the dependencies with poetry:

poetry install

license

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

repltable-0.1.6.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

repltable-0.1.6-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file repltable-0.1.6.tar.gz.

File metadata

  • Download URL: repltable-0.1.6.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.7 CPython/3.8.10 Linux/5.10.16.3-microsoft-standard-WSL2

File hashes

Hashes for repltable-0.1.6.tar.gz
Algorithm Hash digest
SHA256 76af1e9de58dd2c99b262a1a3c75d710b2eea1c8041c5ebdebc3d935ceaa55d6
MD5 8c2bf682e159a3f6095c0e77f15569e3
BLAKE2b-256 aa4647e9120d815b9d758a8167ada60ce13fc6da42647f0a41ab620539048e5c

See more details on using hashes here.

File details

Details for the file repltable-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: repltable-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 2.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.7 CPython/3.8.10 Linux/5.10.16.3-microsoft-standard-WSL2

File hashes

Hashes for repltable-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 bd1235d7865395c746f7344057b917ab886cc93f4ebe06db120e4f305dec30fa
MD5 b4ab27f213912746cdff140d170231cb
BLAKE2b-256 b0cbb526b1d26de3dc3acb2cbe8fba1541264816ce06bf57e3bcb865fca8c83f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page