Closed dittnamn closed 4 years ago
The validation is done based on our internal vocabulary representation for OGP, which you can see here. You'll note that it doesn't include og:image:alt
. The vocabulary is built automatically from http://ogp.me/ns/ogp.me.ttl, which interestingly, also doesn't include that term. I could add build instructions to add it, but I'm loath to have to maintain the vocabulary manually. Ideally, Facebook would ensure that their vocabulary description in Turtle matches the documentation.
However, you shouldn't get an undefined method 'property?'
error. It may complain that you're using an undefined property, but shouldn't error out.
Alright, I see. I tried to see if there's any way to report that to the OGP team, but the Facebook page seems inactive, the mailing list is removed and the Github project has been archived. It looks like Facebook has abandoned the project, as they're not even using it themselves anymore.
I think it might be enough if the error could be changed to a warning, so that the rest of the code could be checked as well.
I went ahead and added 3 missing terms to the OGP vocabulary; doesn't look like it's going to need much further maintenance.
Great, that was quick. I do still get a warning with the same code though:
property http://ogp.me/ns#image:alt: Object "A shiny red apple with a bite taken out" not compatible with range (ogc:url)
Could it be that og:image:alt should be in the range ogc:string instead of ogc:url?
Sorry, I got the range of og:image:alt
wrong, I'll get another update out shortly.
Okay, you should see version 3.8.3 up shortly which has a fix.
Hello, I tried using the linter and when using the tags og:image:alt or og:locale:alternate, it stops without checking the rest of the code. The tags are correct according to the ogp.me website.
Example error message:
error NoMethodError: undefined method 'property?' for #<RDF::URI:0x5931c URI:http://ogp.me/ns#image:alt> Did you mean? subProperty
Example codes that fail (copied from the ogp.me website):