comparison piecrust/baking/single.py @ 998:a49e6846e0da

bake: Fix crash when trying to report a deployment error.
author Ludovic Chabant <ludovic@chabant.com>
date Tue, 21 Nov 2017 09:54:00 -0800
parents 92a98c84a925
children
comparison
equal deleted inserted replaced
997:7b4874b03fb1 998:a49e6846e0da
168 logger.debug("Copying page assets to: %s" % out_assets_dir) 168 logger.debug("Copying page assets to: %s" % out_assets_dir)
169 _ensure_dir_exists(out_assets_dir) 169 _ensure_dir_exists(out_assets_dir)
170 try: 170 try:
171 qualified_page.source.buildAssetor(qualified_page, sub_uri).copyAssets(out_assets_dir) 171 qualified_page.source.buildAssetor(qualified_page, sub_uri).copyAssets(out_assets_dir)
172 except Exception as ex: 172 except Exception as ex:
173 page_rel_path = os.path.relpath(qualified_page.path,
174 self.app.root_dir)
173 raise BakingError("%s: error deploying page assets." % 175 raise BakingError("%s: error deploying page assets." %
174 page_rel_path) from ex 176 page_rel_path) from ex
175 177
176 # Figure out if we have more work. 178 # Figure out if we have more work.
177 has_more_subs = False 179 has_more_subs = False