Hello community, here is the log from the commit of package python-automaton for openSUSE:Factory checked in at 2016-05-19 12:14:37 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-automaton (Old) and /work/SRC/openSUSE:Factory/.python-automaton.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-automaton" Changes: -------- --- /work/SRC/openSUSE:Factory/python-automaton/python-automaton.changes 2015-10-30 13:42:33.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.python-automaton.new/python-automaton.changes 2016-05-19 12:14:39.000000000 +0200 @@ -1,0 +2,26 @@ +Thu Mar 3 14:15:57 UTC 2016 - tbecht...@suse.com + +- update to 1.2.0: + * Add a state-space machine building example + * Ensure state space can also pass on_enter/exit callbacks + * Updated from global requirements + * Updated from global requirements + * Ensure machine special method(s) include in generated docs + * Put py34 first in the envlist order of tox ,remove py33 + * Removes MANIFEST.in as it is not needed explicitely by PBR + * Deprecated tox -downloadcache option removed + * Updated from global requirements + * Remove python 2.6 and cleanup tox.ini + * Added code coverage section to tox + * No need for Oslo Incubator Sync + * Ignore generated files + * docs - Set pbr 'warnerrors' option for doc build + * Remove dummy/placeholder 'ChangeLog' as its not needed + * Enhance the README + * Fix the build path in .gitignore file + * Updated from global requirements + * Provide a finite machine build() method + * Allow for raising on duplicate transition registration +- update Requires according to requirements.txt + +------------------------------------------------------------------- Old: ---- automaton-0.7.0.tar.gz New: ---- automaton-1.2.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-automaton.spec ++++++ --- /var/tmp/diff_new_pack.VMDepR/_old 2016-05-19 12:14:40.000000000 +0200 +++ /var/tmp/diff_new_pack.VMDepR/_new 2016-05-19 12:14:40.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package python-automaton # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,7 +17,7 @@ Name: python-automaton -Version: 0.7.0 +Version: 1.2.0 Release: 0 Summary: Friendly state machines for python License: Apache-2.0 @@ -31,7 +31,7 @@ BuildRequires: python-setuptools BuildRequires: python-six Requires: python-PrettyTable >= 0.7 -Requires: python-debtcollector >= 0.3.0 +Requires: python-debtcollector >= 1.2.0 Requires: python-six >= 1.9.0 BuildArch: noarch ++++++ automaton-0.7.0.tar.gz -> automaton-1.2.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/.coveragerc new/automaton-1.2.0/.coveragerc --- old/automaton-0.7.0/.coveragerc 1970-01-01 01:00:00.000000000 +0100 +++ new/automaton-1.2.0/.coveragerc 2016-02-10 00:14:57.000000000 +0100 @@ -0,0 +1,8 @@ +[run] +branch = True +source = automaton +omit = automaton/tests/* + +[report] +ignore_errors = True +precision = 2 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/AUTHORS new/automaton-1.2.0/AUTHORS --- old/automaton-0.7.0/AUTHORS 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/AUTHORS 2016-02-10 00:15:15.000000000 +0100 @@ -1,4 +1,10 @@ +Davanum Srinivas <dava...@gmail.com> +Janonymous <janonymous.codevult...@gmail.com> Joshua Harlow <harlo...@gmail.com> Joshua Harlow <harlo...@yahoo-inc.com> +Ondřej Nový <ondrej.n...@firma.seznam.cz> +Ronald Bradford <ronald.bradf...@gmail.com> Ruby Loo <r...@yahoo-inc.com> Tom Cocozzello <tjcoc...@us.ibm.com> +sonu.kumar <sonu.ku...@nectechnologies.in> +venkatamahesh <venkatamaheshko...@gmail.com> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/ChangeLog new/automaton-1.2.0/ChangeLog --- old/automaton-0.7.0/ChangeLog 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/ChangeLog 2016-02-10 00:15:15.000000000 +0100 @@ -1,6 +1,42 @@ CHANGES ======= +1.2.0 +----- + +* Add a state-space machine building example +* Ensure state space can also pass on_enter/exit callbacks +* Updated from global requirements +* Updated from global requirements +* Ensure machine special method(s) include in generated docs +* Put py34 first in the envlist order of tox ,remove py33 + +1.1.0 +----- + +* Removes MANIFEST.in as it is not needed explicitely by PBR +* Deprecated tox -downloadcache option removed + +1.0.0 +----- + +* Updated from global requirements +* Remove python 2.6 and cleanup tox.ini + +0.8.0 +----- + +* Added code coverage section to tox +* No need for Oslo Incubator Sync +* Ignore generated files +* docs - Set pbr 'warnerrors' option for doc build +* Remove dummy/placeholder 'ChangeLog' as its not needed +* Enhance the README +* Fix the build path in .gitignore file +* Updated from global requirements +* Provide a finite machine build() method +* Allow for raising on duplicate transition registration + 0.7.0 ----- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/MANIFEST.in new/automaton-1.2.0/MANIFEST.in --- old/automaton-0.7.0/MANIFEST.in 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/MANIFEST.in 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -include AUTHORS -include ChangeLog -exclude .gitignore -exclude .gitreview - -global-exclude *.pyc diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/PKG-INFO new/automaton-1.2.0/PKG-INFO --- old/automaton-0.7.0/PKG-INFO 2015-09-08 17:30:25.000000000 +0200 +++ new/automaton-1.2.0/PKG-INFO 2016-02-10 00:15:15.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: automaton -Version: 0.7.0 +Version: 1.2.0 Summary: Friendly state machines for python. Home-page: http://www.openstack.org/ Author: OpenStack @@ -18,7 +18,12 @@ :target: https://pypi.python.org/pypi/automaton/ :alt: Downloads - Friendly state machines for python. + Friendly state machines for python. The goal of this library is to provide + well documented state machine classes and associated utilities. The state + machine pattern (or the implemented variation there-of) is a commonly + used pattern and has a multitude of various usages. Some of the usages + for this library include providing state & transition validation and + running/scheduling/analyzing the execution of tasks. * Free software: Apache license * Documentation: http://docs.openstack.org/developer/automaton diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/README.rst new/automaton-1.2.0/README.rst --- old/automaton-0.7.0/README.rst 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/README.rst 2016-02-10 00:14:57.000000000 +0100 @@ -10,7 +10,12 @@ :target: https://pypi.python.org/pypi/automaton/ :alt: Downloads -Friendly state machines for python. +Friendly state machines for python. The goal of this library is to provide +well documented state machine classes and associated utilities. The state +machine pattern (or the implemented variation there-of) is a commonly +used pattern and has a multitude of various usages. Some of the usages +for this library include providing state & transition validation and +running/scheduling/analyzing the execution of tasks. * Free software: Apache license * Documentation: http://docs.openstack.org/developer/automaton diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton/machines.py new/automaton-1.2.0/automaton/machines.py --- old/automaton-0.7.0/automaton/machines.py 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/automaton/machines.py 2016-02-10 00:14:57.000000000 +0100 @@ -24,6 +24,37 @@ from automaton import exceptions as excp +class State(object): + """Container that defines needed components of a single state. + + Usage of this and the :meth:`~.FiniteMachine.build` make creating finite + state machines that much easier. + + :ivar name: The name of the state. + :ivar is_terminal: Whether this state is terminal (or not). + :ivar next_states: Dictionary of 'event' -> 'next state name' (or none). + :ivar on_enter: callback that will be called when the state is entered. + :ivar on_exit: callback that will be called when the state is exited. + """ + + def __init__(self, name, + is_terminal=False, next_states=None, + on_enter=None, on_exit=None): + self.name = name + self.is_terminal = bool(is_terminal) + self.next_states = next_states + self.on_enter = on_enter + self.on_exit = on_exit + + +def _convert_to_states(state_space): + # NOTE(harlowja): if provided dicts, convert them... + for state in state_space: + if isinstance(state, dict): + state = State(**state) + yield state + + def _orderedkeys(data, sort=True): if sort: return sorted(six.iterkeys(data)) @@ -88,16 +119,16 @@ @property def default_start_state(self): - return self._default_start_state - - @default_start_state.setter - def default_start_state(self, state): """Sets the *default* start state that the machine should use. NOTE(harlowja): this will be used by ``initialize`` but only if that function is not given its own ``start_state`` that overrides this default. """ + return self._default_start_state + + @default_start_state.setter + def default_start_state(self, state): if self.frozen: raise excp.FrozenMachine() if state not in self._states: @@ -105,6 +136,29 @@ " undefined state '%s'" % (state)) self._default_start_state = state + @classmethod + def build(cls, state_space): + """Builds a machine from a state space listing. + + Each element of this list must be an instance + of :py:class:`.State` or a ``dict`` with equivalent keys that + can be used to construct a :py:class:`.State` instance. + """ + state_space = list(_convert_to_states(state_space)) + m = cls() + for state in state_space: + m.add_state(state.name, + terminal=state.is_terminal, + on_enter=state.on_enter, + on_exit=state.on_exit) + for state in state_space: + if state.next_states: + for event, next_state in six.iteritems(state.next_states): + if isinstance(next_state, State): + next_state = next_state.name + m.add_transition(state.name, next_state, event) + return m + @property def current_state(self): """The current state the machine is in (or none if not initialized).""" @@ -188,8 +242,17 @@ raise excp.Duplicate("State '%s' reaction to event '%s'" " already defined" % (state, event)) - def add_transition(self, start, end, event): - """Adds an allowed transition from start -> end for the given event.""" + def add_transition(self, start, end, event, replace=False): + """Adds an allowed transition from start -> end for the given event. + + :param start: starting state + :param end: ending state + :param event: event that causes start state to + transition to end state + :param replace: replace existing event instead of raising a + :py:class:`~automaton.exceptions.Duplicate` exception + when the transition already exists. + """ if self.frozen: raise excp.FrozenMachine() if start not in self._states: @@ -204,9 +267,22 @@ raise excp.InvalidState("Can not add a transition on event '%s'" " that starts in the terminal state '%s'" % (event, start)) - self._transitions[start][event] = _Jump(end, - self._states[end]['on_enter'], - self._states[start]['on_exit']) + if event in self._transitions[start] and not replace: + target = self._transitions[start][event] + if target.name != end: + raise excp.Duplicate("Cannot add transition from" + " '%(start_state)s' to '%(end_state)s'" + " on event '%(event)s' because a" + " transition from '%(start_state)s'" + " to '%(existing_end_state)s' on" + " event '%(event)s' already exists." + % {'existing_end_state': target.name, + 'end_state': end, 'event': event, + 'start_state': start}) + else: + target = _Jump(end, self._states[end]['on_enter'], + self._states[start]['on_exit']) + self._transitions[start][event] = target def _pre_process_event(self, event): current = self._current diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton/tests/test_fsm.py new/automaton-1.2.0/automaton/tests/test_fsm.py --- old/automaton-0.7.0/automaton/tests/test_fsm.py 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/automaton/tests/test_fsm.py 2016-02-10 00:14:57.000000000 +0100 @@ -14,6 +14,7 @@ # License for the specific language governing permissions and limitations # under the License. +import collections import functools import random @@ -49,6 +50,88 @@ self.jumper.add_reaction('up', 'jump', lambda *args: 'fall') self.jumper.add_reaction('down', 'fall', lambda *args: 'jump') + def test_build(self): + space = [] + for a in 'abc': + space.append(machines.State(a)) + m = machines.FiniteMachine.build(space) + for a in 'abc': + self.assertIn(a, m) + + def test_build_transitions(self): + space = [ + machines.State('down', is_terminal=False, + next_states={'jump': 'up'}), + machines.State('up', is_terminal=False, + next_states={'fall': 'down'}), + ] + m = machines.FiniteMachine.build(space) + m.default_start_state = 'down' + expected = [('down', 'jump', 'up'), ('up', 'fall', 'down')] + self.assertEqual(expected, list(m)) + + def test_build_transitions_with_callbacks(self): + entered = collections.defaultdict(list) + exitted = collections.defaultdict(list) + + def on_enter(state, event): + entered[state].append(event) + + def on_exit(state, event): + exitted[state].append(event) + + space = [ + machines.State('down', is_terminal=False, + next_states={'jump': 'up'}, + on_enter=on_enter, on_exit=on_exit), + machines.State('up', is_terminal=False, + next_states={'fall': 'down'}, + on_enter=on_enter, on_exit=on_exit), + ] + m = machines.FiniteMachine.build(space) + m.default_start_state = 'down' + expected = [('down', 'jump', 'up'), ('up', 'fall', 'down')] + self.assertEqual(expected, list(m)) + + m.initialize() + m.process_event('jump') + + self.assertEqual({'down': ['jump']}, dict(exitted)) + self.assertEqual({'up': ['jump']}, dict(entered)) + + m.process_event('fall') + + self.assertEqual({'down': ['jump'], 'up': ['fall']}, dict(exitted)) + self.assertEqual({'up': ['jump'], 'down': ['fall']}, dict(entered)) + + def test_build_transitions_dct(self): + space = [ + { + 'name': 'down', 'is_terminal': False, + 'next_states': {'jump': 'up'}, + }, + { + 'name': 'up', 'is_terminal': False, + 'next_states': {'fall': 'down'}, + }, + ] + m = machines.FiniteMachine.build(space) + m.default_start_state = 'down' + expected = [('down', 'jump', 'up'), ('up', 'fall', 'down')] + self.assertEqual(expected, list(m)) + + def test_build_terminal(self): + space = [ + machines.State('down', is_terminal=False, + next_states={'jump': 'fell_over'}), + machines.State('fell_over', is_terminal=True), + ] + m = machines.FiniteMachine.build(space) + m.default_start_state = 'down' + m.initialize() + m.process_event('jump') + self.assertTrue(m.terminated) + def test_actionable(self): self.jumper.initialize() self.assertTrue(self.jumper.is_actionable_event('jump')) @@ -75,6 +158,21 @@ m = self._create_fsm('unknown') self.assertRaises(excp.Duplicate, m.add_state, 'unknown') + def test_duplicate_transition(self): + m = self.jumper + m.add_state('side_ways') + self.assertRaises(excp.Duplicate, + m.add_transition, 'up', 'side_ways', 'fall') + + def test_duplicate_transition_replace(self): + m = self.jumper + m.add_state('side_ways') + m.add_transition('up', 'side_ways', 'fall', replace=True) + + def test_duplicate_transition_same_transition(self): + m = self.jumper + m.add_transition('up', 'down', 'fall') + def test_duplicate_reaction(self): self.assertRaises( # Currently duplicate reactions are not allowed... diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton.egg-info/PKG-INFO new/automaton-1.2.0/automaton.egg-info/PKG-INFO --- old/automaton-0.7.0/automaton.egg-info/PKG-INFO 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/automaton.egg-info/PKG-INFO 2016-02-10 00:15:15.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: automaton -Version: 0.7.0 +Version: 1.2.0 Summary: Friendly state machines for python. Home-page: http://www.openstack.org/ Author: OpenStack @@ -18,7 +18,12 @@ :target: https://pypi.python.org/pypi/automaton/ :alt: Downloads - Friendly state machines for python. + Friendly state machines for python. The goal of this library is to provide + well documented state machine classes and associated utilities. The state + machine pattern (or the implemented variation there-of) is a commonly + used pattern and has a multitude of various usages. Some of the usages + for this library include providing state & transition validation and + running/scheduling/analyzing the execution of tasks. * Free software: Apache license * Documentation: http://docs.openstack.org/developer/automaton diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton.egg-info/SOURCES.txt new/automaton-1.2.0/automaton.egg-info/SOURCES.txt --- old/automaton-0.7.0/automaton.egg-info/SOURCES.txt 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/automaton.egg-info/SOURCES.txt 2016-02-10 00:15:15.000000000 +0100 @@ -1,13 +1,12 @@ +.coveragerc .testr.conf AUTHORS CONTRIBUTING.rst ChangeLog HACKING.rst LICENSE -MANIFEST.in README.rst babel.cfg -openstack-common.conf requirements.txt setup.cfg setup.py diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton.egg-info/pbr.json new/automaton-1.2.0/automaton.egg-info/pbr.json --- old/automaton-0.7.0/automaton.egg-info/pbr.json 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/automaton.egg-info/pbr.json 2016-02-10 00:15:15.000000000 +0100 @@ -1 +1 @@ -{"git_version": "e5d9c91", "is_release": true} \ No newline at end of file +{"git_version": "3f93f01", "is_release": true} \ No newline at end of file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/automaton.egg-info/requires.txt new/automaton-1.2.0/automaton.egg-info/requires.txt --- old/automaton-0.7.0/automaton.egg-info/requires.txt 2015-09-08 17:30:24.000000000 +0200 +++ new/automaton-1.2.0/automaton.egg-info/requires.txt 2016-02-10 00:15:15.000000000 +0100 @@ -1,4 +1,4 @@ -pbr<2.0,>=1.6 +pbr>=1.6 six>=1.9.0 -debtcollector>=0.3.0 +debtcollector>=1.2.0 PrettyTable<0.8,>=0.7 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/doc/source/api.rst new/automaton-1.2.0/doc/source/api.rst --- old/automaton-0.7.0/doc/source/api.rst 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/doc/source/api.rst 2016-02-10 00:14:57.000000000 +0100 @@ -6,8 +6,12 @@ Machines -------- +.. autoclass:: automaton.machines.State + :members: + .. autoclass:: automaton.machines.FiniteMachine :members: + :special-members: __iter__, __contains__ .. autoclass:: automaton.machines.HierarchicalFiniteMachine :members: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/doc/source/examples.rst new/automaton-1.2.0/doc/source/examples.rst --- old/automaton-0.7.0/doc/source/examples.rst 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/doc/source/examples.rst 2016-02-10 00:14:57.000000000 +0100 @@ -131,6 +131,7 @@ Leaving 'wags tail' Entered 'lies down' + ------------------------------------ Creating a complex CD-player machine ------------------------------------ @@ -355,3 +356,107 @@ ============= Current state => closed ============= + +---------------------------------------------------------- +Creating a complex CD-player machine (using a state-space) +---------------------------------------------------------- + +This example is equivalent to the prior one but creates a machine in +a more declarative manner. Instead of calling ``add_state`` +and ``add_transition`` a explicit and declarative format can be used. For +example to create the same machine: + +.. testcode:: + + from automaton import machines + + + def print_on_enter(new_state, triggered_event): + print("Entered '%s' due to '%s'" % (new_state, triggered_event)) + + + def print_on_exit(old_state, triggered_event): + print("Exiting '%s' due to '%s'" % (old_state, triggered_event)) + + # This will contain all the states and transitions that our machine will + # allow, the format is relatively simple and designed to be easy to use. + state_space = [ + { + 'name': 'stopped', + 'next_states': { + # On event 'play' transition to the 'playing' state. + 'play': 'playing', + 'open_close': 'opened', + 'stop': 'stopped', + }, + 'on_enter': print_on_enter, + 'on_exit': print_on_exit, + }, + { + 'name': 'opened', + 'next_states': { + 'open_close': 'closed', + }, + 'on_enter': print_on_enter, + 'on_exit': print_on_exit, + }, + { + 'name': 'closed', + 'next_states': { + 'open_close': 'opened', + 'cd_detected': 'stopped', + }, + 'on_enter': print_on_enter, + 'on_exit': print_on_exit, + }, + { + 'name': 'playing', + 'next_states': { + 'stop': 'stopped', + 'pause': 'paused', + 'open_close': 'opened', + }, + 'on_enter': print_on_enter, + 'on_exit': print_on_exit, + }, + { + 'name': 'paused', + 'next_states': { + 'play': 'playing', + 'stop': 'stopped', + 'open_close': 'opened', + }, + 'on_enter': print_on_enter, + 'on_exit': print_on_exit, + }, + ] + + m = machines.FiniteMachine.build(state_space) + m.default_start_state = 'closed' + print(m.pformat()) + +**Expected output:** + +.. testoutput:: + + +-----------+-------------+---------+----------------+---------------+ + | Start | Event | End | On Enter | On Exit | + +-----------+-------------+---------+----------------+---------------+ + | closed[^] | cd_detected | stopped | print_on_enter | print_on_exit | + | closed[^] | open_close | opened | print_on_enter | print_on_exit | + | opened | open_close | closed | print_on_enter | print_on_exit | + | paused | open_close | opened | print_on_enter | print_on_exit | + | paused | play | playing | print_on_enter | print_on_exit | + | paused | stop | stopped | print_on_enter | print_on_exit | + | playing | open_close | opened | print_on_enter | print_on_exit | + | playing | pause | paused | print_on_enter | print_on_exit | + | playing | stop | stopped | print_on_enter | print_on_exit | + | stopped | open_close | opened | print_on_enter | print_on_exit | + | stopped | play | playing | print_on_enter | print_on_exit | + | stopped | stop | stopped | print_on_enter | print_on_exit | + +-----------+-------------+---------+----------------+---------------+ + +.. note:: + + As can be seen the two tables from this example and the prior one are + exactly the same. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/openstack-common.conf new/automaton-1.2.0/openstack-common.conf --- old/automaton-0.7.0/openstack-common.conf 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/openstack-common.conf 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -[DEFAULT] - -# The list of modules to copy from oslo-incubator.git - -# The base module to hold the copy of openstack.common -base=automaton diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/requirements.txt new/automaton-1.2.0/requirements.txt --- old/automaton-0.7.0/requirements.txt 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/requirements.txt 2016-02-10 00:14:57.000000000 +0100 @@ -3,13 +3,13 @@ # process, which may cause wedges in the gate later. # See: https://bugs.launchpad.net/pbr/+bug/1384919 for why this is here... -pbr<2.0,>=1.6 +pbr>=1.6 # Apache-2.0 # Python 2->3 compatibility library. -six>=1.9.0 +six>=1.9.0 # MIT # For deprecation of things -debtcollector>=0.3.0 # Apache-2.0 +debtcollector>=1.2.0 # Apache-2.0 # For pretty formatting machines/state tables... -PrettyTable<0.8,>=0.7 +PrettyTable<0.8,>=0.7 # BSD diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/setup.cfg new/automaton-1.2.0/setup.cfg --- old/automaton-0.7.0/setup.cfg 2015-09-08 17:30:25.000000000 +0200 +++ new/automaton-1.2.0/setup.cfg 2016-02-10 00:15:15.000000000 +0100 @@ -29,6 +29,9 @@ cover-erase = true verbosity = 2 +[pbr] +warnerrors = True + [wheel] universal = 1 @@ -42,6 +45,6 @@ [egg_info] tag_date = 0 -tag_svn_revision = 0 tag_build = +tag_svn_revision = 0 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/setup.py new/automaton-1.2.0/setup.py --- old/automaton-0.7.0/setup.py 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/setup.py 2016-02-10 00:14:57.000000000 +0100 @@ -25,5 +25,5 @@ pass setuptools.setup( - setup_requires=['pbr>=1.3'], + setup_requires=['pbr>=1.8'], pbr=True) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/test-requirements.txt new/automaton-1.2.0/test-requirements.txt --- old/automaton-0.7.0/test-requirements.txt 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/test-requirements.txt 2016-02-10 00:14:57.000000000 +0100 @@ -5,12 +5,12 @@ hacking<0.11,>=0.10.0 doc8 # Apache-2.0 -coverage>=3.6 -discover -python-subunit>=0.0.18 -sphinx!=1.2.0,!=1.3b1,<1.3,>=1.1.2 -oslosphinx>=2.5.0 # Apache-2.0 +coverage>=3.6 # Apache-2.0 +discover # BSD +python-subunit>=0.0.18 # Apache-2.0/BSD +sphinx!=1.2.0,!=1.3b1,<1.3,>=1.1.2 # BSD +oslosphinx!=3.4.0,>=2.5.0 # Apache-2.0 oslotest>=1.10.0 # Apache-2.0 -testrepository>=0.0.18 -testscenarios>=0.4 -testtools>=1.4.0 +testrepository>=0.0.18 # Apache-2.0/BSD +testscenarios>=0.4 # Apache-2.0/BSD +testtools>=1.4.0 # MIT diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/automaton-0.7.0/tox.ini new/automaton-1.2.0/tox.ini --- old/automaton-0.7.0/tox.ini 2015-09-08 17:29:47.000000000 +0200 +++ new/automaton-1.2.0/tox.ini 2016-02-10 00:14:57.000000000 +0100 @@ -1,21 +1,13 @@ [tox] minversion = 1.6 -skipsdist = True -envlist = docs,py33,py34,py26,py27,pypy,pep8,venv - -[tox:jenkins] -downloadcache = ~/cache/pip +envlist = py34,py27,pypy,docs,pep8,venv [testenv:docs] basepython = python2.7 commands = python setup.py build_sphinx [testenv] -usedevelop = True -install_command = pip install {opts} {packages} -setenv = VIRTUAL_ENV={envdir} -deps = -r{toxinidir}/requirements.txt - -r{toxinidir}/test-requirements.txt +deps = -r{toxinidir}/test-requirements.txt commands = python setup.py test --slowest --testr-args='{posargs}' [testenv:pep8] @@ -25,7 +17,7 @@ commands = python setup.py testr --slowest --testr-args='{posargs}' sphinx-build -b doctest doc/source doc/build - doc8 doc/source + doc8 --ignore-path "doc/source/history.rst" doc/source [testenv:venv] basepython = python2.7 @@ -34,3 +26,6 @@ [flake8] show-source = True exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build + +[testenv:cover] +commands = python setup.py test --coverage --testr-args="{posargs}"