Skip to content
A python decorator that tracks added and changed elements of the decorated object.
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
lib
tests
.envrc
.gitignore
.travis.yml
LICENSE
README.md
bitbucket-pipelines.yml
changelog.txt
dev-requirements.txt
setup.py
tox.ini

README.md

Build Status

This repo lives both in Github and BitBucket.

History Object

An Object implementation that tracks added and changed elements.

Usage

>>> from history_object import History
>>> 
>>> @History()
>>> class T():
>>>     def __init__(self, x):
>>>        self.x = x
>>>
>>> test = T("Hello World")
>>> test.history['x']         # [None, "Hello World"]
>>> test.x = "Goodbye World"
>>> test.history['x']         # [None, "Hello World", "Goodbye World"]

Test

You can run the tests using tox

tox

Publish

To publish a new version of this package your Pypi user needt to be added to the project. (Ask Connor to give you access)

# Update version number in setup.py

python setup.py sdist
twine upload dist/*
You can’t perform that action at this time.