Skip to content

Commit

Permalink
fixed str representation of lexeme form and sense (#21)
Browse files Browse the repository at this point in the history
* fixed str representation of lexeme form and sense

* updated changelog
  • Loading branch information
galtay authored Apr 5, 2019
1 parent a696da4 commit faeb8cc
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@
qwikidata Change Log
====================

v0.2.1
======

**Fixed**:

* typo in string representation of WikidataForm and WikidataSense.

v0.2.0
======

Expand Down
2 changes: 1 addition & 1 deletion qwikidata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
"""Metadata for this package."""

__package_name__ = "qwikidata"
__version__ = "0.2.0"
__version__ = "0.2.1"
4 changes: 2 additions & 2 deletions qwikidata/entity.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ def get_representation(self, lang: typedefs.LanguageCode = typedefs.LanguageCode
return ""

def __str__(self) -> str:
return f"WikidataForm(form_id={self.form_id}, representation={self.get_representation()}, grammatical_features={self.grammatical_features}"
return f"WikidataForm(form_id={self.form_id}, representation={self.get_representation()}, grammatical_features={self.grammatical_features})"

def __repr__(self) -> str:
return self.__str__()
Expand Down Expand Up @@ -481,7 +481,7 @@ def get_gloss(self, lang: typedefs.LanguageCode = typedefs.LanguageCode("en")) -
return ""

def __str__(self) -> str:
return f"WikidataSense(sense_id={self.sense_id}, gloss={self.get_gloss()}"
return f"WikidataSense(sense_id={self.sense_id}, gloss={self.get_gloss()})"

def __repr__(self) -> str:
return self.__str__()
Expand Down

0 comments on commit faeb8cc

Please sign in to comment.