henriquebastos / gnucash-to-beancount

Gnucash to Beancount Converter.
GNU General Public License v2.0
30 stars 19 forks source link

ValueError: Unsupported table versions #14

Open almereyda opened 4 years ago

almereyda commented 4 years ago

When trying to open a certain GnuCash SQLite database that has been edited with a recent version, this script, also in the version from https://github.com/AndrewStein/gnucash-to-beancount, throws:

Traceback (most recent call last):
  File "/home/yala/.local/bin/gnucash-to-beancount", line 11, in <module>
    load_entry_point('gnucash-to-beancount==1.0b0', 'console_scripts', 'gnucash-to-beancount')()
  File "/home/yala/.local/lib/python3.7/site-packages/gnucash_to_beancount/cli.py", line 38, in main
    with piecash.open_book(options.filename, open_if_lock=True) as book:
  File "/home/yala/.local/lib/python3.7/site-packages/piecash/core/session.py", line 350, in open_book
    raise ValueError("Unsupported table versions")

This is known and reported upstream as https://github.com/sdementen/piecash/issues/126

almereyda commented 4 years ago

The patch in the suggested resolution of the issue filed as PR https://github.com/sdementen/piecash/pull/130#issuecomment-596837295 has been tested and is confirmed to work with this, respectively the version from AndrewStein.