Home

wq.db

wq.db is a collection of Python modules for building robust, flexible schemas and REST APIs for use in creating field data collection apps and (more generally) mobile-first websites with progressive enhancement. wq.db is the backend component of wq and is geared primarily for use with wq.app, though it can be used separately. wq.db is built on the Django platform.

Latest PyPI Release Release Notes Documentation License GitHub Stars GitHub Forks GitHub Issues

Travis Build Status Python Support Django Support

Support Matrix

wq.db 1.1.0 is compatible with Django 1.11 and newer, and optimized for Python 3.

  Python Django Django REST Framework
wq.db 1.0.0 2.7, 3.4, 3.5, 3.6 1.8, 1.10, 1.11 3.6
wq.db 1.1.0 2.7*, 3.4, 3.5, 3.6 1.11, 2.0 3.8
wq.db 2.0 (Future) 3.4+ 2.0+ TBD

* Python 2.7 support is no longer tested, though it should still work for now.

Getting Started


# Recommended: create virtual environment
# python3 -m venv venv
# . venv/bin/activate

# Install entire wq suite (recommended)
pip install wq

# Install only wq.db
pip install wq.db

See the documentation for more information.

Features

wq.db provides the following modules:

wq.db.rest

Extends the excellent Django REST Framework with a collection of views, serializers, and context processors useful for creating a progresively enhanced website that serves as its own mobile app and its own REST API. The core of the library is an admin-like ModelRouter that connects REST urls to registered models, and provides a descriptive configuration object for consumption by wq.app's client-side router. wq.db.rest also includes a GeoJSON serializer/renderer.

wq.db.patterns

A collection of abstract models and serializers for use in constructing advanced design patterns including nested forms, EAV structures, and natural keys. Includes wq.db.patterns.identify, an installable Django app module to help manage third-party entity identifers.