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
8e07c62a
Kaydet (Commit)
8e07c62a
authored
Ara 03, 2004
tarafından
Vinay Sajip
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed errors reported in SF bug #1074693
üst
e1311180
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
6 deletions
+23
-6
liblogging.tex
Doc/lib/liblogging.tex
+23
-6
No files found.
Doc/lib/liblogging.tex
Dosyayı görüntüle @
8e07c62a
...
@@ -35,6 +35,21 @@ constrained to use these levels: you can specify your own and use a
...
@@ -35,6 +35,21 @@ constrained to use these levels: you can specify your own and use a
more general
\class
{
Logger
}
method,
\method
{
log()
}
, which takes an
more general
\class
{
Logger
}
method,
\method
{
log()
}
, which takes an
explicit level argument.
explicit level argument.
The numeric values of logging levels are given in the following table. These
are primarily of interest if you want to define your own levels, and need
them to have specific values relative to the predefined levels. If you
define a level with the same numeric value, it overwrites the predefined
value; the predefined name is lost.
\begin{tableii}
{
l|l
}{
code
}{
Level
}{
Numeric value
}
\lineii
{
CRITICAL
}{
50
}
\lineii
{
ERROR
}{
40
}
\lineii
{
WARNING
}{
30
}
\lineii
{
INFO
}{
20
}
\lineii
{
DEBUG
}{
10
}
\lineii
{
NOTSET
}{
0
}
\end{tableii}
Levels can also be associated with loggers, being set either by the
Levels can also be associated with loggers, being set either by the
developer or through loading a saved logging configuration. When a
developer or through loading a saved logging configuration. When a
logging method is called on a logger, the logger compares its own
logging method is called on a logger, the logger compares its own
...
@@ -297,8 +312,9 @@ constructor sets this attribute to 1.
...
@@ -297,8 +312,9 @@ constructor sets this attribute to 1.
Sets the threshold for this logger to
\var
{
lvl
}
. Logging messages
Sets the threshold for this logger to
\var
{
lvl
}
. Logging messages
which are less severe than
\var
{
lvl
}
will be ignored. When a logger is
which are less severe than
\var
{
lvl
}
will be ignored. When a logger is
created, the level is set to
\constant
{
NOTSET
}
(which causes all messages
created, the level is set to
\constant
{
NOTSET
}
(which causes all messages
to be processed in the root logger, or delegation to the parent in non-root
to be processed when the logger is the root logger, or delegation to the
loggers).
parent when the logger is a non-root logger). Note that the root logger
is created with level
\constant
{
WARNING
}
.
\end{methoddesc}
\end{methoddesc}
\begin{methoddesc}
{
isEnabledFor
}{
lvl
}
\begin{methoddesc}
{
isEnabledFor
}{
lvl
}
...
@@ -1324,10 +1340,6 @@ also includes information such as when the record was created, the
...
@@ -1324,10 +1340,6 @@ also includes information such as when the record was created, the
source line where the logging call was made, and any exception
source line where the logging call was made, and any exception
information to be logged.
information to be logged.
\class
{
LogRecord
}
has no methods; it's just a repository for
information about the logging event. The only reason it's a class
rather than a dictionary is to facilitate extension.
\begin{classdesc}
{
LogRecord
}{
name, lvl, pathname, lineno, msg, args,
\begin{classdesc}
{
LogRecord
}{
name, lvl, pathname, lineno, msg, args,
exc
_
info
}
exc
_
info
}
Returns an instance of
\class
{
LogRecord
}
initialized with interesting
Returns an instance of
\class
{
LogRecord
}
initialized with interesting
...
@@ -1342,6 +1354,11 @@ which, together with \var{msg}, makes up the user message; and
...
@@ -1342,6 +1354,11 @@ which, together with \var{msg}, makes up the user message; and
is available).
is available).
\end{classdesc}
\end{classdesc}
\begin{methoddesc}
{
getMessage
}{}
Returns the message for this
\class
{
LogRecord
}
instance after merging any
user-supplied arguments with the message.
\end{methoddesc}
\subsection
{
Thread Safety
}
\subsection
{
Thread Safety
}
The logging module is intended to be thread-safe without any special work
The logging module is intended to be thread-safe without any special work
...
...
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