madhat2r / plaid2text

Python Scripts to export Plaid transactions and transform them into Ledger or Beancount syntax formatted files.
GNU General Public License v3.0
88 stars 19 forks source link

Build not reproducible, breaking on prompt_toolkit #20

Open bradyt opened 5 years ago

bradyt commented 5 years ago

I think you're allowing pip3 to grab incompatible versions of libraries?

> plaid2text
Traceback (most recent call last):
  File "/usr/local/bin/plaid2text", line 2, in <module>
    from plaid2text.plaid2text import main;main()
  File "/usr/local/lib/python3.7/site-packages/plaid2text/plaid2text.py", line 19, in <module>
    from plaid2text.renderers import LedgerRenderer, BeancountRenderer
  File "/usr/local/lib/python3.7/site-packages/plaid2text/renderers.py", line 10, in <module>
    import plaid2text.config_manager as cm
  File "/usr/local/lib/python3.7/site-packages/plaid2text/config_manager.py", line 8, in <module>
    from plaid2text.interact import prompt, NullValidator, YesNoValidator
  File "/usr/local/lib/python3.7/site-packages/plaid2text/interact.py", line 5, in <module>
    from prompt_toolkit.contrib.completers.filesystem import PathCompleter
ModuleNotFoundError: No module named 'prompt_toolkit.contrib.completers.filesystem'

Maybe the following is relevant?

> pip3 show prompt_toolkit
Name: prompt-toolkit
Version: 2.0.9
Summary: Library for building powerful interactive command lines in Python
Home-page: https://github.com/jonathanslenders/python-prompt-toolkit
Author: Jonathan Slenders
Author-email: UNKNOWN
License: BSD-3-Clause
Location: /usr/local/lib/python3.7/site-packages
Requires: wcwidth, six
Required-by: plaid2text, ipython

Maybe I need to have version 2.1.0 here.

bradyt commented 5 years ago

Maybe add freeze dependencies to requirements.txt and commit?

bradyt commented 5 years ago

Ah, breaks on prompt_toolkit starting at 2.0.0.

An IRCer suggested,

18:02 try: import new.module; except ...: import old.module ## FIXME: remove when EVERYONE has upgraded to module ≥1.2.3
18:04 I usually include a sunset clause as well
18:04 # remove after 2020-06-01 or after xxx
vrohlfs commented 4 years ago

@bradyt were you able to figured out how to solve this error? I keep having the same issue when i run plaid2text without any arguments (I've tried with both prompt-toolkit versions 3.0.2 - latest - and 2.0.10)

bradyt commented 4 years ago

I've no recollection, and have not considered Plaid recently, sorry.

vrohlfs commented 4 years ago

@bradyt Got it. Any particular reason why folks are not using beancount and plaid lately? Most of the discussions online date back 2-3 years.

Also, found this in one of your forks that solved the issue: '- from prompt_toolkit.contrib.completers.filesystem import PathCompleter' '- from prompt_toolkit.contrib.completers.base import Completer, Completion' '+ from prompt_toolkit.completion.filesystem import PathCompleter' '+ from prompt_toolkit.completion.base import Completer, Completion'

Thanks for such a quick response.

vrohlfs commented 4 years ago

@bradyt any input would be appreciated. Just wanted to confirm this would be a good path towards managing my own finances.

bradyt commented 4 years ago

I'm not sure I understand the question. And one might say it's getting off topic from the issue title. Perhaps a better venue for your additional questions, would be IRC? There are some links at https://plaintextaccounting.org/#newsdiscussion.