Re: Avoid nested SIGINT handling

2021-11-10 Thread Chris Angelico
On Thu, Nov 11, 2021 at 5:01 PM Jon Ribbens via Python-list wrote: > > On 2021-11-10, Paulo da Silva wrote: > > Hi! > > > > How do I handle a SIGINT (or any other signal) avoid nesting? > > I don't think you need to. Python will only call signal handlers in > the main thread, so a handler can't b

Re: Breaking new relic format on a new line character in FileHandler appender

2021-11-10 Thread Chris Angelico
On Thu, Nov 11, 2021 at 5:00 PM Vijay Karavadra via Python-list wrote: > > Hello Team, > > I'm trying to add logs in the new relic platform from a python application. > For that, I've to add logs in a local file in a specific format which is > > '{"log.level":"%(levelname)s", "log.entity.name":"my

Re: Avoid nested SIGINT handling

2021-11-10 Thread Paulo da Silva
Às 21:55 de 10/11/21, Jon Ribbens escreveu: > On 2021-11-10, Paulo da Silva wrote: >> Hi! >> >> How do I handle a SIGINT (or any other signal) avoid nesting? > > I don't think you need to. Python will only call signal handlers in > the main thread, so a handler can't be executed while another han

Avoid nested SIGINT handling

2021-11-10 Thread Paulo da Silva
Hi! How do I handle a SIGINT (or any other signal) avoid nesting? Does this work? class STATUS: InInt=False def SIGINT_handler(sn,f): if STATUS.InInt: return STATUS.InInt=True process_int() STATUS.InInt=False Thanks for any suggestions. Paulo -- https:/

Re: Avoid nested SIGINT handling

2021-11-10 Thread Jon Ribbens via Python-list
On 2021-11-10, Paulo da Silva wrote: > Hi! > > How do I handle a SIGINT (or any other signal) avoid nesting? I don't think you need to. Python will only call signal handlers in the main thread, so a handler can't be executed while another handler is running anyway. -- https://mail.python.org/mai

Breaking new relic format on a new line character in FileHandler appender

2021-11-10 Thread Vijay Karavadra via Python-list
Hello Team, I'm trying to add logs in the new relic platform from a python application. For that, I've to add logs in a local file in a specific format which is '{"log.level":"%(levelname)s", "log.entity.name":"my-service-name", "message":"%(message)s"}' This works fine in normal scenario and g

RE: Vnev issue - AttributeError: module 'sysconfig' has no attribute '_get_default_scheme'. Did you mean: 'get_default_scheme'?

2021-11-10 Thread pranesh kumar
Hi Shared a google sheet with details [1]https://docs.google.com/presentation/d/1W9wH08dfzA1XP5sqBBNj0bk0YPPGVG1z0-WQ3yt1NUU/edit?usp=sharing after importing OpenCV When typing "cv2." All functions related to the OpenCV module should show up which is not happening How t

Re: Py_IS_TYPE(op, &PyDict_Type) does not work on MacOS

2021-11-10 Thread Marco Sulla
Indeed now I use PyDict_Check, but anyway it's very strange that Py_IS_TYPE(op, &PyDict_Type) does not work only on MacOS. On Mon, 8 Nov 2021 at 19:30, Barry wrote: > > > > On 8 Nov 2021, at 07:45, Marco Sulla wrote: > > As you can read here: > > https://github.com/Marco-Sulla/python-frozendict