Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get account balances raises assertion #12

Open
basslet opened this issue Nov 30, 2024 · 1 comment
Open

Get account balances raises assertion #12

basslet opened this issue Nov 30, 2024 · 1 comment

Comments

@basslet
Copy link

basslet commented Nov 30, 2024

Installation was successful. Auth works. Downloading all documents works.

I'm trying to get transactions so that I can save them to csv, because the Comdirect csv export on their website is a real PITA.

When I run get_account_balances_and_transactions.py, I get this assertion that I can't quite figure out.

(base) MacBookPro:bin dbu$ python get_account_balances_and_transactions.py
Please press ENTER after confirming push-tan
Balance of Direct Access Savings-Plus Account (DE962004xxxxxxxxxxxxxx): xxxxx.26 EUR
Recent transactions:
TRANSFER
TRANSFER
TRANSFER
TRANSFER
BANK_FEES
Traceback (most recent call last):
File "/Users/dbu/Repositories/python-comdirect-api/bin/get_account_balances_and_transactions.py", line 32, in
transactions = s.account_get_transactions(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dbu/miniconda3/lib/python3.11/site-packages/comdirect_api/session.py", line 254, in account_get_transactions
return [comdirect_api.types.AccountTransaction(i) for i in response.json()["values"]]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dbu/miniconda3/lib/python3.11/site-packages/comdirect_api/session.py", line 254, in
return [comdirect_api.types.AccountTransaction(i) for i in response.json()["values"]]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dbu/miniconda3/lib/python3.11/site-packages/comdirect_api/types.py", line 160, in init
assert(self.transactionType in TransactionType)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

@keisentraut
Copy link
Owner

Probably comdirect changed something in the JSON reply. I am not really using my own code anymore, so I probably won't fix it. But feel free to support a pull request, I will merge it then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants