Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitce4afe4

Browse files
trym-bByron
authored andcommitted
Revert "Replace wildcard imports with concrete imports"
This reverts commit53d94b8.The reason for the revert is that the commit in question introduced aregression where certain modules, functions and classes that wereexposed before were no longer exposed.See#1352 (comment)for additional information.
1 parent53d94b8 commitce4afe4

File tree

6 files changed

+30
-32
lines changed

6 files changed

+30
-32
lines changed

‎git/__init__.py

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# the BSD License: http://www.opensource.org/licenses/bsd-license.php
66
# flake8: noqa
77
#@PydevCodeAnalysisIgnore
8-
fromgit.excimportGitError,GitCommandError,GitCommandNotFound,UnmergedEntriesError,CheckoutError,InvalidGitRepositoryError,NoSuchPathError,BadName# @NoMove @IgnorePep8
8+
fromgit.excimport*# @NoMove @IgnorePep8
99
importinspect
1010
importos
1111
importsys
@@ -39,16 +39,16 @@ def _init_externals() -> None:
3939
#{ Imports
4040

4141
try:
42-
fromgit.configimportGitConfigParser# @NoMove @IgnorePep8
43-
fromgit.objectsimportBlob,Commit,Object,Submodule,Tree# @NoMove @IgnorePep8
44-
fromgit.refsimportHead,Reference,RefLog,RemoteReference,SymbolicReference,TagReference# @NoMove @IgnorePep8
45-
fromgit.diffimportDiff,DiffIndex,NULL_TREE# @NoMove @IgnorePep8
46-
fromgit.dbimportGitCmdObjectDB,GitDB# @NoMove @IgnorePep8
47-
fromgit.cmdimportGit# @NoMove @IgnorePep8
48-
fromgit.repoimportRepo# @NoMove @IgnorePep8
49-
fromgit.remoteimportFetchInfo,PushInfo,Remote,RemoteProgress# @NoMove @IgnorePep8
50-
fromgit.indeximportBlobFilter,IndexEntry,IndexFile# @NoMove @IgnorePep8
51-
fromgit.utilimport (# @NoMove @IgnorePep8
42+
fromgit.configimportGitConfigParser# @NoMove @IgnorePep8
43+
fromgit.objectsimport*# @NoMove @IgnorePep8
44+
fromgit.refsimport*# @NoMove @IgnorePep8
45+
fromgit.diffimport*# @NoMove @IgnorePep8
46+
fromgit.dbimport*# @NoMove @IgnorePep8
47+
fromgit.cmdimportGit# @NoMove @IgnorePep8
48+
fromgit.repoimportRepo# @NoMove @IgnorePep8
49+
fromgit.remoteimport*# @NoMove @IgnorePep8
50+
fromgit.indeximport*# @NoMove @IgnorePep8
51+
fromgit.utilimport (# @NoMove @IgnorePep8
5252
LockFile,
5353
BlockingLockFile,
5454
Stats,

‎git/exc.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
# the BSD License: http://www.opensource.org/licenses/bsd-license.php
66
""" Module containing all exceptions thrown throughout the git package, """
77

8-
fromgitdb.excimportBadName,BadObject# NOQA @UnusedWildImport skipcq: PYL-W0401, PYL-W0614
8+
fromgitdb.excimportBadName# NOQA @UnusedWildImport skipcq: PYL-W0401, PYL-W0614
9+
fromgitdb.excimport*# NOQA @UnusedWildImport skipcq: PYL-W0401, PYL-W0614
910
fromgit.compatimportsafe_decode
1011

1112
# typing ----------------------------------------------------

‎git/index/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
"""Initialize the index package"""
22
# flake8: noqa
3-
from .baseimportIndexFile
4-
from .typimportIndexEntry,BlobFilter
3+
from .baseimport*
4+
from .typimport*

‎git/objects/__init__.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
# flake8: noqa
55
importinspect
66

7-
from .baseimportObject,IndexObject
8-
from .blobimportBlob
9-
from .commitimportCommit
7+
from .baseimport*
8+
from .blobimport*
9+
from .commitimport*
1010
from .submoduleimportutilassmutil
11-
from .submodule.baseimportSubmodule,UpdateProgress
12-
from .submodule.rootimportRootModule,RootUpdateProgress
13-
from .tagimportTagObject
14-
from .treeimportTree
11+
from .submodule.baseimport*
12+
from .submodule.rootimport*
13+
from .tagimport*
14+
from .treeimport*
1515
# Fix import dependency - add IndexObject to the util module, so that it can be
1616
# imported by the submodule.base
1717
smutil.IndexObject=IndexObject# type: ignore[attr-defined]

‎git/refs/__init__.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# flake8: noqa
22
# import all modules in order, fix the names they require
3-
from .symbolicimportSymbolicReference
4-
from .referenceimportReference
5-
from .headimportHEAD,Head
6-
from .tagimportTagReference
7-
from .remoteimportRemoteReference
3+
from .symbolicimport*
4+
from .referenceimport*
5+
from .headimport*
6+
from .tagimport*
7+
from .remoteimport*
88

9-
from .logimportRefLogEntry,RefLog
9+
from .logimport*

‎test/lib/__init__.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,9 @@
44
# This module is part of GitPython and is released under
55
# the BSD License: http://www.opensource.org/licenses/bsd-license.php
66

7+
# flake8: noqa
78
importinspect
8-
9-
from .helperimport (GIT_DAEMON_PORT,SkipTest,StringProcessAdapter,TestBase,
10-
TestCase,fixture,fixture_path,
11-
with_rw_and_rw_remote_repo,with_rw_directory,
12-
with_rw_repo)
9+
from .helperimport*
1310

1411
__all__= [nameforname,objinlocals().items()
1512
ifnot (name.startswith('_')orinspect.ismodule(obj))]

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp