Metadata-Version: 1.1
Name: ERPpeek
Version: 0.10
Summary: Versatile tool for browsing OpenERP data
Home-page: http://erppeek.readthedocs.org/
Author: Florent Xicluna
Author-email: florent.xicluna@gmail.com
License: BSD
Description: ===================================================
        ERPpeek, a versatile tool for browsing OpenERP data
        ===================================================
        
        Download the `latest release <http://pypi.python.org/pypi/ERPpeek>`__ from PyPI::
        
            pip install -U erppeek
        
        .. contents::
        
        
        Overview
        --------
        
        ERPpeek carries three completing uses:
        
        (1) with command line arguments
        (2) as an interactive shell
        (3) as a client library
        
        
        Key features:
        
        - single executable ``erppeek.py``, no external dependency
        - wrappers for ``search+read``, for data model introspection, etc...
        - simpler syntax for ``domain`` and ``fields``
        - full API accessible on the ``Client`` object for OpenERP 5.0 through 6.1
        - the module can be imported and used as a library: ``from erppeek import Client``
        - supports Python 3 and Python 2 (>= 2.5)
        
        
        1. Command line arguments
        -------------------------
        
        See the `introduction on this page
        <http://www.theopensourcerer.com/2011/12/13/erppeek-a-tool-for-browsing-openerp-data-from-the-command-line/>`__
        or::
        
            erppeek --help
        
        
        2. Interactive use
        ------------------
        
        Edit ``erppeek.ini`` and declare the environment(s)::
        
           [DEFAULT]
           host = localhost
           port = 8069
           database = openerp
           username = admin
        
           [demo]
           username = demo
           password = demo
        
        
        Connect to the OpenERP server::
        
            erppeek --list
            erppeek --env demo
        
        
        This is a sample session::
        
            demo >>> model('res.users')
            <Model 'res.users'>
            demo >>> client.ResUsers is model('res.users')
            True
            demo >>> client.ResUsers.count()
            4
            demo >>> read('ir.cron', ['active = False'], 'active function')
            [{'active': False, 'function': 'run_mail_scheduler', 'id': 1},
             {'active': False, 'function': 'run_bdr_scheduler', 'id': 2},
             {'active': False, 'function': 'scheduled_fetch_new_scans', 'id': 9}]
            demo >>>
            demo >>> client.modules('delivery')
            {'uninstalled': ['delivery', 'sale_delivery_report']}
            demo >>> client.upgrade('base')
            1 module(s) selected
            42 module(s) to process:
              to upgrade    account
              to upgrade    account_chart
              to upgrade    account_tax_include
              to upgrade    base
              ...
            demo >>>
        
        .. note::
        
           Use the ``--verbose`` switch to see what happens behind the scene.
           Lines are truncated at 79 chars.  Use ``-vv`` or ``-vvv`` to print
           more.
        
        
        Main commands::
        
            search(obj, domain)
            search(obj, domain, offset=0, limit=None, order=None)
                                            # Return a list of IDs
            count(obj, domain)              # Count the matching objects
        
            read(obj, ids, fields=None)
            read(obj, domain, fields=None)
            read(obj, domain, fields=None, offset=0, limit=None, order=None)
                                            # Return values for the fields
        
            models(name)                    # List models matching pattern
            model(name)                     # Return a Model instance
            keys(obj)                       # List field names of the model
            fields(obj, names=None)         # Return details for the fields
            field(obj, name)                # Return details for the field
            access(obj, mode='read')        # Check access on the model
        
            do(obj, method, *params)        # Generic 'object.execute'
            wizard(name)                    # Return the 'id' of a new wizard
            wizard(name_or_id, datas=None, action='init')
                                            # Generic 'wizard.execute'
            exec_workflow(obj, signal, id)  # Trigger workflow signal
        
            client                          # Client object, connected
            client.login(user)              # Login with another user
            client.connect(env)             # Connect to another env.
            client.modules(name)            # List modules matching pattern
            client.upgrade(module1, module2, ...)
                                            # Upgrade the modules
        
        
        
        Changelog
        ---------
        
        0.10 (2012-08-23)
        ~~~~~~~~~~~~~~~~~
        
        * Add the ``--verbose`` switch to log the XML-RPC messages.
          Lines are truncated at 79 chars.  Use ``-vv`` or ``-vvv``
          to truncate at 179 or 9999 chars respectively.
        
        * Removed the ``--write`` switch because it's not really useful.
          Use :meth:`Record.write` or :meth:`client.write` for example.
        
        * Stop raising RuntimeError when calling ``Client.model(name)``.
          Simply print the message if the name does not match.
        
        * Fix ``RecordList.read()`` and ``Record.read()`` methods to accept the
          same diversity of ``fields`` arguments as the ``Client.read()`` method.
        
        * ``RecordList.read()`` and ``Record.read()`` return instances of
          ``RecordList`` and ``Record`` for relational fields.
        
        * Optimize: store the name of the ``Record`` when a relational field
          is accessed.
        
        * Fix message wording on module install or upgrade.
        
        
        0.9.2 (2012-08-22)
        ~~~~~~~~~~~~~~~~~~
        
        * Fix ``Record.write()`` and ``Record.unlink()`` methods.
        
        * Fix the caching of the ``Model`` keys and fields and the ``Record``
          name.
        
        
        0.9.1 (2012-08-22)
        ~~~~~~~~~~~~~~~~~~
        
        * Fix ``client.model()`` method.  Add ``models()`` to the ``globals()``
          in interactive mode.
        
        
        0.9 (2012-08-22)
        ~~~~~~~~~~~~~~~~
        
        * Add the Active Record pattern for convenience.  New classes :class:`Model`,
          :class:`RecordList` and :class:`Record`.  The :meth:`Client.model` method
          now returns a single :class:`Model` instance.  These models can be
          reached using camel case attribute too.  Example:
          ``client.model('res.company')`` and ``client.ResCompany`` return the same
          :class:`Model`.
        
        * Refresh the list of modules before install or upgrade.
        
        * List all modules which have ``state not in ('uninstalled', 'uninstallable')``
          when calling ``client.modules(installed=True)``.
        
        * Add documentation.
        
        
        0.8 (2012-04-24)
        ~~~~~~~~~~~~~~~~
        
        * Fix ``help(client)`` and ``repr(...)``.
        
        * Add basic safeguards for argument types.
        
        
        0.7 (2012-04-04)
        ~~~~~~~~~~~~~~~~
        
        * Fix RuntimeError on connection.
        
        
        0.6 (2012-04-03)
        ~~~~~~~~~~~~~~~~
        
        * Support Python 3.
        
        * Return Client method instead of function when calling ``client.write``
          or similar.
        
        * Fix the case where :meth:`~Client.read()` is called with a single id.
        
        
        0.5 (2012-03-29)
        ~~~~~~~~~~~~~~~~
        
        * Implement ``Client.__getattr__`` special attribute to call any object
          method, like ``client.write(obj, values)``.  This is somewhat
          redundant with ``client.execute(obj, 'write', values)`` and its
          interactive alias ``do(obj, 'write', values)``.
        
        * Add ``--write`` switch to enable unsafe helpers: ``write``,
          ``create``, ``copy`` and ``unlink``.
        
        * Tolerate domain without square brackets, but show a warning.
        
        * Add long options ``--search`` for ``-s``, ``--interact`` for ``-i``.
        
        
        0.4 (2012-03-28)
        ~~~~~~~~~~~~~~~~
        
        * Workaround for ``sys.excepthook`` ignored, related to a
          `Python issue <http://bugs.python.org/issue12643>`__.
        
        
        0.3 (2012-03-26)
        ~~~~~~~~~~~~~~~~
        
        * Add ``--config`` and ``--version`` switches.
        
        * Improve documentation with session examples.
        
        * Move the project from Launchpad to GitHub.
        
        
        0.2 (2012-03-24)
        ~~~~~~~~~~~~~~~~
        
        * Allow to switch user or database: methods ``client.login`` and
          ``client.connect``.
        
        * Allow ``context=`` keyword argument.
        
        * Add ``access(...)`` method.
        
        * Add ``%(...)s`` formatting for the fields parameter of the ``read(...)`` method.
        
        * Refactor the interactive mode.
        
        * Many improvements.
        
        * Publish on PyPI.
        
        
        0.1 (2012-03-14)
        ~~~~~~~~~~~~~~~~
        
        * Initial release.
        
Keywords: openerp xml-rpc xmlrpc
Platform: any
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Software Development :: Libraries :: Python Modules
