| Index: chrome/common/extensions/docs/server2/path_canonicalizer.py
|
| diff --git a/chrome/common/extensions/docs/server2/path_canonicalizer.py b/chrome/common/extensions/docs/server2/path_canonicalizer.py
|
| index d4f4b497c77776eaace2d12c06839879789a08fa..219e30de59a90436eb50ac53ba5e678c49008b91 100644
|
| --- a/chrome/common/extensions/docs/server2/path_canonicalizer.py
|
| +++ b/chrome/common/extensions/docs/server2/path_canonicalizer.py
|
| @@ -9,9 +9,10 @@ import traceback
|
|
|
| from branch_utility import BranchUtility
|
| from compiled_file_system import CompiledFileSystem, SingleFile
|
| +from extensions_paths import PUBLIC_TEMPLATES
|
| from file_system import FileNotFoundError
|
| from third_party.json_schema_compiler.model import UnixName
|
| -import svn_constants
|
| +
|
|
|
| def _SimplifyFileName(file_name):
|
| return (posixpath.splitext(file_name)[0]
|
| @@ -20,6 +21,7 @@ def _SimplifyFileName(file_name):
|
| .replace('-', '')
|
| .replace('_', ''))
|
|
|
| +
|
| class PathCanonicalizer(object):
|
| '''Transforms paths into their canonical forms. Since the dev server has had
|
| many incarnations - e.g. there didn't use to be apps/ - there may be old
|
| @@ -82,9 +84,9 @@ class PathCanonicalizer(object):
|
|
|
| try:
|
| apps_public = self._public_apis.GetFromFileListing(
|
| - '/'.join((svn_constants.PUBLIC_TEMPLATE_PATH, 'apps'))).Get()
|
| + '%s/apps' % PUBLIC_TEMPLATES).Get()
|
| extensions_public = self._public_apis.GetFromFileListing(
|
| - '/'.join((svn_constants.PUBLIC_TEMPLATE_PATH, 'extensions'))).Get()
|
| + '%s/extensions' % PUBLIC_TEMPLATES).Get()
|
| except FileNotFoundError:
|
| # Probably offline.
|
| logging.warning(traceback.format_exc())
|
|
|