1
0
mirror of https://github.com/OlafvdSpek/ctemplate.git synced 2025-09-28 19:05:49 +08:00

Python 3 support

This commit is contained in:
Olaf van der Spek 2017-08-27 17:31:42 +02:00
parent ce1b8fe617
commit 4b7e6c52dc
2 changed files with 2 additions and 2 deletions

View File

@ -210,7 +210,7 @@ class FSMConfig(object):
self.sm['state'] = self.AddState
self.sm['condition'] = self.AddCondition
execfile(filename, self.sm)
exec(open(filename).read(), self.sm)
self.name = self.sm['name']
if not self.name.isalnum():
raise Exception("State machine name must consist of only alphanumeric"

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python2
#!/usr/bin/env python
#
# Copyright (c) 2008, Google Inc.
# All rights reserved.