store methods, optional serializer, PEP8 file_obj
Created by: fractaledmind
I have made three alterations to version 1.7:
- I changed all
open ... as file:
toopen ... as file_obj
to avoid pylint error when redefining built-in - Added a new optional parameter to
Workflow()
intialilzation:-
serializer
defaults topickle
but can be set to anything that supportsload
anddump
methods -
self._serializer
loads or dumps store and cache data in respective methods - stored/cached data is saved in file with extension matching
serializer
's name (__name__
property)
-
- Added
stored_data
andstore_data
methods, which mirrorcached_data
andcache_data
in functionality.
Thoughts?