Metadata-Version: 2.0
Name: hamster-lib
Version: 0.11.0
Summary: A library for common timetracking functionality.
Home-page: https://github.com/projecthamster/hamster-lib
Author: Eric Goller
Author-email: eric.goller@ninjaduck.solutions
License: GPL3
Keywords: hamster-lib
Platform: UNKNOWN
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Natural Language :: English
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Requires-Dist: appdirs
Requires-Dist: configparser
Requires-Dist: future
Requires-Dist: icalendar
Requires-Dist: sqlalchemy

===============================
hamsterlib
===============================

.. image:: https://img.shields.io/travis/projecthamster/hamster-lib/master.svg
        :target: https://travis-ci.org/projecthamster/hamster_lib

.. image:: https://img.shields.io/codecov/c/github/projecthamster/hamster-lib/master.svg
        :target: https://codecov.io/github/projecthamster/hamster-lib

.. image:: https://readthedocs.org/projects/hamster-lib/badge/?version=master
        :target: http://hamster-lib.docs.projecthamster.org/en/latest/
        :alt: Documentation Status

.. image:: https://requires.io/github/projecthamster/hamster-lib/requirements.svg?branch=master
        :target: https://requires.io/github/projecthamster/hamster-lib/requirements/?branch=master
        :alt: Requirements Status

(A badges refer to ``master``)

A library for common timetracking functionality.

``hamster-lib`` aims to be a replacement for ``projecthamster``  backend
library.  While we are not able to function as a  straight forward drop-in
replacement we try very hard to stay as compatible as possible. As a
consequence clients are able to switch to ``hamster-lib``  merely by changing
some basic calls. Most of the semantics and return values will be as before.

This itself points to a major architectural shift in the way ``hamster-lib``
approaches timetracking. We are firm believers in *do one thing, and do it
well*. The tried and tested unix toolbox principle. As such we focus on
providing useful backend functionality and helper methods so clients (dbus
interfaces, CLIs or graphical UIs) can build upon a solid and consistent base
and focus on their specific requirements.

Features
--------
* Full python >=2.7 and >=3.4 compatibility
* Full unicode support
* >= 95% test coverage
* Extensive documentation
* Focus on clean, maintainable code.
* Free software: GPL3
* All you need for production, test or dev environments comes out of the box
  with regular python tools.

First Steps
-----------
* Build dev environment: ``make develop``
* Build the documentation locally: ``make docs``
* Run just the tests: ``make test``
* Run entire test suite including linters and coverage: ``make test-all``

Additional Resources
--------------------
* `Documentation by 'read the docs' <http://hamster-lib.docs.projecthamster.org/en/latest>`_
* `CI thanks to Travis-CI <https://travis-ci.org/projecthamster/hamster-lib>`_
* `Coverage reports by 'codecov' <https://codecov.io/gh/projecthamster/hamster-lib>`_
* `Dependency monitoring by 'requires.io' <https://requires.io/github/projecthamster/hamster-lib/requirements/?branch=master>`_

News: Version 0.11.0
---------------------
This is the first release of ``hamster-lib`` as official part of
`projecthamster <https://github.com/projecthamster>`_.
As such it includes a lot of internal adjustments and minor fixes.
Besides such housekeeping however, is also offers some genuine new features.
You can now query ``ActivityManaget.get_all`` to return *all* activities, where
it previously only returned *all for given category*. We also made
``Category``, ``Activity`` and ``Fact`` hashable, so you can now use them as
``dict`` keys or ``set`` elements.
For a more detailed overview about what new, please refer to the changelog.
Happy tracking; Eric.

Todo
----
This early release is mainly meant as a rough proof-of-concept at this stage.
It showcases our API as well as our general design decisions.  As such there
are a few functionalities/details of the original ``projecthamster`` backend
that we wish to allow for, but are not provided so far.  These are:

* Tags (We accept them but they are not stored in the backend.)
* Autocomplete related methods
* Trophies (The jury is still out on if and how we want to support those.)
* Migrations from old databases.

Incompatibilities
------------------
Despite our efforts to stay backwards compatible we did deliberately break the
way ``Facts`` without end dates are handled. We think allowing for them in any
persistent backend creates a data consistency nightmare and so far there seems
no conceivable use case for it, let alone an obvious semantic.  What we do
allow for is *one* ``ongoing fact``. That is a fact that has a start, but no
end date. For details, please refer to the documentation.

Credits
---------
Tools used in rendering this package:

*  Cookiecutter_
*  `cookiecutter-pypackage`_

.. _Cookiecutter: https://github.com/audreyr/cookiecutter
.. _`cookiecutter-pypackage`: https://github.com/audreyr/cookiecutter-pypackage




History
=======

0.11.0 (2016-07-06)
--------------------
* Renamed this package to ``hamster-lib`` as it now an offical part of
  `projecthamster <https://github.com/projecthamster>`_. It was previously
  named and distributed as `hamsterlib <https://pypi.python.org/pypi/hamsterlib/0.1.0>`_
* Add documentation checker ``pep257`` to testsuite.
* Fixed docstrings.
* Removed ``hamster_lib.objects.Fact.serialized_name``.
* Improved test factories
* Made ``hamster_lib.objects.*`` *hashable*.
* Provide consistent and improved ``__repr__`` methods for
  ``hamster_lib.objects`` classes.
* ``FactManager._get_all`` can now return facts completely*or* partially within
  the timeframe. As a consequence, we removed
  ``FactManager._timeframe_is_free``.
* Added a set of helper function to ease common configuration related tasks.
  In particular they make it easy to store a given config at its canonical
  file system location.
* Improved ``ActivityManager.get_all`` to enable it to return *all* activities.

0.10.0 (2016-04-20)
-------------------
* Add ``ical`` export facilities. Brand new writer using the ``icalendar`` library.
* Add ``xml`` export facilities.
* Switch to `semantic versioning <http://semver.org>`_
* Added GPL3 boilerplate
* Provide documentation on packaging and ``requirements.txt``.
* Add support for `editorconfig <http://editorconfig.org>`_
* Introduce fine grained, storage backend dependent config options.

0.0.3 (2016-04-08)
-------------------
* fact managers ``save`` method now enforces new ``fact_min_delta`` setting.
* Fixed broken packing in ``setup.py``.
* Storage manager methods now use extensive logging.
* Documentation moved to 'alabaster' theme and content extended.
* Remove usage of ``future.builtins.str``.
* Adjusted ``release`` make target.

0.0.2 (2016-04-07)
------------------
* First release on PyPi
* Improved documentation
* Support for *ongoing facts*.
* Updated requirements

0.0.1 (2016-04-03)
---------------------
* First release on github


