Skip to content

Commit

Permalink
raise error early on broken profile
Browse files Browse the repository at this point in the history
  • Loading branch information
jabdoa2 committed Nov 9, 2016
1 parent 920231d commit a3ebb30
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions mpf/core/shot_profile_manager.py
Expand Up @@ -86,6 +86,9 @@ def process_profile_config(self, profile_name, config):
if not config['player_variable']:
config['player_variable'] = '%_' + profile_name

if not config['states']:
raise AssertionError("Shot profile {} has to contain at least one state.".format(profile_name))

if self.debug:
self.log.debug("Processed '%s' profile configuration: %s",
profile_name, config)
Expand Down

0 comments on commit a3ebb30

Please sign in to comment.