Skip to content

codersquid/oops-datedir-repo-noprune

Repository files navigation

This is a mirror of 
https://code.launchpad.net/~codersquid/python-oops-datedir-repo/oops-datedir-prune-optionaliming.dat
which is a branch off of
https://code.launchpad.net/python-oops-datedir-repo
Go there for history, I couldn't get the bzr fastimport plugin to work to import
the bzr history.

This makes the prune dependencies optional.

*************************************************************************
python-oops-datedir-repo: A simple disk repository for OOPS Error reports
*************************************************************************

    Copyright (c) 2011, Canonical Ltd

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation, version 3 only.
   
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Lesser General Public License for more details.
   
    You should have received a copy of the GNU Lesser General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
    GNU Lesser General Public License version 3 (see the file LICENSE).

This is a component of the python-oops project:
https://launchpad.net/python-oops. An OOPS report is a report
about something going wrong in a piece of software... thus, an 'oops' :)

This package provides disk storage, management, and a serialisation format for
OOPSes stored in the repository. Programs or services that are generating OOPS
reports need this package or other similar ones, if they want to persist the
reports.

Dependencies
============

* Python 2.6+
* The oops package (https://launchpad.net/python-oops or 'oops' on pypi).

Testing Dependencies
====================

* fixtures (http://pypi.python.org/pypi/fixtures)

* subunit (http://pypi.python.org/pypi/python-subunit) (optional)

* testtools (http://pypi.python.org/pypi/testtools)

Usage
=====

oops_datedir_repo is an extension package for the oops package.

The DateDirRepo class provides an OOPS publisher (``DateDirRepo.publish``)
which will write OOPSes into the repository.

Retrieving OOPSes can be done by using the low level serializer_rfc822
functions : an OOPS report can be written to a disk file via the
serializer_rfc822.write() function, and read via the matching read() function.

Typical usage::

  >>> config = oops.Config()
  >>> with fixtures.TempDir() as tempdir:
  ...    repo = oops_datedir_repo.DateDirRepo('/tmp/demo')
  ...    config.publishers.append(repo.publish)
  ...    ids = config.publish({'oops': '!!!'})

For more information see the oops package documentation or the api docs.

Installation
============

oops_datedir_repo can be installed into an existing Python environment in
the usual way using ``pip``, or it can be installed as a standalone package
with ``pip install .\[prune\]`` in order to use its ``prune`` tool.  To install
it as a standalone package, run ``make`` to create a suitable virtual
environment; you can then run ``bin/prune`` to delete unreferenced OOPSes.


Development
===========

Upstream development takes place at https://launchpad.net/python-oops-datedir-repo.

To run this project's tests, use `tox <https://tox.readthedocs.io/en/latest/>`.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published