[Python]'NoneType' object has no attribute'text' problem solved

The error is as follows:'NoneType' object has no attribute'text', because try-except is used to print out the error message.

Solution:

 In the process of writing code, this tag class was accidentally omitted, so that the find function cannot know what the passed parameter is, so there is no text attribute. After adding it, the program can run normally.

Guess you like

Origin blog.csdn.net/weixin_44566432/article/details/107918080