Mercurial > kallithea
changeset 8874:cb733c39f658
db: read hgrc in Repository.scm_instance_no_cache and Gist.scm_instance
This will make sure .hg/hgrc is read in some code paths where it was missing.
That might make a difference in some real world cases.
author | Mads Kiilerich <mads@kiilerich.com> |
---|---|
date | Wed, 21 Apr 2021 14:48:53 +0200 |
parents | a349211f875e |
children | 092e897458fa |
files | kallithea/model/db.py |
diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/kallithea/model/db.py Wed Apr 21 13:34:12 2021 +0200 +++ b/kallithea/model/db.py Wed Apr 21 14:48:53 2021 +0200 @@ -1317,7 +1317,7 @@ repo_full_path = self.repo_full_path log.debug('Creating instance of repository at %s', repo_full_path) from kallithea.lib.utils import make_ui - self._scm_instance = get_repo(repo_full_path, baseui=make_ui()) + self._scm_instance = get_repo(repo_full_path, baseui=make_ui(repo_full_path)) return self._scm_instance def __json__(self): @@ -2241,7 +2241,9 @@ @property def scm_instance(self): gist_base_path = os.path.join(kallithea.CONFIG['base_path'], self.GIST_STORE_LOC) - return get_repo(os.path.join(gist_base_path, self.gist_access_id)) + repo_full_path = os.path.join(gist_base_path, self.gist_access_id) + from kallithea.lib.utils import make_ui + return get_repo(repo_full_path, baseui=make_ui(repo_full_path)) class UserSshKeys(meta.Base, BaseDbModel):