Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(3)  |  Call(0)  |  Derive(0)  |  Import(3)
This file implements an abstract, db-based state machine.

States are represented by subclasses of State.  This state is supplemented by a
finite number of counters, each ranging over a finite set of integers.  In
general, the behavior of the machine in a particular state is governed by the
State class; the counters are only used to fail out of cycles that might
otherwise cause hardware damage.

Transitions are triggered by events: timeouts, API calls, or internal events.
(more...)

src/m/o/mozpool-4.1.5/mozpool/mozpool/requestmachine.py   mozpool(Download)
import random
 
from mozpool import config, statemachine, statedriver, util, async, mozpool
 
####

src/m/o/mozpool-4.1.5/mozpool/lifeguard/devicemachine.py   mozpool(Download)
import json
import datetime
from mozpool import config, statemachine, statedriver, async
from mozpool.bmm import api
from mozpool.db import exceptions

src/m/o/mozpool-4.1.5/mozpool/test/unit/test_statemachine.py   mozpool(Download)
 
import mock
from mozpool import statemachine
from mozpool.test.util import TestCase