Skip to main content

MongoFrames logo

MongoFrames

Build Status Join the chat at https://gitter.im/GetmeUK/ContentTools

MongoFrames is a fast unobtrusive MongoDB ODM for Python designed to fit into a workflow not dictate one. Documentation is available at MongoFrames.com and includes:

Installation

We recommend you use virtualenv or virtualenvwrapper to create a virtual environment for your install. There are several options for installing MongoFrames:

  • pip install MongoFrames (recommended)
  • easy_install MongoFrames
  • Download the source and run python setup.py install

Dependencies

10 second example

from mongoframes import *

# Define some document frames (a.k.a models)
class Dragon(Frame):
    _fields = {'name', 'loot'}

class Item(Frame):
    _fields = {'desc', 'value'}

# Create a dragon and loot to boot
Item(desc='Sock', value=1).insert()
Item(desc='Diamond', value=100).insert()
Dragon(name='Burt', loot=Item.many()).insert()

# Have Burt boast about his loot
burt = Dragon.one(Q.name == 'Burt', projection={'loot': {'$ref': Item}})
for item in burt.loot:
    print('I have a {0.name} worth {0.value} crown'.format(item))

Testing

To test the library you'll need to be running a local instance of MongoDB on the standard port.

To run the test suite: py.test To run the test suite on each supported version of Python: tox

Helpful organizations

MongoFrames is developed using a number of tools & services provided for free by nice folks at organizations committed to supporting open-source projects including GitHub and Travis CI.

Download files

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

Source Distribution

MongoFrames-1.3.10.tar.gz (31.2 kB view details)

Uploaded Source

File details

Details for the file MongoFrames-1.3.10.tar.gz.

File metadata

  • Download URL: MongoFrames-1.3.10.tar.gz
  • Upload date:
  • Size: 31.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.12

File hashes

Hashes for MongoFrames-1.3.10.tar.gz
Algorithm Hash digest
SHA256 8a1a3bb4fcbc011965c9839d290bcbd24004785d42e289a623282036980f886a
MD5 948dfdcf41014e3af4e7569da73a8ea8
BLAKE2b-256 2476b6af8b2db6dc51b264c9b384242317f4d223a9f315930911fad6a1246d0c

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.3.10 This release

1 file

1.3.9

1 file

1.3.8

1 file

1.3.7

1 file

1.3.6

1 file

1.3.5

1 file

1.3.4

1 file

1.3.3

1 file

1.3.2

1 file

1.3.1

1 file

1.3.0

1 file

1.2.14

1 file

1.2.13

1 file

1.2.12

1 file

1.2.11

1 file

1.2.10

1 file

1.2.9

1 file

1.2.8

1 file

1.2.7

1 file

1.2.6

1 file

1.2.5

1 file

1.2.4

1 file

1.2.3

1 file

1.2.2

1 file

1.2.1

1 file

1.2.0

1 file

1.1.2

1 file

1.1.1

1 file

1.1.0

1 file

1.0.3

1 file

1.0.2

1 file

1.0.1

1 file

1.0.0

1 file

Supported by

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