Understanding RuntimeError

I’ve developed a new notebook to explore Wikidata using the Wikidata Query Service : CAT🐈: Overview of references / PAC | Observable

Some users report that they have " RuntimeError: Invalid column reference: "d.reference" (Wikidata:Bistro - Wikidata)

It’s hard to reproduce the error.

Do you have any advice on how to avoid to have this problem?

When I look at the cell that throws that error, it is the cell df which doesn’t properly handle the case for when array has no entries (d does not have an attribute called reference in that case). You should handle the case of array being empty.

1 Like