Page MenuHomePhabricator

Empty map results give an error
Closed, ResolvedPublic5 Story Points

Description

Both of these queries show unhelpful errors instead of a helpful warning message like "no data was found". Also, looking at the code, there seems to be no way for the visualizer to show a custom error message in the error band above visualizer.

Returns a single empty object

#defaultView:Map
SELECT ?place ?placeLabel ?location
WHERE {}
{
  "head" : {    "vars" : [ "place", "placeLabel", "location" ]  },
  "results" : {    "bindings" : [ { } ]  }
}

Returns empty response

#defaultView:Map
SELECT ?place ?placeLabel ?location
WHERE { wd:Q0 wdt:P0 ?location  . }
{
  "head" : {    "vars" : [ "place", "placeLabel", "location" ]  },
  "results" : {    "bindings" : [ ]  }
}

Details

Related Gerrit Patches:
wikidata/query/gui : masterFix: Empty map results give an error

Event Timeline

Yurik created this task.Oct 23 2017, 1:18 AM
Restricted Application added projects: Wikidata, Discovery. · View Herald TranscriptOct 23 2017, 1:18 AM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Jonas raised the priority of this task from Medium to High.Dec 4 2017, 10:31 AM
Jonas moved this task from Backlog to Bugs on the Wikidata Query UI board.
Jonas set the point value for this task to 5.Sep 4 2018, 1:29 PM
Jonas moved this task from Ready to estimate to In Progress on the Wikidata-Campsite board.
Addshore moved this task from incoming to in progress on the Wikidata board.Sep 17 2018, 8:17 AM

Change 462414 had a related patch set uploaded (by Jonas Kress (WMDE); owner: Jonas Kress (WMDE)):
[wikidata/query/gui@master] Fix: Empty map results give an error

https://gerrit.wikimedia.org/r/462414

Change 462414 merged by jenkins-bot:
[wikidata/query/gui@master] Fix: Empty map results give an error

https://gerrit.wikimedia.org/r/462414