Skip to main content

Nested OBject manipulations

Project description

Documentation Status

nob: the Nested OBject manipulator

Deep nested data is sometimes difficult to map with objects in an Object Relational Mapping (ORM) appraoch. Suppose e.g. you're working with this file:

root:
  System:
    Library:
      Frameworks:
        Python.framework:
          Versions:
            2.7:
              bin: python2.7

If you wanted the last value here using pure Python, you would have to write something like:

pure_python['root']['System']['Library']['Frameworks']['Python.framework']['Versions']['2.7']['bin']

Gosh that's bad, it doesn't even fit in the screen! This is where nob shines: it offers a simple set of tools to explore and edit any nested data (Python native dicts and lists). With nob, this becomes:

nob_object['bin'][:]

Pretty neat, no? For more, checkout nob's documentation.

Installation

pip install nob

Enough said :)

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

nob-0.6.1-py2.py3-none-any.whl (11.5 kB view hashes)

Uploaded Python 2 Python 3

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