Skip to main content

MongoDB-like document store using SQLite

Project description

pylitemongo

English | فارسی


English

📌 Overview

pylitemongo is a lightweight, MongoDB-like document store built on top of SQLite. It offers a familiar API for managing JSON-like documents without requiring a separate database server. Ideal for small-scale applications, rapid prototyping, or embedded use cases.


✨ Features

  • MongoDB-style operations (insert, find, update, delete)
  • Powered by SQLite (no external dependencies)
  • Fast and minimal footprint
  • Written entirely in Python
  • Seamless integration with existing Python projects

📦 Installation

pip install pylitemongo

🚀 Quick Start

from pylitemongo import Database

db = Database("mydata.db")
users = db["users"]

users.insert({"name": "Alice", "age": 25})
users.insert({"name": "Bob", "age": 30})

for user in users.find({"age": 25}):
    print(user)

users.update({"name": "Alice"}, {"$set": {"age": 26}})
users.delete({"name": "Bob"})

📚 Documentation

  • Database: SQLite-backed document store
  • Collection: MongoDB-like methods (insert, find, update, delete)
  • Supports basic query operators: $eq, $gt, $lt, $set

🛠 Requirements

  • Python 3.6+
  • SQLite (included with Python)

🧪 Testing

git clone https://github.com/yourusername/pylitemongo.git
cd pylitemongo
pip install -r requirements-dev.txt
pytest

🤝 Contributing

We welcome contributions!

  • Fork the repo
  • Create a branch (git checkout -b feature-name)
  • Commit your changes (git commit -m "Add feature")
  • Push the branch (git push origin feature-name)
  • Open a Pull Request

📜 License

MIT License


فارسی

📌 معرفی

pylitemongo یک کتابخانه سبک برای ذخیره‌سازی داده‌ها به صورت سندمحور است که بر پایه SQLite ساخته شده. این ابزار برای پروژه‌های کوچک، نمونه‌سازی سریع یا استفاده در برنامه‌هایی که نیاز به پایگاه‌داده سنگین ندارند، مناسب است.


✨ ویژگی‌ها

  • عملیات مشابه MongoDB (insert، find، update، delete)
  • استفاده از SQLite به عنوان پایگاه‌داده داخلی
  • سبک، سریع و بدون وابستگی خارجی
  • پیاده‌سازی کامل با پایتون
  • قابل استفاده در پروژه‌های پایتونی موجود

📦 نصب

pip install pylitemongo

🚀 شروع سریع

from pylitemongo import Database

db = Database("mydata.db")
users = db["users"]

users.insert({"name": "Ali", "age": 25})
users.insert({"name": "Sara", "age": 30})

for user in users.find({"age": 25}):
    print(user)

users.update({"name": "Ali"}, {"$set": {"age": 26}})
users.delete({"name": "Sara"})

📚 مستندات

  • Database: مدیریت پایگاه‌داده SQLite
  • Collection: متدهای مشابه MongoDB (insert، find، update، delete)
  • پشتیبانی از عملگرهای ساده مانند $eq، $gt، $lt، $set

🛠 پیش‌نیازها

  • پایتون 3.6 یا بالاتر
  • SQLite (به صورت پیش‌فرض همراه پایتون)

🧪 تست

git clone https://github.com/yourusername/pylitemongo.git
cd pylitemongo
pip install -r requirements-dev.txt
pytest

🤝 مشارکت

خوشحال می‌شویم اگر مشارکت کنید!

  • ریپازیتوری را Fork کنید
  • یک Branch جدید بسازید (git checkout -b feature-name)
  • تغییرات خود را Commit کنید (git commit -m "افزودن ویژگی جدید")
  • Branch را Push کنید (git push origin feature-name)
  • یک Pull Request باز کنید

📜 مجوز

این پروژه تحت مجوز 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

pylitemongo-0.1.1.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pylitemongo-0.1.1-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file pylitemongo-0.1.1.tar.gz.

File metadata

  • Download URL: pylitemongo-0.1.1.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for pylitemongo-0.1.1.tar.gz
Algorithm Hash digest
SHA256 42333f2ab0c33413fcac242ee5d5382f4e8217742d69986db3ffd64af12637bb
MD5 cf565739b309d078c452051a642cd73f
BLAKE2b-256 b0e743abdf803d12291af08255746e85dde00d1eb16371eb0db980726946a6b0

See more details on using hashes here.

File details

Details for the file pylitemongo-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pylitemongo-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for pylitemongo-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4c28bdf0dc90f88201f0d4da3c932838dfca6a9a13ceb16b52f9b3bb9eedc5f0
MD5 cbd79b4e0b5f4b0b639f79537a536dc0
BLAKE2b-256 aa37f9ead1b3a3311e4639e32a60e1eafbabfcf576909f1bf59c322b9688041f

See more details on using hashes here.

Supported by

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