Page MenuHomePhabricator

MediaSearch - issues for Other License filter for Images
Closed, ResolvedPublic


As a follow up to T257938.

(1) Other in Images tab fetches files with Creative Commons Attribution-Share Alike 3.0

Also wondering if we've missed some...I'm testing my patch locally and an image with the license Creative Commons Attribution-Share Alike 3.0 it is popping up under "other" instead of share with attributtion/cc-by-sa.

Checking commons wmf.26 I observed exactly what @AnneT pointed out in the above comment - Other option returns images with Creative Commons Attribution-Share Alike 3.0, e.g. will display in the result set the following image:

Screen Shot 2021-01-13 at 4.58.11 PM.png (1×699 px, 834 KB)

Question - is it correct to treat the licenses like CC BY-SA 3.0 RS as Other and only CC BY-SA 4.0 as Use with attribution and same license?

The issues below are minor issues regarding displaying copyright info in QuickView.

(2) No attribution is shown for files that do have licensing information.
The following file has Licensing attribution but it's not shown in QuickView.

Screen Shot 2021-01-13 at 5.18.41 PM.png (879×678 px, 785 KB)
Screen Shot 2021-01-13 at 5.19.02 PM.png (1×1 px, 1 MB)

(3) Some files have license that seems to be 'No restrictions' instead of 'Other'?
e.g. but the image will be returned with the Other option.

(4) The licensing information is shown without the copyright icon/label which might make it difficult for users to see that the licensing info is present:

Screen Shot 2021-01-13 at 3.17.24 PM.png (660×552 px, 323 KB)

Event Timeline

This is an issue for the community to fix. @matthiasmullie to write a summary of what needs to be fixed and how, and @Keegan will post to the talk page.

These 2 were missing from the license map config:

	P275=Q98755364, # copyright licence = Commons Attribution-ShareAlike 3.0 Italy
	P275=Q98755344, # copyright licence = Commons Attribution-Share Alike 3.0 Serbia

I have added them, and the files in question now no longer appear in search results they don't belong.

We've intentionally made this license map something that the community can change, but IIRC we haven't really informed them about it. I will post more details about that in a separate comment.

This seems to be because there is less license information available from the API.
I've split this off into T273165 and added some more detail in there.

This file has a copyright license = attribution only license statement, so it think it's definitely not "no restrictions".
There may be another issue with where this specific license fits, however. I've split that off into T273166.

We currently only show icons for some (CC & PD) licenses.
It's be nice if we can show a generic fallback icon for the rest of the licenses. I've spit that off into T273167.

The map of these license statements can be found at

It is the map of license names to structured data statements, for use with the haslicense keyword feature (or the Special:MediaSearch UI filter which uses the search keyword filter)
Changes to this take effect immediately.
The syntax is as follows:

  • Everything from a "#" character to the end of the line is a comment.
  • Every non-blank line is the license name, followed by a "|" character followed by a comma-separated list of <property>=<item> statements.

Examples of good lines:


Adding additional whitespace for improved legibility (e.g. newlines) is allowed around the | and , characters.


@Keegan: above is some documentation for how the community can update the license mapping, should the need to make changes. Can you make sure this finds its way to the relevant people?
Once that is done, you can close this ticket - the other things have been split off into separate tickets.

Keegan posted the information here.