Message from Python discussions

November 2018

— (It's redis)


Well is a custom filter for pytb which will enable a function if some criterias are meet

That filter has multiple arguments:

the main one is the words to which I use a if to check if the words are in the text

Now there are multiple args:
starts_with (if the text starts with a word from that list) which if is true will trigger the handler otherwhise if is false the code will just check if the list of words are in the text.)

ignore_markdown (if is set to true will check if there is a markdown text in the text and if it's True to send a False command to the handler

And ignore_html is the same as above but with html text

— The False bool will not trigger the handler so nothing is happening

— Can you share your code in hastebin or

— Https://

— I'm still trying to figure out how to do it

— Ignore the last if

— I think that now i need something to return false if any of those are True.. maybe another if?

— I could use return False if any of these are true and not word in text?

— Fixed the if == statements

— Hi. I am using xml.etree.ElementTree to parse docbook XML. But it appeared that there are HTML special character entities inside my file, for instance ë Now I see the following exception raised during parse():

xml.etree.ElementTree.ParseError: undefined entity ë: line 7191, column 64

What is the proper way to avoid such errors?

Message permanent page

— What do you want to do exactly? verify that response is text?