mostm / pyqiwi

Python QIWI API Wrapper
http://pyqiwi.readthedocs.io/
MIT License
45 stars 25 forks source link

Обязательная необходимость next_txn_date в Wallet.history #5

Closed zuenko closed 6 years ago

zuenko commented 6 years ago

Python 3.6

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-50-48db75dd2237> in <module>()
----> 1 wallet.history()

~/anaconda3/lib/python3.6/site-packages/qiwipy-2.1.0-py3.6.egg/pyqiwi/__init__.py in history(self, rows, operation, start_date, end_date, sources, next_txn_date, next_txn_id)
    162         for transaction in result_json['data']:
    163             transactions.append(types.Transaction.de_json(transaction))
--> 164         ntd = types.JsonDeserializable.decode_date(result_json.get("nextTxnDate"))
    165         return {"transactions": transactions,
    166                 "next_txn_date": ntd,

~/anaconda3/lib/python3.6/site-packages/qiwipy-2.1.0-py3.6.egg/pyqiwi/types.py in decode_date(date_string)
     64                 '%Y-%m-%dT%H:%M:%S.%f%z')
     65         else:
---> 66             raise TypeError('types.JsonDeserializable.decode_date only accepts date_string as str type')
     67 
     68     def __str__(self):

TypeError: types.JsonDeserializable.decode_date only accepts date_string as str type