Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
335e14dd
Kaydet (Commit)
335e14dd
authored
Ock 04, 2014
tarafından
Eric Snow
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #19713: Move away from using find_module/load_module.
üst
d749c7ae
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
5 deletions
+12
-5
test_tools.py
Lib/test/test_tools.py
+5
-4
NEWS
Misc/NEWS
+2
-0
setup.py
setup.py
+5
-1
No files found.
Lib/test/test_tools.py
Dosyayı görüntüle @
335e14dd
...
...
@@ -6,6 +6,7 @@ Tools directory of a Python checkout or tarball, such as reindent.py.
import
os
import
sys
import
importlib._bootstrap
import
importlib.machinery
import
unittest
from
unittest
import
mock
...
...
@@ -405,8 +406,8 @@ class PdepsTests(unittest.TestCase):
@classmethod
def
setUpClass
(
self
):
path
=
os
.
path
.
join
(
scriptsdir
,
'pdeps.py'
)
loader
=
importlib
.
machinery
.
SourceFileLoader
(
'pdeps'
,
path
)
self
.
pdeps
=
loader
.
load_module
()
spec
=
importlib
.
util
.
spec_from_file_location
(
'pdeps'
,
path
)
self
.
pdeps
=
importlib
.
_bootstrap
.
_SpecMethods
(
spec
)
.
load
()
@classmethod
def
tearDownClass
(
self
):
...
...
@@ -430,8 +431,8 @@ class Gprof2htmlTests(unittest.TestCase):
def
setUp
(
self
):
path
=
os
.
path
.
join
(
scriptsdir
,
'gprof2html.py'
)
loader
=
importlib
.
machinery
.
SourceFileLoader
(
'gprof2html'
,
path
)
self
.
gprof
=
loader
.
load_module
()
spec
=
importlib
.
util
.
spec_from_file_location
(
'gprof2html'
,
path
)
self
.
gprof
=
importlib
.
_bootstrap
.
_SpecMethods
(
spec
)
.
load
()
oldargv
=
sys
.
argv
def
fixup
():
sys
.
argv
=
oldargv
...
...
Misc/NEWS
Dosyayı görüntüle @
335e14dd
...
...
@@ -255,6 +255,8 @@ Library
- Issue #6477: Added support for pickling the types of built-in singletons
(i.e., Ellipsis, NotImplemented, None).
- Issue #19713: Move away from using find_module/load_module.
- Issue #19851: Fixed a regression in reloading sub-modules.
- ssl.create_default_context() sets OP_NO_COMPRESSION to prevent CRIME.
...
...
setup.py
Dosyayı görüntüle @
335e14dd
...
...
@@ -3,6 +3,8 @@
import
sys
,
os
,
importlib
.
machinery
,
re
,
optparse
from
glob
import
glob
import
importlib._bootstrap
import
importlib.util
import
sysconfig
from
distutils
import
log
...
...
@@ -327,8 +329,10 @@ class PyBuildExt(build_ext):
return
loader
=
importlib
.
machinery
.
ExtensionFileLoader
(
ext
.
name
,
ext_filename
)
spec
=
importlib
.
util
.
spec_from_file_location
(
ext
.
name
,
ext_filename
,
loader
=
loader
)
try
:
loader
.
load_module
()
importlib
.
_bootstrap
.
_SpecMethods
(
spec
)
.
load
()
except
ImportError
as
why
:
self
.
failed
.
append
(
ext
.
name
)
self
.
announce
(
'*** WARNING: renaming "
%
s" since importing it'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment