Skip to content
This repository was archived by the owner on Apr 2, 2025. It is now read-only.
This repository was archived by the owner on Apr 2, 2025. It is now read-only.

Metadata API: Fix license urls #266

Description

@kulla

The bug

Currently we output the url of the license table as the license url. However we have the following urls in our MySQL:

mysql> select id, title, url from license;
+----+-----------------------------------------------------------------------------------------------------+-----------------------------------------------------------+
| id | title                                                                                               | url                                                       |
+----+-----------------------------------------------------------------------------------------------------+-----------------------------------------------------------+
|  1 | Dieses Werk steht unter der freien Lizenz CC BY-SA 4.0.                                             | https://creativecommons.org/licenses/by-sa/4.0/deed.de    |
|  2 | Das ISB Bayern h�lt an Teilen dieses Werkes die Rechte.                                             | https://www.isb.bayern.de/                                |
|  3 | Das Z-MNU h�lt an Teilen dieses Werkes die Rechte.                                                  | http://btmdx1.mat.uni-bayreuth.de/smart/wp/               |
|  4 | Dieses Werk steht unter der freien Lizenz CC BY-SA 4.0 mit Namensnennung von Herrn Rudolf Brinkmann | https://123mathe.de                                       |
|  5 | Lizenzhinweis f�r das BOS Intranet                                                                  | http://www.bos-sozial.musin.de/                           |
|  6 | Dieses Werk steht unter der freien Lizenz CC BY-SA 4.0 mit Namensnennung von Herrn Franz Strobl.    | http://www.strobl-f.de/                                   |
|  7 | Dieses Werk steht unter der freien Lizenz CC BY-SA 4.0 mit Namensnennung von Herrn G�nther Rasch    | http://www.raschweb.de/                                   |
|  8 | Herr Thomas Unkelbach h�lt an Teilen dieses Werkes die Rechte.                                      | http://ne.lo-net2.de/selbstlernmaterial/                  |
|  9 | This content is licensed under cc-by-sa-4.0                                                         | http://creativecommons.org/licenses/by/4.0/               |
| 10 | Standard-YouTube-Lizenz                                                                             | https://www.youtube.com/static?gl=DE&template=terms       |
| 11 | Dieses Werk steht unter der freien Lizenz CC BY-NC-SA 3.0.                                          | https://creativecommons.org/licenses/by-nc-sa/3.0/deed.de |
| 12 | F�r dieses Werk gelten die Nutzungsbedingungen des Pr�fungsarchivs von www.mebis.bayern.de.         | https://mediathek.mebis.bayern.de/archiv.php              |
| 13 | This content is licensed under cc-by-sa-4.0                                                         | https://creativecommons.org/licenses/by/4.0/              |
| 14 | Este contenido est� licenciado bajo cc-by-sa-4.0                                                    | https://creativecommons.org/licenses/by-sa/4.0/deed.es    |
| 15 | F�r dieses Video gelten die Nutzungsbedingungen der BR Mediathek.                                   | https://www.br.de/mediathek/nutzungsbedingungen           |
| 16 | Dieses Werk steht unter der Lizenz CC BY-ND 4.0                                                     | https://creativecommons.org/licenses/by-nd/4.0/           |
| 17 | This content is licensed under cc-by-sa-4.0                                                         | http://creativecommons.org/licenses/by/4.0/               |
| 18 |  Ce contenu est sous licence cc-by-sa-4.0                                                           | http://creativecommons.org/licenses/by/4.0/               |
| 19 | CC BY 4.0 - Landesbildungsserver Baden-W�rttemberg                                                  | https://www.schule-bw.de/                                 |
| 21 | Licencia est�ndar de YouTube                                                                        | https://www.youtube.com/static?template=terms&gl=ES       |
| 22 | Esta obra est� bajo la licencia libre CC BY-SA 4.0 de la iniciativa colectiva �frica en la Escuela  | https://www.facebook.com/AfricaenlaEscuela/               |
| 23 |  Este ejercicio/tarea est� bajo la licencia libre CC BY-SA 4.0 del se�or Franz Strobl.              | http://www.strobl-f.de/                                   |
| 24 | Dieses Werk steht unter der freien Lizenz CC BY-SA 4.0 mit Namensnennung von MNWeG                  | https://mnweg.org                                         |
| 25 |                                                                                                     |                                                           |
+----+-----------------------------------------------------------------------------------------------------+-----------------------------------------------------------+

When you now look at the license with id 7 it is a CC-BY-SA license. However the license url is http://www.raschweb.de/ and not https://creativecommons.org/licenses/by-sa/4.0/deed.de. The url http://www.raschweb.de/ needs to be added to the contributors.

Expected result

All items in the Metadata API with a CC license (you can spot them in the title) need to return as url in the form https://creativecommons.org/licenses/.... When there is currently a different URL, than it need to be added to the contributors.

Possible solutions

  • Add extra code in the database layer for the special licenses OR
  • Add a column contribution_url which can be null. For example for license with ID 7 you can set url=https://creativecommons.org/licenses/by-sa/4.0/deed.de and contribution_url=http://www.raschweb.de/. Add a new contributor in the metadata API when contribution_url is set (maybe have a better name for contribution_url as well).

Follow Ups

  • Inform edusharing ( inhalte at-zeichen edu-sharing.net ) after bug is fixed

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions