Wikidata:Contact the development team/Archive/2016/10

This page is an archive. Please do not modify it. Use the current page, even to continue an old discussion.

Problems with gender?

When approving or rejecting the claim gender female on Q456071 it re-apears again. Is there something going wrong? Same for Q520321. --Florentyna (talk) 16:11, 4 October 2016 (UTC)

Although I don't get any error from the primary sources tool, this doesn't work for me as well. I've created T147330 for this. Cheers, Hoo man (talk) 16:22, 4 October 2016 (UTC)

Formatter URLs requiring API keys

Please note the question I have raised, at Wikidata:Project chat#Formatter URLs requiring API keys. Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 16:21, 4 October 2016 (UTC)

OAuth, graph

I have written some pywikibot scripts at paws.wmflabs.org. Since I´m working together with some editors about cycling, I would like to know if I could allow them to enter my paws space? I´m logging in with OAuth to PAWS.

A second question: I have seen that it is possible to combine the graph-Extension and Wikidata. I have already done so as proof of concept. At the moment most use cases are about SPARQL and graph or just showing pie charts (without wikidata, I guess). I have thought about a lua function for our cycling module that prints a picture to visualize the gradient (de: Steigung) that a rider has to do when driving to the top of a mountain. Is there a technical reason not to do something like that? --Molarus 02:18, 5 October 2016 (UTC)

I don't know enough about the sharing ability of PAWS to answer the first question. Obviously sharing logins is not ok, while sharing scripts and other resources should be fine.
Regarding the GRAPH extension: I don't see any technical reason that would prevent you from covering that use case (if the data is there and Graph supports such graphs, which I guess it does). Cheers, Hoo man (talk) 07:22, 5 October 2016 (UTC)
Thanks. --Molarus 08:14, 5 October 2016 (UTC)

nofollow question

I asked this question on the project chat, was told to try here. Does anyone know what's the nofollow status of sitelinks to siterprojects in Wikidata items (the ones that generate the interwiki links on the sidebar)? In WP normal external links are nofollow but links using siterproject templates are not. The source is not visible here so I can't tell. Thanks, Acer (talk) 23:03, 6 October 2016 (UTC)

@Acer: The links in the interwiki box on the right have the following format: <a href="page-link" hreflang="language-code" title="page-title">page-title</a>, so there's no nofollow.
Regarding "The source is not visible here so I can't tell.": The produced html code is visible (as on all web pages, most browsers expose that on right click) and all of our software is open source. Have a look at http://wikiba.se/ if you want to get a high-level overview of the Wikibase software in use here. Cheers, Hoo man (talk) 09:41, 7 October 2016 (UTC)
Duh, I actually forgot about checking the HTML code directly... Too much Wiki editing I guess. Thanks :) Acer (talk) 12:12, 7 October 2016 (UTC)

merge.js and duplicate claims

This introduces a second P625 into the item. That is maybe not necessary, if the claims have no qualifiers? -- Innocent bystander (talk) 19:18, 10 October 2016 (UTC)

The coordinates are different though. Sjoerd de Bruin (talk) 19:22, 10 October 2016 (UTC)
Yes, and both of them could be deleted since they both are incorrect. -- Innocent bystander (talk) 06:14, 11 October 2016 (UTC)
But this is not what merge stands for. Matěj Suchánek (talk) 14:02, 11 October 2016 (UTC)
Maybe not, but when do we need two P625 without qualifiers in an item? -- Innocent bystander (talk) 19:34, 12 October 2016 (UTC)

undedected edit conflict

This edit is strange. I removed a statement shortly after the same statement was edited by another user but I was not warned about that. Moreover, the edit summary is inconsistent with the actual edit. --Pasleim (talk) 16:48, 12 October 2016 (UTC)

And I am probably the other user. I saw that claim disappear when I edited something else in the page. But when I reloaded the page, it was back. Very strange... -- Innocent bystander (talk) 20:20, 12 October 2016 (UTC)
Strange indeed but I fear it is hard to tell now what was going on. As long as this was a one time thing I'd say we leave it and more on. If it happens regularly we should spend time on investigating. --Lydia Pintscher (WMDE) (talk) 16:35, 17 October 2016 (UTC)

where do I go for up-to-date and complete api documentation?

I want to write a library for using the Wikidata api but I’m missing some documentation.

i have found the following sources:

the page om MediaWiki is not up-to-date and is missing the details that i need.

At the Wikidata api page I’m missing an explanation for a lot of the value parameters.

for example: wbsetreference needs a json object. but the only way of knowing what object is looking at the examples at the bottom. which don't have an example for time or quantity value.

and this continues on the other api module

so my question is documentation for all those small details.

--Wvdp (talk) 21:42, 13 October 2016 (UTC)

Thanks for the feedback. The two things you linked are the best we have but it is on my todo list to put work into improving it. --Lydia Pintscher (WMDE) (talk) 16:37, 17 October 2016 (UTC)

New items statistics

It would be interesting to know how new items are created, e.g. manually or by PetScan/QuickStatements/Bot.

Maybe this could help find ways to reduce Wikidata:Database reports/without claims by site.
--- Jura 10:12, 3 October 2016 (UTC)

This query gives you an overview over the last 30 days. --Pasleim (talk) 12:24, 9 October 2016 (UTC)
Tool/modenew pages% totalper day
bot13220856.844407
Widar4105417.651368
manual4076517.531359
Widar by NIOSH165697.12552
Widar through bot16210.754
WE-Framework gadget3110.1310
redirect460.022
wikishootme500

Thanks. Looks good. I consolidated them above. Seems suitable for grafana.
--- Jura 12:56, 9 October 2016 (UTC)

If a ticket is filed and approved by @Lydia_Pintscher_(WMDE): then I would be more than happy to add this to grafana. Otherwise I can link to the code and you can have a crack at adding it! ·addshore· talk to me! 12:28, 10 October 2016 (UTC)
@Addshore: If it consists mainly in setting up the query, I can give it a try. With the above, Pasleim already did most of it. How does it work?
--- Jura 10:24, 20 October 2016 (UTC)

Linking Wikipedia articles to items with no labels in the given language

I think it would be a massive improvement if you were given the option to set the label for an item when you link a Wikipedia article to it and it does not have a label in the language of the wikipedia. Something like an input box pre-filled with the article title and a checkbox that asks "Would you also like to set the label for the corresponding Wikidata item?" would be great. With the current system, we end up with very many Wikidata items needlessly lacking labels in many languages. --Njardarlogar (talk) 09:44, 17 October 2016 (UTC)

I've actually made similar suggestions twice before (1 2). Maybe I should create a task at Phabricator. --Njardarlogar (talk) 10:04, 20 October 2016 (UTC)
Hello @Njardarlogar:, thanks for you suggestion. If you can create a Phabricator task, please do it, otherwise I can create it for you. We will consider it soon. Lea Lacroix (WMDE) (talk) 15:44, 20 October 2016 (UTC)
Task created. --Njardarlogar (talk) 16:30, 20 October 2016 (UTC)

Outdated SPARQL results

For almost all items in this query I updated lv description some time ago via quick statements, but they are not updated in SPARQL yet.

SELECT ?item ?itemDescription WHERE {
  ?item wdt:P17 wd:Q211 .
  ?item wdt:P31 wd:Q532 .
  optional {
    ?item schema:description ?itemDescription .
  	FILTER(lang(?itemDescription)="lv") .
    FILTER( REGEX(STR(?itemDescription), '^ciems .+ novad(a .+ pagast)?ā, Latvijā$') = false )
  }
}
Try it!

--Edgars2007 (talk) 14:59, 13 October 2016 (UTC)

The query results are cached for a while. Can you check now? Is there still a problem? --Lydia Pintscher (WMDE) (talk) 16:36, 17 October 2016 (UTC)
Yes, there is. --Edgars2007 (talk) 13:25, 19 October 2016 (UTC)

  Resolved. Let's say - wrong query. --Edgars2007 (talk) 04:33, 23 October 2016 (UTC)

Autocategorisation

We are getting property proposal requests for "category for ..." properties because people want to categorise pages automatically. For example, Wikidata:Property proposal/Archive/25#category_for_people_born_here, Wikidata:Property proposal/Archive/44#category_for_recipients_of_this_award and currently Wikidata:Property proposal/Category for people deaths by this disease.

Adding properties like those is not a long term solution because there's a unlimited number of possible intersections. We have category combines topics (P971) which is a much better option but that requires finding an item which links to the one you currently have. It's a straightforward SPARQL query but I don't know if/how people can actually access that data.

Is there a way to do it right now? If not, is it going to be possible any time soon?

- Nikki (talk) 16:57, 15 October 2016 (UTC)

What are people actually trying to do with the data? --Lydia Pintscher (WMDE) (talk) 16:38, 17 October 2016 (UTC)
@Lydia Pintscher (WMDE): I think it's to populate categories like it:Categoria:Nati a Roma. For places of birth there is already a dedicate property: category for people born here (P1464). For cause of death, there isn't.
--- Jura 10:34, 20 October 2016 (UTC)
For an example of how these properties are being used, search for P1464 on ru:Модуль:Wikidata/Places. Lots of categories used on pages could be automatically determined, like if the item for a page has place of birth (P19) Rome (Q220) the page should go into it:Categoria:Nati a Roma, if it has country of citizenship (P27) United States of America (Q30), it should go into de:Kategorie:US-Amerikaner. To do that, there needs to be a way to look up the appropriate category. - Nikki (talk) 16:42, 22 October 2016 (UTC)

It seems that Wikidata:Contact_the_development_team/Archive/2016/07#One_site_link_per_item_limitation was archived before it received a response. I (and the other people involved?) would still like to know if any of the suggestions we made would be possible options. (@Lydia Pintscher (WMDE): Pinging you since you were going to look into it) - Nikki (talk) 14:17, 8 October 2016 (UTC)

I am also interested. For wikis using multiple scripts permanent duplicated item (P2959) cannot be long term solution. Removing this limitation for some wikis seems to be only viable solution.--Jklamo (talk) 21:32, 11 October 2016 (UTC)
I do not remember if I proposed a disk partitioning (Q624167) of a wiki in that discussion, but I have done it in other places. One wiki could then have one sitelink-code for each partition in the wiki. I think it would work for wikis like Armenian Wikipedia, the Wikipedias who are merged with Wikisource and the Incubators. -- Innocent bystander (talk) 20:25, 12 October 2016 (UTC)
Sorry it is taking me forever to get back on this topic :( So I think the suggestion to have several "sites" per wiki and split them by namespace is at least interesting. (I don't yet know if it'll be possible with the current changes we are making to how sites are configured.) Do we have an idea if this would solve the issue for most cases? For Commons at least it would still create the conflict of having a link to the topic and the category of the topic in the same item. They are semantically different concepts though and you can make different statements about them. Hmmmmm. It would help with multilingual wikis that split by namespace but cover the same topic. --Lydia Pintscher (WMDE) (talk) 13:04, 19 October 2016 (UTC)
@Lydia Pintscher (WMDE): There are essentially three different usecases:
1. Commons (let's ignore that for once)
2. hywiki
3. A series of other wikis (see Property talk:P2959#Charts)
Solutions that work for one might not work for others. I don't think any of #2 and #3 differentiate by namespace. A solution for #2 could be to split the wiki into 2 (if this is fine with the relevant community).
--- Jura 10:30, 20 October 2016 (UTC)
I don't think hywiki is special. Any of those wikis could theoretically be split into separate wikis but none of them (including hywiki) are eligible according to the language policy. - Nikki (talk) 11:03, 22 October 2016 (UTC)
I've tried to outline my understanding of the different issues I'm aware of and what different wikis are doing on User:Nikki/Permanent duplicates. The most widespread issue is multiple languages/dialects/scripts in a single wiki and those are not split by namespace. :( What do you think about the idea to have separate "sites" per wiki but split by language tag? - Nikki (talk) 11:03, 22 October 2016 (UTC)
Thanks for writing that up. I'm not sure if it possible for us to distinguish by language tag. I'll try to find out after I am back from vacation on the 3rd. --Lydia Pintscher (WMDE) (talk) 14:06, 25 October 2016 (UTC)

Map markers hard to see

I find the default map markers (red dots) on query results like this rather indistinct and too small after zooming in. This applies particularly when the map is projected onto a screen during a demonstration. Is it possible to configure them differently, locally, or to change the default? Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 15:00, 16 October 2016 (UTC)

@Lea Lacroix (WMDE): Please check with Jonas if he already has this on his radar and if not file a ticket. --Lydia Pintscher (WMDE) (talk) 16:39, 17 October 2016 (UTC)
This is already in Phabricator as T148022. Cheers, Hoo man (talk) 12:50, 24 October 2016 (UTC)
I'm not sure that's the same issue. Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 14:17, 25 October 2016 (UTC)

Incompete result sets that may still be useful

Say a maintenance query has a too big result set to be entirely computed in time with the query service. We have to wait for the timeout to know this then we have to try something like setting a limit to view some results. Would it be possible to see the result set blazegraph has found at the time of the timeout ? author  TomT0m / talk page 19:38, 25 October 2016 (UTC)

@TomT0m: It is already returning the partial result ( grey box ) --Jonas Kress (WMDE) (talk) 14:57, 26 October 2016 (UTC)

@Jonas Kress (WMDE): It may be that it worked in the past, but since quite a lot of time now it always shows an exception in that grey box (Something like a "Concurrent exception" with a java legendary stack trace that does not is shown entirely and fill the box). author  TomT0m / talk page 16:13, 26 October 2016 (UTC)
@TomT0m: I see it works for this query https://query.wikidata.org/#%23Cats%0ASELECT%20%3Fitem%20%3FitemLabel%0AWHERE%0A%7B%0A%09%3Fitem%20wdt%3AP31%20wd%3AQ5%20.%0A%09SERVICE%20wikibase%3Alabel%20%7B%20bd%3AserviceParam%20wikibase%3Alanguage%20%22en%22%20%7D%0A%7D --Jonas Kress (WMDE) (talk) 17:08, 26 October 2016 (UTC)
Mmm right, that works for me too. Would that mean every query I write that timeout is so complex it does not find any result before the timeout ? I understand for query that must sort for example ... But still a little weird. author  TomT0m / talk page 19:18, 26 October 2016 (UTC)
One example of this kind of queries : this one (it's easy to play with the limits to make it timeout) author  TomT0m / talk page 19:20, 26 October 2016 (UTC)
@TomT0m: This query works for me :). --Jonas Kress (WMDE) (talk) 13:39, 27 October 2016 (UTC)

@TomT0m: Queries that use GROUP BY or ORDER BY can't be displayed incomplete, because the full set of selected triples needs to be known in order to perform these operations. This might also apply to other operations, but for those two it's obvious: These operations are applied last while executing a query and they need to process the whole set of previously selected triples (because something to group or to order by could also be at the "end" of the previously selected set of triples). While in some specific cases it could theoretically be ok to output the incomplete results anyway, Blazegraph probably doesn't do that (for good). Cheers, Hoo man (talk) 14:09, 27 October 2016 (UTC)

Changes in GUI

The Swedish GUI suddenly tells "add" instead of whatever it was written at the bottom at every claim-box. Probably a MediaWiki-page that hasn't been edited on Translatewiki, but which? (@Ainali: har du konto där?) -- Innocent bystander (talk) 08:53, 27 October 2016 (UTC)

It is translatewiki:MediaWiki:Wikibase-statementlistview-add. I translated it yesterday, but have no clue on when it get picked up and deployed. Ainali (talk) 09:08, 27 October 2016 (UTC)
Can confirm. Just translated the new strings too, wish this was communicated earlier. Sjoerd de Bruin (talk) 09:15, 27 October 2016 (UTC)
Thank you for looking into this… the new translations will be picked up by Wikidata with the localization update tonight. Cheers, Hoo man (talk) 09:22, 27 October 2016 (UTC)