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
1db2ba3a
Kaydet (Commit)
1db2ba3a
authored
Şub 11, 2014
tarafından
Victor Stinner
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #20505: use also the monotonic time to decide if asyncio debug traces
should be printed
üst
5d1ea04b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
base_events.py
Lib/asyncio/base_events.py
+4
-3
No files found.
Lib/asyncio/base_events.py
Dosyayı görüntüle @
1db2ba3a
...
@@ -639,15 +639,16 @@ class BaseEventLoop(events.AbstractEventLoop):
...
@@ -639,15 +639,16 @@ class BaseEventLoop(events.AbstractEventLoop):
event_list
=
self
.
_selector
.
select
(
timeout
)
event_list
=
self
.
_selector
.
select
(
timeout
)
dt
=
time
.
perf_counter
()
-
t0
dt
=
time
.
perf_counter
()
-
t0
dt_monotonic
=
time
.
monotonic
()
-
t0_monotonic
dt_monotonic
=
time
.
monotonic
()
-
t0_monotonic
if
not
event_list
and
timeout
and
dt
<
timeout
:
if
(
not
event_list
and
timeout
and
(
dt
<
timeout
or
dt_monotonic
<
timeout
)):
selector
=
self
.
_selector
.
__class__
.
__name__
selector
=
self
.
_selector
.
__class__
.
__name__
if
(
selector
.
startswith
((
"Poll"
,
"Epoll"
,
"Iocp"
))
if
(
selector
.
startswith
((
"Poll"
,
"Epoll"
,
"Iocp"
))
or
timeout
>
1e-3
or
dt
>
1e-3
):
or
timeout
>
1e-3
or
dt
>
1e-3
):
unit
,
factor
=
"ms"
,
1e3
unit
,
factor
=
"ms"
,
1e3
else
:
else
:
unit
,
factor
=
"us"
,
1e6
unit
,
factor
=
"us"
,
1e6
print
(
"asyncio:
%
s.select(
%.
3
f
%
s) took
%.3
f
%
s"
print
(
"asyncio:
%
s.select(
%.
4
f
%
s) took
%.3
f
%
s"
" (monotonic
:
%.3
f
%
s, clock res:
%.3
f
%
s)"
" (monotonic
=
%.3
f
%
s, clock res=
%.3
f
%
s)"
%
(
self
.
_selector
.
__class__
.
__name__
,
%
(
self
.
_selector
.
__class__
.
__name__
,
timeout
*
factor
,
unit
,
timeout
*
factor
,
unit
,
dt
*
factor
,
unit
,
dt
*
factor
,
unit
,
...
...
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