equal
deleted
inserted
replaced
930 |
930 |
931 @staticmethod |
931 @staticmethod |
932 def i18ninstance_instance(appid): |
932 def i18ninstance_instance(appid): |
933 """recompile instance's messages catalogs""" |
933 """recompile instance's messages catalogs""" |
934 config = cwcfg.config_for(appid) |
934 config = cwcfg.config_for(appid) |
935 try: |
935 config.repairing = True # notify this is not a regular start |
936 config.bootstrap_cubes() |
936 config.read_instance_schema = False # bootstrap schema is enough |
937 except IOError, ex: |
937 repo = config.repository() |
938 import errno |
938 if config._cubes is None: |
939 if ex.errno != errno.ENOENT: |
|
940 raise |
|
941 # bootstrap_cubes files doesn't exist |
|
942 # notify this is not a regular start |
|
943 config.repairing = True |
|
944 # create an in-memory repository, will call config.init_cubes() |
|
945 config.repository() |
|
946 except AttributeError: |
|
947 # web only config |
939 # web only config |
948 config.init_cubes(config.repository().get_cubes()) |
940 config.init_cubes(repo.get_cubes()) |
949 errors = config.i18ncompile() |
941 errors = config.i18ncompile() |
950 if errors: |
942 if errors: |
951 print '\n'.join(errors) |
943 print '\n'.join(errors) |
952 |
944 |
953 |
945 |