Skip to content

Commit

Permalink
[fix] Add a memento_client fix to the framework
Browse files Browse the repository at this point in the history
- add memento module and import MementoClient and MementoClientException.
  Derive MementoClient and add timout parameters for several methods. The
  implementation was originally made with this commit:
  mementoweb/py-memento-client@15dc9f5

- move weblinkchecker._get_closest_memento_url() to memento.py
  as get_closest_memento_url() but keep the blame history
- use pywikibot logging system
- set memento_client requirement to ==0.6.1
- update weblinkchecker.py script
- update tests and rename weblinkchecker_tests to memento_tests
- update doc
- update license

Bug: T185561
Change-Id: I137a27ad198f0e0aae713c888401265f7aca187b
  • Loading branch information
xqt committed Jun 19, 2022
1 parent 804317e commit 9561f9d
Show file tree
Hide file tree
Showing 10 changed files with 331 additions and 776 deletions.
5 changes: 5 additions & 0 deletions docs/api_ref/pywikibot.data.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ pywikibot.data.api module

.. automodule:: pywikibot.data.api

pywikibot.data.memento module
-----------------------------

.. automodule:: pywikibot.data.memento

pywikibot.data.mysql module
---------------------------

Expand Down
7 changes: 5 additions & 2 deletions docs/licenses.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@ Licenses
:ref:`MIT license`; translations by translators and manual pages on
mediawiki.org are available under the `CC-BY-SA 3.0`_ license. The
Pywikibot logo is Public domain but it includes material that may be
protected as a trademark.
protected as a trademark. Parts of :mod:`memento<pywikibot.data.memento>`
module is licenced under the `BSD`_ open source software license. You
may obtain a copy of the License at
http://mementoweb.github.io/SiteStory/license.html.


MIT License
Expand All @@ -18,4 +21,4 @@ MIT License


.. _CC-BY-SA 3.0: https://creativecommons.org/licenses/by-sa/3.0/

.. _BSD: https://github.com/mementoweb/py-memento-client/blob/master/LICENSE.txt
2 changes: 2 additions & 0 deletions pywikibot/CONTENT.rst
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ The contents of the package
| +----------------+-------------------------------------+
| | _requests.py | API Requests interface |
+----------------------------+----------------+-------------------------------------+
| memento.py | memento_client 0.6.1 package fix |
+----------------------------+------------------------------------------------------+
| mysql.py | Miscellaneous helper functions for mysql queries |
+----------------------------+------------------------------------------------------+
| sparql.py | Objects representing SPARQL query API |
Expand Down
Loading

0 comments on commit 9561f9d

Please sign in to comment.