Skip to main content

# mdb

A client to [my database](https://db.marcusweinberger.repl.co)

## Installation

pip install marcusdb

Sorry, mdb was taken

## Usage

import mdb

keys = mdb.generate() # {“priv”:”XXXXXXXX”, “pub”:”XXXXXXXXX”} # tip: the public key is just a hashed version of the private key [sha256(sha256(key) + salt)] # protip: you can choose your own key using mdb.register(“YOUR_TOKEN_HERE”), but remember - if your token isn’t secure, someone could crack the hash

privclient = mdb.Client(keys[‘priv’]) pubclient = mdb.Client(keys[‘pub’]) # yep, both use the same class. attempting priv methods with pub keys just dont work

privclient.store(“hello”, “world”) # can store all types of data by using the jsonpickle library

pubclient.retrieve(“hello”) # > “world”

pubclient.store(“test”, “wa”) # will return False

privclient.delete(“hello”) # returns True

privclient.unregister(conf=True) # conf defaults to false, when false will do nothing # deletes your account from the DB, making both keys invalid and out of the system

## Github: [https://github.com/AgeOfMarcus/mdb](https://github.com/AgeOfMarcus/mdb) ## View post on repl.it: [post & demo](https://repl.it/talk/share/MDB-A-database-with-seperate-readwrite-keys-perfect-for-small-projects-to-store-JSON/35762)

Metadata

Release files for marcusdb 1.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for marcusdb 1.0.2
File Size Uploaded Provenance Actions
marcusdb-1.0.2.tar.gz 2.3 kB Without provenance Details for marcusdb-1.0.2.tar.gz

Release files / marcusdb-1.0.2.tar.gz

Download URL marcusdb-1.0.2.tar.gz
Size 2.3 kB
Tags Source
SHA-256 checksum
How to use checksums
676b54f8fdd3c1cc803ad2eacdc561835f2d5581451b21b35be191b533851aa8
BLAKE2b-256 checksum
How to use checksums
6f3862fe27997fb88760fc516940a7313fb07ff997f48f367432d83aac2739d1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.8.0 tqdm/4.45.0 CPython/3.8.2

Security for marcusdb 1.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page