Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

"Never make any mistaeks." (Anonymous, in a mail discussion about to a kernel bug report.)


devel / comp.lang.python / Re: logging library python

SubjectAuthor
* logging library pythonתמר ווסה
`- Re: logging library pythonDan Stromberg

1
logging library python

<04dcd013-0c87-4405-a54c-28487c704d68n@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=18064&group=comp.lang.python#18064

  copy link   Newsgroups: comp.lang.python
X-Received: by 2002:ac8:5754:0:b0:2e1:eee8:be0b with SMTP id 20-20020ac85754000000b002e1eee8be0bmr20172422qtx.349.1651088640573;
Wed, 27 Apr 2022 12:44:00 -0700 (PDT)
X-Received: by 2002:a05:6214:2243:b0:44f:24d8:16a3 with SMTP id
c3-20020a056214224300b0044f24d816a3mr21388368qvc.51.1651088640344; Wed, 27
Apr 2022 12:44:00 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.python
Date: Wed, 27 Apr 2022 12:44:00 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=87.71.25.101; posting-account=duQ_2AkAAAD_1emxWwInZVAW1qE2hrwt
NNTP-Posting-Host: 87.71.25.101
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <04dcd013-0c87-4405-a54c-28487c704d68n@googlegroups.com>
Subject: logging library python
From: tamarp...@gmail.com (תמר ווסה)
Injection-Date: Wed, 27 Apr 2022 19:44:00 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 6
 by: תמר ווסה - Wed, 27 Apr 2022 19:44 UTC

hello,
we have many scripts of one project. what is the right way to define the logger to all scripts? we tried to create class that define the logger configuration+generic function (handler functions to write generic log message), and each script define an instance of the class. But the log info is reference to the class script and not the right script. Should we need not to use the class ? should we need define logger to each script ?

Re: logging library python

<mailman.268.1651107873.20749.python-list@python.org>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=18069&group=comp.lang.python#18069

  copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail
From: drsali...@gmail.com (Dan Stromberg)
Newsgroups: comp.lang.python
Subject: Re: logging library python
Date: Wed, 27 Apr 2022 18:04:20 -0700
Lines: 18
Message-ID: <mailman.268.1651107873.20749.python-list@python.org>
References: <04dcd013-0c87-4405-a54c-28487c704d68n@googlegroups.com>
<CAGGBd_ohKRK9X76B-WDF6cG7Gwb-UcRsGQjpiqyu84=magJ+CQ@mail.gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Trace: news.uni-berlin.de SB75niHEY+QmQvTDjkXxFQj349H8HZec5t0m4rEf9iRg==
Return-Path: <drsalists@gmail.com>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=pass
reason="2048-bit key; unprotected key"
header.d=gmail.com header.i=@gmail.com header.b=bazpmeme;
dkim-adsp=pass; dkim-atps=neutral
X-Spam-Status: OK 0.002
X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '2022': 0.05;
'subject:python': 0.06; 'class.': 0.07; 'subject:library': 0.07;
'27,': 0.09; 'cc:addr:python-list': 0.09; 'hello,\xc2\xa0': 0.09;
'log': 0.12; 'url:mailman': 0.15; 'cc:name:python list': 0.16;
'from:addr:drsalists': 0.16; 'from:name:dan stromberg': 0.16;
'instance': 0.16; 'received:209.85.217': 0.16; 'script.': 0.16;
'subject:logging': 0.16; 'probably': 0.17; 'cc:addr:python.org':
0.20; 'url-ip:188.166.95.178/32': 0.25; 'url-ip:188.166.95/24':
0.25; 'url:listinfo': 0.25; 'cc:2**0': 0.25; 'url-ip:188.166/16':
0.25; 'tried': 0.26; 'project.': 0.27; 'function': 0.27; 'url-
ip:188/8': 0.31; 'message-id:@mail.gmail.com': 0.32; 'but': 0.32;
'script': 0.33; 'header:In-Reply-To:1': 0.34;
'received:google.com': 0.34; 'close': 0.35; 'from:addr:gmail.com':
0.35; 'functions': 0.36; 'received:209.85': 0.37; 'class': 0.37;
'way': 0.38; 'received:209': 0.39; 'use': 0.39; 'wed,': 0.39;
'define': 0.40; 'something': 0.40; 'hello,': 0.40; 'want': 0.40;
'should': 0.40; 'reference': 0.60; 'to:charset:utf-8': 0.61;
'right': 0.68; '8bit%:100': 0.76
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
h=mime-version:references:in-reply-to:from:date:message-id:subject:to
:cc; bh=8HCKQfmgPKnhE/Jr14PfX6AlsJtN+YT5ueToaPOUtyE=;
b=bazpmemeeAZRooLgPadRLTDeITONKcHXuvPJ4ufqZweAhn6b616WRoKLaHRGkXrSrJ
7nie8OPQdqOl+ziC4X6TINgAfXZxobzdEVV586zEaHDrFTF7rJOxstuq+Qey4E9oyaFe
Bc6vEetyYZeD6RDZxwaStp9P1BrE4AYRjTVgeUWJ3ZXJh2BFyhHAz8C8GHGRNopNpEka
eHn80ggh38vrbCZ18B/iQC7dLLJBNMoYr4/xnmt0wrOLEOSsRUmURk9xt9IhmbBLywAt
UXVCfmlPMH76jmJOvc67VOKbxUhyKz81XRYCM2I5Sdo9B4tc4W7KgLK0h8xrl4K2xlFn
qhHg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=x-gm-message-state:mime-version:references:in-reply-to:from:date
:message-id:subject:to:cc;
bh=8HCKQfmgPKnhE/Jr14PfX6AlsJtN+YT5ueToaPOUtyE=;
b=kZ7iIOumtOXvwqSBOvYsBdyNaiQCeaqs6h5OUm6ogZiKFJZcM69sGQZN0CK36BbTTH
76y7/sfG3pCX5RIuBVZVQLqrscXjUPVfsZvTcPvJMCiTnR/eTo+AgIcOqDhiUqtIAvvm
U0WLTDMNj4WZtPYDfVveELwBreLMhH3UwmaItFZKvoM18a8O/vNqaXvcwX9Gtup/fkTn
gftp0v0EOSROCT9t3SYr9DnBlg/jGiaJKPykprC1FXXDox1jcapif8QklzLVx9xIK1YG
9cm49NovTXcyKRMrVFxITdgCzcFlE7G/r6NmB1qv2K8XALUZ0VO0JpSOGiAWSUOEHRip
6MzQ==
X-Gm-Message-State: AOAM532cbyrV4spm6Is9OcCdZJjnrKbxbZnXktfYtU4EhFB+OFtSTfcx
rykTqOmABIGk15eO4rH2LSGVh8CdXPauhRE39T4=
X-Google-Smtp-Source: ABdhPJz1SmhXTsFaJbc05fVc4PF4HpXXxo0TTJMNOTWDWiefYPWszxKzZyOcD2KB2U41mHPxvGvJqJeaxOWRjtlHfbA=
X-Received: by 2002:a67:c981:0:b0:320:92c2:d2ee with SMTP id
y1-20020a67c981000000b0032092c2d2eemr8797153vsk.79.1651107871678; Wed, 27 Apr
2022 18:04:31 -0700 (PDT)
In-Reply-To: <04dcd013-0c87-4405-a54c-28487c704d68n@googlegroups.com>
X-Content-Filtered-By: Mailman/MimeDel 2.1.39
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <CAGGBd_ohKRK9X76B-WDF6cG7Gwb-UcRsGQjpiqyu84=magJ+CQ@mail.gmail.com>
X-Mailman-Original-References: <04dcd013-0c87-4405-a54c-28487c704d68n@googlegroups.com>
 by: Dan Stromberg - Thu, 28 Apr 2022 01:04 UTC

You probably want getLogger(__name__)

....or something close to it.

‪On Wed, Apr 27, 2022 at 12:58 PM ‫תמר ווסה‬‎ <tamarp540@gmail.com> wrote:‬

> hello,
> we have many scripts of one project. what is the right way to define the
> logger to all scripts? we tried to create class that define the logger
> configuration+generic function (handler functions to write generic log
> message), and each script define an instance of the class. But the log
> info is reference to the class script and not the right script. Should we
> need not to use the class ? should we need define logger to each script ?
> --
> https://mail.python.org/mailman/listinfo/python-list
>

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor