comparison sat/bridge/bridge_constructor/bridge_constructor.py @ 3169:560642ab1c10

bridge constructor: replaced deprecated `readfp`
author Goffi <goffi@goffi.org>
date Fri, 14 Feb 2020 15:18:52 +0100
parents 559a625a236b
children be6d91572633
comparison
equal deleted inserted replaced
3168:1cb232c9e845 3169:560642ab1c10
122 def go(self): 122 def go(self):
123 self.importConstructors() 123 self.importConstructors()
124 args = self.parse_args() 124 args = self.parse_args()
125 template_parser = Parser() 125 template_parser = Parser()
126 try: 126 try:
127 template_parser.readfp(args.template) 127 template_parser.read_file(args.template)
128 except IOError: 128 except IOError:
129 print("The template file doesn't exist or is not accessible") 129 print("The template file doesn't exist or is not accessible")
130 exit(1) 130 exit(1)
131 constructor = self.protocoles[args.protocole](template_parser, args) 131 constructor = self.protocoles[args.protocole](template_parser, args)
132 constructor.generate(args.side) 132 constructor.generate(args.side)