Skip to main content

ZODB browser

Project description

The ZODB browser allows you to inspect persistent objects stored in the ZODB, view their attributes and historical changes made to them.

Usage as a standalone project

Install all the dependencies into the source tree with zc.buildout:

python bootstrap.py
bin/buildout

Run bin/zodbbrowser specifying either a filename or a ZEO address

bin/zodbbrowser /path/to/Data.fs
bin/zodbbrowser --zeo localhost:9080
bin/zodbbrowser --zeo /path/to/zeosock

If you don’t have a spare Data.fs to test with, you can create a new empty one with just the barest Zope 3 scaffolding in it:

bin/zodbbrowser empty.fs --rw

Open http://localhost:8070 in a web browser. Note that there are no access controls; all other users on the local machine will be able to access the database contents.

Or you could try to use easy_install. It may work or it may not, depending on the current state of all the dependencies (buildout.cfg hardcodes dependency version to a known-working-together state, called the “Zope 3.4 Known Good Set”, so buildout-based installs are safer)

easy_install zodbbrowser[app]
zodbbrowser /path/to/Data.fs

Command-line options

Run bin/zodbbrowser --help to see a full and up-to-date list of command-line options:

Usage: zodbbrowser [options] [FILENAME | --zeo ADDRESS]

Open a ZODB database and start a web-based browser app.

Options:
  -h, --help        show this help message and exit
  --zeo=ADDRESS     connect to ZEO server instead
  --listen=ADDRESS  specify port (or host:port) to listen on
  --rw              open the database read-write (allows creation of the
                    standard Zope local utilities if missing)

Online help

There’s a little ‘help’ link in the bottom-right corner of every page that describes the user interface in greater detail.

Usage as a plugin

Add zodbbrowser to the list of eggs (e.g. in buildout.cfg of your app) and add this to your site.zcml:

<include package="zodbbrowser" />

Rerun bin/buildout, restart Zope and append @@zodbbrowser to the end of the URL to start browsing, e.g. http://localhost:8080/@@zodbbrowser. Or, if you still use ZMI (the Zope Management Interface), look for a new menu item titled “ZODB Browser”.

Alternatives

There’s a package called z3c.zodbbrowser in the Zope svn repository that implements the same idea (but without history browsing) as a GUI desktop application written using wxPython. It doesn’t have a website and was never released to the Python Package Index.

Authors

ZODB Browser was developed by Tautvilas Mečinskas (tautvilas@pov.lt) and Marius Gedminas (marius@pov.lt) from Programmers of Vilnius. It is licenced under the Zope Public Licence.

Please report bugs at https://bugs.launchpad.net/zodbbrowser

Changes

0.6 (2009-12-07)

  • Ability to revert object state to an older version. Requires a read-write database connection (i.e. run bin/zodbbrowser –rw). The button is hidden and appears when you’re hovering over a transaction entry in the list.

  • Collapse long item lists by default.

0.5.1 (2009-11-23)

  • IMPORTANT BUGFIX: don’t leave old object states lying around in ZODB object cache, which could lead to DATA LOSS (LP#487243).

0.5 (2009-11-23)

  • Be a bit more tolerant to unpickling errors (show which revision could not be loaded instead of breaking the whole page).

  • Show full history of OOBTree objects and subobjects (LP#474334).

  • Change background color of links on hover, to make it clear what object you’ll see when you click, especially when the __repr__ shown contains reprs of subobjects.

  • Show size of containers next to the “Items” heading (LP#486910).

  • Show size of containers next to their representation, e.g. “<persistent.dict.PersistentDict object at 0xad0b3ec> (0 items)”.

  • Pay attention when __name__ is declared as a class attribute (LP#484899).

  • Show names of directly provided interfaces on objects (i.e. show a better representation of pickled zope.interface.Provides objects).

  • Pretty-printing of dictionaries (including nested ones).

0.4 (2009-10-11)

  • @@zodbbrowser oid and tid parameters now accept values in hex format (0x0123) Patch by Adam Groszer.

0.3.1 (2009-07-17)

  • Fixed install error on Windows (path cannot end in /).

0.3 (2009-07-17)

  • First public release

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

zodbbrowser-0.6.tar.gz (74.1 kB view hashes)

Uploaded Source

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