Changeset - fcfc62767107
[Not reviewed]
default
0 7 0
Mads Kiilerich - 6 years ago 2019-08-04 01:29:11
mads@kiilerich.com
Grafted from: 6782da628e3a
flake8: fix E129 visually indented line with same indent as next logical line
7 files changed with 18 insertions and 10 deletions:
0 comments (0 inline, 0 general)
kallithea/bin/kallithea_cli_repo.py
Show inline comments
 
@@ -133,7 +133,8 @@ def repo_purge_deleted(ask, older_than):
 
        if ('.hg' in alldirs or
 
            '.git' in alldirs or
 
            '.svn' in alldirs or
 
            'objects' in alldirs and ('refs' in alldirs or 'packed-refs' in f)):
 
            'objects' in alldirs and ('refs' in alldirs or 'packed-refs' in f)
 
        ):
 
            continue
 
        for loc in alldirs:
 
            if REMOVED_REPO_PAT.match(loc):
kallithea/controllers/changelog.py
Show inline comments
 
@@ -88,7 +88,8 @@ class ChangelogController(BaseRepoContro
 
        if (branch_name and
 
            branch_name not in c.db_repo_scm_instance.branches and
 
            branch_name not in c.db_repo_scm_instance.closed_branches and
 
            not revision):
 
            not revision
 
        ):
 
            raise HTTPFound(location=url('changelog_file_home', repo_name=c.repo_name,
 
                                    revision=branch_name, f_path=f_path or ''))
 

	
kallithea/controllers/pullrequests.py
Show inline comments
 
@@ -98,7 +98,8 @@ class PullrequestsController(BaseRepoCon
 
            peerbranches = set()
 
            for i in repo._repo.revs(
 
                "sort(parents(branch(id(%s)) and merge()) - branch(id(%s)), -rev)",
 
                branch_rev, branch_rev):
 
                branch_rev, branch_rev
 
            ):
 
                for abranch in repo.get_changeset(i).branches:
 
                    if abranch not in peerbranches:
 
                        n = 'branch:%s:%s' % (abranch, repo.get_changeset(abranch).raw_id)
kallithea/lib/db_manage.py
Show inline comments
 
@@ -237,8 +237,8 @@ class DbManage(object):
 
            ('default_repo_enable_downloads', False, 'bool'),
 
            ('default_repo_enable_statistics', False, 'bool'),
 
            ('default_repo_private', False, 'bool'),
 
            ('default_repo_type', 'hg', 'unicode')]:
 

	
 
            ('default_repo_type', 'hg', 'unicode')
 
        ]:
 
            if skip_existing and Setting.get_by_name(k) is not None:
 
                log.debug('Skipping option %s', k)
 
                continue
kallithea/lib/vcs/backends/git/repository.py
Show inline comments
 
@@ -278,7 +278,8 @@ class GitRepository(BaseRepository):
 

	
 
        is_bstr = isinstance(revision, (str, unicode))
 
        if ((is_bstr and revision.isdigit() and len(revision) < 12)
 
            or isinstance(revision, int) or is_null(revision)):
 
            or isinstance(revision, int) or is_null(revision)
 
        ):
 
            try:
 
                revision = self.revisions[int(revision)]
 
            except IndexError:
kallithea/lib/vcs/subprocessio.py
Show inline comments
 
@@ -367,13 +367,15 @@ class SubprocessIOChunker(object):
 
        # Else, we are happy.
 
        returncode = _p.poll()
 
        if (returncode is not None # process has terminated
 
            and returncode != 0): # and it failed
 
            and returncode != 0
 
        ): # and it failed
 
            bg_out.stop()
 
            out = ''.join(bg_out)
 
            bg_err.stop()
 
            err = ''.join(bg_err)
 
            if (err.strip() == 'fatal: The remote end hung up unexpectedly' and
 
                out.startswith('0034shallow ')):
 
                out.startswith('0034shallow ')
 
            ):
 
                # hack inspired by https://github.com/schacon/grack/pull/7
 
                bg_out = iter([out])
 
                _p = None
 
@@ -395,7 +397,8 @@ class SubprocessIOChunker(object):
 
        if self.process:
 
            returncode = self.process.poll()
 
            if (returncode is not None # process has terminated
 
                and returncode != 0): # and it failed
 
                and returncode != 0
 
            ): # and it failed
 
                self.output.stop()
 
                self.error.stop()
 
                err = ''.join(self.error)
kallithea/model/pull_request.py
Show inline comments
 
@@ -172,7 +172,8 @@ class CreatePullRequestAction(object):
 
        object.
 
        """
 
        if (h.HasRepoPermissionLevel('read')(org_repo.repo_name) and
 
            h.HasRepoPermissionLevel('read')(other_repo.repo_name)):
 
            h.HasRepoPermissionLevel('read')(other_repo.repo_name)
 
        ):
 
            return True
 

	
 
        return False
0 comments (0 inline, 0 general)