X-Received: by 2002:a05:620a:2489:b0:6af:4b28:818d with SMTP id i9-20020a05620a248900b006af4b28818dmr19364022qkn.662.1656937588374; Mon, 04 Jul 2022 05:26:28 -0700 (PDT) X-Received: by 2002:a05:6870:390d:b0:101:ab20:2763 with SMTP id b13-20020a056870390d00b00101ab202763mr16432291oap.233.1656937588062; Mon, 04 Jul 2022 05:26:28 -0700 (PDT) Path: csiph.com!1.us.feeder.erje.net!feeder.erje.net!border1.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: de.comp.lang.python Date: Mon, 4 Jul 2022 05:26:27 -0700 (PDT) In-Reply-To: Injection-Info: google-groups.googlegroups.com; posting-host=87.71.7.244; posting-account=TEsHeAoAAAARE3wCPbXq05j6DF-fM4ap NNTP-Posting-Host: 87.71.7.244 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: [Python-de] Re: Ich sende erneut - der Code war nicht klar- python - From: Linnea G Injection-Date: Mon, 04 Jul 2022 12:26:28 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Lines: 90 Xref: csiph.com de.comp.lang.python:5826 On Monday, 4 July 2022 at 14:29:24 UTC+3, Massa, Harald Armin wrote: > Hi Linnea,=20 >=20 > -------------------------------------------------------------------------= ------------=20 > >=20 > > loggin.conf:=20 > >=20 > >=20 > > -----------------------------------------------------------------------= --------------=20 > > [handler_consoleHandler]=20 > > class=3DStreamHandler=20 > > level=3DDEBUG=20 > > * formatter*=3DsimpleFormatter=20 > > args=3D(sys.stdout,)=20 > >=20 > > [*formatter_simpleFormatter*] > > format=3D'%(asctime)s - %(name)s %(levelname)s - %(message)s'=20 > >=20 > > -----------------------------------------------------------------------= --------------=20 > >=20 > > Als ich lief, bekam ich diesen Fehler:=20 > >=20 > >=20 > > -----------------------------------------------------------------------= -------------- > > flist =3D cp["formatters"]["keys"]=20 > > File "C:\Program Files (x86)\Microsoft Visual=20 > > Studio\Shared\Python37_64\lib\configparser.py", line 958, in __getitem_= _=20 > > raise KeyError(key)=20 > > KeyError: 'formatters'=20 > >=20 > > -----------------------------------------------------------------------= --------------=20 > > > configparser erwartet einen Eintrag mit dem Schl=C3=BCssel "formatters".= =20 > In Deiner Config sehe ich nur "formatter" und "formatter_simpleFormatter"= =20 >=20 >=20 > Wenn Du mal schaust unter=20 > https://docs.python.org/3/library/logging.config.html=20 >=20 > Abschnitt ConfigurationFileFormat=20 >=20 > dort werden Sectionen, [formatters], [loggers] und [handlers] gefordert -= =20 > die sehe ich in Deiner config nicht=20 >=20 > (quote von jener Seite)=20 >=20 > [loggers]keys=3Droot,log02,log03,log04,log05,log06,log07=20 > [handlers]keys=3Dhand01,hand02,hand03,hand04,hand05,hand06,hand07,hand08,= hand09=20 > [formatters]keys=3Dform01,form02,form03,form04,form05,form06,form07,form0= 8,form09=20 >=20 >=20 >=20 >=20 >=20 >=20 >=20 >=20 >=20 > > _______________________________________________=20 > > python-de Mailingliste -- pyth...@python.org=20 > > Zur Abmeldung von dieser Mailingliste senden Sie eine Nachricht an=20 > > python-...@python.org=20 > > https://mail.python.org/mailman3/lists/python-de.python.org/=20 > > Mitgliedsadresse: ch...@ghum.de=20 > >=20 >=20 >=20 > --=20 >=20 > GHUM GmbH=20 > Harald Armin Massa=20 > Spielberger Stra=C3=9Fe 49=20 > 70435 Stuttgart=20 > 0173/9409607=20 >=20 > Amtsgericht Stuttgart, HRB 734971=20 > GF: Harald Armin Massa Vielen Dank!! Das war die L=C3=B6sung!!