1

I want to disable or filter the warning below.

The later, seems to come from the zeep logger, so I've tried to set this logger level to CRITICAL to avoid the warning message, using the command below, but it didn't work.

logging.getLogger("zeep").setLevel(logging.CRITICAL)

To reformulate my problem, I am expecting that the following message doesn't appear either on the console or the log file.

Traceback (most recent call last):
  File "C:/Users/aelbouha/Desktop/Bnetza DataSet/mastr_temp.py", line 458, in download_unit_wind_permit
    unit_wind_permit = get_unit_wind_permit(unit_wind_list[i])
  File "C:/Users/aelbouha/Desktop/Bnetza DataSet/mastr_temp.py", line 245, in get_unit_wind_permit
    genMastrNummer=mastr_wind_permit)
  File "C:\Users\aelbouha\AppData\Local\Continuum\anaconda3\lib\site-packages\zeep\proxy.py", line 45, in __call__
    kwargs,
  File "C:\Users\aelbouha\AppData\Local\Continuum\anaconda3\lib\site-packages\zeep\wsdl\bindings\soap.py", line 130, in send
    return self.process_reply(client, operation_obj, response)
  File "C:\Users\aelbouha\AppData\Local\Continuum\anaconda3\lib\site-packages\zeep\wsdl\bindings\soap.py", line 195, in process_reply
    return self.process_error(doc, operation)
  File "C:\Users\aelbouha\AppData\Local\Continuum\anaconda3\lib\site-packages\zeep\wsdl\bindings\soap.py", line 299, in process_error
    detail=fault_node.find("detail"),
zeep.exceptions.Fault: Objekt nicht gefunden
hoefling
  • 59,418
  • 12
  • 147
  • 194
aelbouha
  • 11
  • 2
  • 1
    Possible duplicate of [Python logging: disable stack trace](https://stackoverflow.com/questions/54605699/python-logging-disable-stack-trace) – hoefling Jul 15 '19 at 14:26
  • The answer in the linked question should suit your needs. Alternatively, you can disable propagation for `zeep` logger via `logging.getLogger("zeep").propagate = False`, but this will turn off `zeep` logger completely, so no messages will be emitted from it at all. – hoefling Jul 15 '19 at 14:31

0 Answers0