erikriver / opengraph

A python module to parse the Open Graph Protocol
http://ogp.me/
MIT License
226 stars 82 forks source link

According to http://ogp.me/ description is not required. #36

Open LeResKP opened 5 years ago

LeResKP commented 5 years ago

Also fix the example.

Please note the example from the readme was not working

HTML = """ ... ... The Rock (1996) ... ... ... ... ... ... ... ... ... ... """ import opengraph movie = opengraph.OpenGraph() movie.parser(HTML) movie.is_valid() False movie.required_attrs ['title', 'type', 'image', 'url', 'description'] movie.required_attrs.pop(-1) 'description' movie.is_valid() True