# HG changeset patch # User RhodeCode Admin # Date 2023-03-06 22:36:17 # Node ID daf8135e73956645928dc1b4a76bfef69de26ecb # Parent e51d300dc160273ddbaa6ed32e2664a0d646f6bf python3: removed compat modules diff --git a/rhodecode/apps/ops/views.py b/rhodecode/apps/ops/views.py --- a/rhodecode/apps/ops/views.py +++ b/rhodecode/apps/ops/views.py @@ -27,7 +27,7 @@ from pyramid.httpexceptions import HTTPF from rhodecode.apps._base import BaseAppView from rhodecode.lib import helpers as h from rhodecode.lib.auth import LoginRequired -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.model.db import UserApiKeys log = logging.getLogger(__name__) diff --git a/rhodecode/apps/repository/tests/test_repo_files.py b/rhodecode/apps/repository/tests/test_repo_files.py --- a/rhodecode/apps/repository/tests/test_repo_files.py +++ b/rhodecode/apps/repository/tests/test_repo_files.py @@ -26,7 +26,7 @@ import pytest from rhodecode.apps.repository.tests.test_repo_compare import ComparePage from rhodecode.apps.repository.views.repo_files import RepoFilesView from rhodecode.lib import helpers as h -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.ext_json import json from rhodecode.lib.vcs import nodes diff --git a/rhodecode/apps/repository/tests/test_repo_summary.py b/rhodecode/apps/repository/tests/test_repo_summary.py --- a/rhodecode/apps/repository/tests/test_repo_summary.py +++ b/rhodecode/apps/repository/tests/test_repo_summary.py @@ -25,7 +25,7 @@ import pytest from rhodecode.apps.repository.views.repo_summary import RepoSummaryView from rhodecode.lib import helpers as h -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.utils2 import AttributeDict, safe_str from rhodecode.lib.vcs.exceptions import RepositoryRequirementError from rhodecode.model.db import Repository diff --git a/rhodecode/apps/repository/views/repo_commits.py b/rhodecode/apps/repository/views/repo_commits.py --- a/rhodecode/apps/repository/views/repo_commits.py +++ b/rhodecode/apps/repository/views/repo_commits.py @@ -34,7 +34,7 @@ from rhodecode.lib import diffs, codeblo from rhodecode.lib.auth import ( LoginRequired, HasRepoPermissionAnyDecorator, NotAnonymous, CSRFRequired) from rhodecode.lib.ext_json import json -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.diffs import ( cache_diff, load_cached_diff, diff_cache_exist, get_diff_context, get_diff_whitespace_flag) diff --git a/rhodecode/lib/pidlock.py b/rhodecode/lib/pidlock.py --- a/rhodecode/lib/pidlock.py +++ b/rhodecode/lib/pidlock.py @@ -23,7 +23,6 @@ import errno from multiprocessing.util import Finalize -from rhodecode.lib.compat import kill class LockHeld(Exception): @@ -92,7 +91,7 @@ class DaemonLock(object): # process PID if running_pid: try: - kill(running_pid, 0) + os.kill(running_pid, 0) except OSError as exc: if exc.errno in (errno.ESRCH, errno.EPERM): print("Lock File is there but" diff --git a/rhodecode/lib/vcs/backends/git/repository.py b/rhodecode/lib/vcs/backends/git/repository.py --- a/rhodecode/lib/vcs/backends/git/repository.py +++ b/rhodecode/lib/vcs/backends/git/repository.py @@ -28,7 +28,7 @@ import re from zope.cachedescriptors.property import Lazy as LazyProperty -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.datelib import ( utcdate_fromtimestamp, makedate, date_astimestamp) from rhodecode.lib.utils import safe_unicode, safe_str diff --git a/rhodecode/lib/vcs/backends/hg/repository.py b/rhodecode/lib/vcs/backends/hg/repository.py --- a/rhodecode/lib/vcs/backends/hg/repository.py +++ b/rhodecode/lib/vcs/backends/hg/repository.py @@ -29,7 +29,7 @@ import urllib.request, urllib.parse, url from zope.cachedescriptors.property import Lazy as LazyProperty -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.datelib import ( date_to_timestamp_plus_offset, utcdate_fromtimestamp, makedate) from rhodecode.lib.utils import safe_unicode, safe_str diff --git a/rhodecode/lib/vcs/backends/svn/repository.py b/rhodecode/lib/vcs/backends/svn/repository.py --- a/rhodecode/lib/vcs/backends/svn/repository.py +++ b/rhodecode/lib/vcs/backends/svn/repository.py @@ -28,7 +28,7 @@ import urllib.request, urllib.parse, url from zope.cachedescriptors.property import Lazy as LazyProperty -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.datelib import date_astimestamp from rhodecode.lib.utils import safe_str, safe_unicode from rhodecode.lib.utils2 import CachedProperty diff --git a/rhodecode/model/pull_request.py b/rhodecode/model/pull_request.py --- a/rhodecode/model/pull_request.py +++ b/rhodecode/model/pull_request.py @@ -38,7 +38,7 @@ from rhodecode.lib.vcs.nodes import File from rhodecode.translation import lazy_ugettext from rhodecode.lib import helpers as h, hooks_utils, diffs from rhodecode.lib import audit_logger -from rhodecode.lib.compat import OrderedDict +from collections import OrderedDict from rhodecode.lib.hooks_daemon import prepare_callback_daemon from rhodecode.lib.markup_renderer import ( DEFAULT_COMMENTS_RENDERER, RstTemplateRenderer)