Skip to content

Commit

Permalink
Merge pull request #10 from martinohanlon/dev
Browse files Browse the repository at this point in the history
v0.2.0
  • Loading branch information
Martin O'Hanlon authored Mar 10, 2021
2 parents 61d8413 + ca1b205 commit 685cbe1
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 5 deletions.
7 changes: 5 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,9 @@ The drawings have been moderated but there is no guarantee it'll actually be a p
Status
------

**Beta** - stable, under active dev, the API may change.
**Stable**.

Raise any `issues`_ in the `github repository`_.

.. |quickdraw| image:: https://raw.githubusercontent.com/martinohanlon/quickdraw_python/master/docs/images/quickdraw.png
:scale: 100 %
Expand Down Expand Up @@ -166,4 +167,6 @@ Status
.. _QuickDrawData: https://quickdraw.readthedocs.io/en/latest/api.html#quickdrawdata
.. _QuickDrawDataGroup: https://quickdraw.readthedocs.io/en/latest/api.html#quickdrawdatagroup
.. _drawing_names: https://quickdraw.readthedocs.io/en/latest/api.html#quickdraw.QuickDrawDataGroup.drawing_names
.. _drawings: https://quickdraw.readthedocs.io/en/latest/api.html#quickdraw.QuickDrawDataGroup.drawings
.. _drawings: https://quickdraw.readthedocs.io/en/latest/api.html#quickdraw.QuickDrawDataGroup.drawings
.. _issues: https://github.com/martinohanlon/quickdraw_python/issues
.. _github repository: https://github.com/martinohanlon/quickdraw_python
5 changes: 5 additions & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ Change log

.. currentmodule:: quickdraw

0.2.0 - 2012-03-10
------------------

+ Python 3.7+ compatibility fix

0.1.0
-----

Expand Down
3 changes: 3 additions & 0 deletions examples/search_drawing.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from quickdraw import QuickDrawDataGroup
anvils = QuickDrawDataGroup("anvil")
results = anvils.search_drawings(countrycode="PL")
7 changes: 5 additions & 2 deletions quickdraw/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -363,10 +363,13 @@ def drawings(self):
if self._current_drawing > self._drawing_count - 1:
# reached the end to the drawings
self._current_drawing = 0
raise StopIteration()
return
else:
# yield the next drawing
yield self.get_drawing(index = self._current_drawing)
try:
yield self.get_drawing(index = self._current_drawing)
except StopIteration:
return

def get_drawing(self, index=None):
"""
Expand Down
5 changes: 4 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

__project__ = 'quickdraw'
__desc__ = 'An API for downloading and reading the google quickdraw data.'
__version__ = '0.1.0'
__version__ = '0.2.0'
__author__ = "Martin O'Hanlon"
__author_email__ = '[email protected]'
__license__ = 'MIT'
Expand Down Expand Up @@ -76,6 +76,9 @@
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
]

if __name__ == '__main__':
Expand Down

0 comments on commit 685cbe1

Please sign in to comment.