gerritbot added a comment.
Change 309088 merged by jenkins-bot:
Additional fixes for T143897
https://gerrit.wikimedia.org/r/309088TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: gerritbotCc: Esc3300,
gerritbot added a comment.
Change 309088 had a related patch set uploaded (by Smalyshev):
Additional fixes for T143897
https://gerrit.wikimedia.org/r/309088TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To:
Esc3300 added a comment.
It seems that something like this stopped working (similar to the "temporary workaround" above T143897#2582831):
SELECT ?person ?deathDate
{
?person wdt:P31 wd:Q5 .
?person wdt:P570 ?deathDate .
FILTER ( now() < (?deathDate+"P1Y"^^xsd:duration) )
}
It throws a
gerritbot added a comment.
Change 308012 merged by jenkins-bot:
Fix NotMaterializedException on date comparisons with strings
https://gerrit.wikimedia.org/r/308012TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL
gerritbot added a comment.
Change 308012 had a related patch set uploaded (by Smalyshev):
Fix NotMaterializedException on date comparisons with strings
https://gerrit.wikimedia.org/r/308012TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL
Esc3300 added a comment.
Not really, the culprit seems to be https://www.wikidata.org/wiki/Q5186062 with year "0"
Found with:
SELECT ?person ?deathDate
{
?person wdt:P570 ?deathDate .
FILTER(!sameTerm( dataType( ?deathDate ), xsd:dateTime ) )
?person wdt:P31 wd:Q5 .
}
TASK
Alphos added a comment.
Or, to handle the string literals too :
# People who died in the last 7 days
SELECT ?person ?deathDate {
?person wdt:P31 wd:Q5 .
?person wdt:P570 ?deathDate .
FILTER( IF ( sameTerm(dataType(?deathDate), xsd:dateTime), ?deathDate >= ( NOW() - "P7D"^^xsd:duration ),
Esc3300 added a comment.
Good news about duration. Another possible workaround could be:
# People who died in the last 7 days
SELECT ?person ?deathDate {
?person wdt:P31 wd:Q5 .
?person wdt:P570 ?deathDate .
FILTER ( ?dod > "2016-08-20T00:00:00Z"^^xsd:dateTime)
FILTER ( ?deathDate >=
Smalyshev added a comment.
Temporary fix:
# People who died in the last 7 days
SELECT ?person ?deathDate {
?person wdt:P31 wd:Q5 .
?person wdt:P570 ?deathDate .
FILTER(sameTerm(dataType(?deathDate), xsd:dateTime))
FILTER ( ?deathDate >= (now()-"P7D"^^xsd:duration) )
}
The bug is
Smalyshev added a comment.
Fix for duration arithmetics is deployed, leaving open for the exception issue.TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: SmalyshevCc: gerritbot, Smalyshev, Alphos,
Smalyshev added a comment.
The +/- part will be fixed soon, filed https://jira.blazegraph.com/browse/BLZG-2077 for the exception part.TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: SmalyshevCc: gerritbot,
gerritbot added a comment.
Change 307347 merged by jenkins-bot:
Fix negative duration handling
https://gerrit.wikimedia.org/r/307347TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To: gerritbotCc: gerritbot,
gerritbot added a comment.
Change 307347 had a related patch set uploaded (by Smalyshev):
Fix negative duration handling
https://gerrit.wikimedia.org/r/307347TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To:
Alphos added a comment.
It's weirder than you think :
SELECT ?now WHERE {
BIND( ( NOW() - "P7D"^^xsd:duration ) AS ?now ) .
}
returns "Sep 1, 2016", which is 6 days from today (we're 2016-08-25T23:55:00.000+02:00, give or take a few minutes)
SELECT ?now WHERE {
BIND( (
Smalyshev added a comment.
That's weird that it works with + but not with -. Looks like a bug somewhere in comparison or math implementation. I'll take a look.TASK DETAILhttps://phabricator.wikimedia.org/T143897EMAIL PREFERENCEShttps://phabricator.wikimedia.org/settings/panel/emailpreferences/To:
Alphos added a comment.
Temporary workaround :
# People who died in the last week
# Well, more accurately, people whose death + 7 days is after the current day and time, but still !
SELECT ?human ?humanLabel ?date
WHERE
{
?human wdt:P31 wd:Q5;
wdt:P570 ?date.
FILTER(?date +
16 matches
Mail list logo