def _find_milestone_revisions(config, milestone, branch=None):
 script = alembic_script.ScriptDirectory.from_config(config)
 return [(m.revision, label) for m in _get_revisions(script) for label in (m.branch_labels or [None]) if ((milestone in getattr(m.module, 'neutron_milestone', [])) and ((branch is None) or (branch in m.branch_labels)))]

def _find_milestone_revisions ( config , milestone , branch = None ) : script = alembic_script . ScriptDirectory . from_config ( config ) return [ ( m . revision , label ) for m in _get_revisions ( script ) for label in ( m . branch_labels or [ None ] ) if ( ( milestone in getattr ( m . module , 'neutron_milestone' , [ ] ) ) and ( ( branch is None ) or ( branch in m . branch_labels ) ) ) ]
return the revision(s) for a given milestone .