>
> Did you pass the --python option to the acprep command?
>
Yes, I did pass this option. The compile was successful but I could not see
the ledger.so file being generated anywhere (I saw the ledger.dylib file).
I abandoned this approach because there were a few things related to
boost-python that I did not understand.
> I take care of the Homebrew Ledger formula and have never seen that
> error, can you provide me the output of: % brew --prefix please
>
Thank you for the brew package! It make it incredibly easy to install. I
mean to update the ledger docs on github once I get past this issue.
What happens when you run: % brew test ledger --with-python ?
>
(ledger)[~] brew test ledger --with-python
Testing ledger
==> /usr/local/Cellar/ledger/3.1/bin/ledger --args-only --file
/usr/local/Cellar/ledger/3.1/share/ledger/examples/sample.dat --output
/private/tmp/ledger-XEAtvh/output balance --collapse equity
==> python /usr/local/Cellar/ledger/3.1/share/ledger/demo.py
Traceback (most recent call last):
File "/usr/local/Cellar/ledger/3.1/share/ledger/demo.py", line 10, in
<module>
import ledger
ImportError: No module named ledger
Error: ledger: failed
Failed executing: python /usr/local/Cellar/ledger/3.1/share/ledger/demo.py
/usr/local/Library/Homebrew/formula.rb:644:in `system'
/usr/local/Library/Formula/ledger.rb:90:in `block in <class:Ledger>'
/usr/local/Library/Homebrew/formula.rb:562:in `block in run_test'
/usr/local/Library/Homebrew/extend/fileutils.rb:21:in `mktemp'
/usr/local/Library/Homebrew/formula.rb:560:in `run_test'
/usr/local/Library/Homebrew/cmd/test.rb:59:in `block (2 levels) in test'
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/timeout.rb:66:in
`timeout'
/usr/local/Library/Homebrew/cmd/test.rb:58:in `block in test'
/usr/local/Library/Homebrew/cmd/test.rb:37:in `each'
/usr/local/Library/Homebrew/cmd/test.rb:37:in `test'
/usr/local/Library/brew.rb:136:in `<main>'
(ledger)[~]
Also please try: % ledger python
> this will put you in an interactive python session, what happens
> when you import ledger in there?
>
So this is embarrassing, but I has already tried this exact command
earlier, and ran in the same error mentioned in my original post. When I
tried it again this morning, and it works. I had upgraded to iterm2 from
iterm1 after reading about strange path issues, so this may be another
variable. This command works fine now. I am happy it is, but a little
annoyed that I am not sure what fixed the problem.
> I've learned most of my Ledger Python by reading
> $(brew --prefix ledger)/share/ledger/demo.py
> it's very worthwhile studying it!
>
Excellent - thanks for the pointer and will study it. Thanks for the reply
Alexis!
--
---
You received this message because you are subscribed to the Google Groups
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.