##// END OF EJS Templates
Merging done by hand
Jonathan Frederic -
Show More
@@ -151,11 +151,23 b' class NbConvertApp(BaseIPythonApplication):'
151 resources = {}
151 resources = {}
152 resources['unique_key'] = notebook_name
152 resources['unique_key'] = notebook_name
153
153
154 #Export & write
154 #Try to export
155 output, resources = export_by_name(self.export_format,
155 try:
156 notebook_filename,
156 return_value = export_by_name(self.export_format,
157 resources=resources,
157 notebook_filename,
158 config=self.config)
158 resources=resources,
159 config=self.config)
160 except NameError as e:
161 print("Error: '%s' exporter not found." % self.export_format,
162 file=sys.stderr)
163 print("Known exporters are:",
164 "\n\t" + "\n\t".join(get_export_names()),
165 file=sys.stderr)
166 sys.exit(-1)
167 else:
168 output, resources = return_value
169
170 #Write
159 self.writer.write(output, resources, notebook_name=notebook_name)
171 self.writer.write(output, resources, notebook_name=notebook_name)
160
172
161
173
General Comments 0
You need to be logged in to leave comments. Login now