Skip to content

Releases: lokal-profil/wikidata-stuff

0.5

17 Feb 23:28
13f9941
Compare
Choose a tag to compare

This introduces no new functionality but drops all previously deprecated packages, modules, classes, functions and arguments.

If upgrading from a pre-0.4 release you are strongly recommended too **first upgrade to 0.4 ** and then clear out any deprecation warnings.

Note that the package name is now wikidatastuff.

0.4

17 Feb 22:37
030e3c3
Compare
Choose a tag to compare
0.4

This introduces multiple breaking changes but has been designed to raise deprecation warnings for all of these making it easier to adapt code built on pre-0.4 releases.

To display the deprecation warnings run your script using the pywikibot -debug flag (you must be making use of pywikibot.handleArgs()) or add the -Wd option to your python call.

The major changes are:

  • Re-factor of the WikidataStuff class to make Statement, Qualifier and Reference stand-alone classes. These were internal classes before. References to the old names no longer work but the deprecation messages point to the new schema.
  • Re-naming of all modules, classes, functions and function arguments to conform with PEP8. Usage of the old names works but raises a deprecation warning pointing to the new naming convention.
  • Re-naming of the package, to conform with PEP8, from wikidataStuff to wikidatastuff. The old name still works but raises a deprecation warning.
  • Some functions moved from wikidata_stuff to helpers.

Minor/internal changes:

  • Standardised string formatting
  • Standardised line breaking

0.3.9

28 Sep 13:30
9e68dd0
Compare
Choose a tag to compare

Uses the Reference embedded in Statement, if any, unless a ref
is explicitly provided to addNewClaim.

Switches the mysql library from mysqlclient toPyMySQL.

0.3.8

30 Sep 22:46
Compare
Choose a tag to compare

Introduces the no_wdss parameter for disabling WikidataStringSearch

0.3.7

07 Sep 10:21
Compare
Choose a tag to compare

Introduces PreviewItem a module for generating a wikitext table preview of a single updated/created Wikidata item candidate.

Also:

  • Raw output can now be gotten from select queries by adding raw to make_select_wdqs_query()
  • Local hashing of wbRepesentation has been dropped as this is now supported natively by pywikibot. You might have to update your version of pywikibot.
  • Added a helper function convert_language_dict_to_json() for converting language-string dictionaries to the required (json) format needed by Wikidata.
  • Allow the standard summary to be used also for the creation of new items.
  • Extended README

0.3.6

27 Jun 13:26
Compare
Choose a tag to compare

Add a reference property to Statement

Adds the add_reference() function to Statement allowing a Reference to be associated with the statement.

This also changes the hash and the __repr__ of Statement.

Also makes get_unit_q more flexible by allowing powers to be either plain or raised (i.e. km2 or km²).

0.3.5

14 Jun 08:18
Compare
Choose a tag to compare

Make Statements hashable

Also add temporary hashing support for WbTypes (WbTime, WbQuantity, Coordinates etc.) until this is available through pywikibot proper.

0.3.4

12 Jun 18:35
Compare
Choose a tag to compare

Add functionality needed for comparison of Statement and Qualifier (but not References)

  • Duplicate Qualifiers are no longer allowed in a Statement.
  • The internal representation of Qualifiers in a Statement is now a set stored as _quals. quals still returns a list.
  • The Pid used for a Qualifier may now also be an int.
  • __repr__ for Claim is now available anywhere in the WikidataStuff class

0.3.3

05 Jun 16:22
Compare
Choose a tag to compare

Introduce add_multiple_label_or_alias and add_multiple_descriptions were added to provide a mechanism for adding label+alias or descriptions in multiple languages in a single edit.

Also adds the possibility of providing both a singl name or a list of names (in a given language) to add_multiple_label_or_alias/addLabelOrAlias.

0.3.2

11 May 08:31
Compare
Choose a tag to compare

Added no_strip parameter to helpers.fill_cache_wdqs() which toggles the output from integers to full Qids.