Re: beancount OFX; investment inventory

2017-01-08 Thread Christopher Singley


On Saturday, 7 January 2017 14:33:43 UTC-6, Martin Blais wrote
>
>
> On a somewhat related note: I wonder if a new type of directive could be 
> useful, similar to Balance assertions, that would assert that the total of 
> one account matches that of another. I haven't need it myself just yet, but 
> it's a simple and appealing idea.
>

I doubt you'd find that useful.  Such assertions are generally needed not 
between various accounts on the general ledger, but between G/L accounts 
and other records whose utility you've not yet perceived.
 

>
> One thing to be aware of is that the goal of this project is not to 
> replicate nor implement traditional methods of accounting.
> Rather, the purpose is to come up with the simplest possible 
> representation that allows one to enter and effectively query data from 
> text files in the context of personal finance.
> Given this, I feel quite free to deviate from well-established norms, 
> especially when their existence derives from historical limitations.
> For example, Beancount adopts Ledger's idea of doing away with credits and 
> debits (preferring signed amounts) and there's no "reconciliation" process, 
> instead you declare balance assertions explicitly.
> Furthermore, I think there may be simpler ways to solve some accounting 
> problems by taking a CS outlook on them.
>

The issue is not that traditional methods of accounting are crusty and 
benighted... mapping debits & credits to +/- is just normal industry 
practice; it's been pretty much universal since the release of Visicalc.

The real issue is defining the scope of the problem.  Accountancy treats of 
operations and entities as different from one another as a hummingbird and 
a jellyfish.  In order to do our own work, we make simplifying 
assumptions.  It's important to be clear about what assumptions we're 
making, the trade-offs involved, where they break down, and how to handle 
it when they do break down.

The biggest assumptions made by beancount seem to involve its input format 
- e.g. a single monolothic file with a unified simple format suffices for 
all accounting needs of personal finance, and manual data entry is entirely 
sufficient for personal finance.  I am entirely sympathetic to these design 
goals, but it sounds like you're already starting to bump into problems 
(the wash sale rules) the root cause of which is insufficient separation of 
concerns.  I hate to tell you that there's a lot more where that came 
from... yes, squarely in the realm of personal finance (unless by "personal 
finance" you mean "trivial cases").

It's an entirely respectable position to limit the scope of the problem to 
just the general ledger - to say "beancount doesn't do inventory".  Your 
system looks fine for that use (although I need to test it) - I'm pretty 
sure I could write what I need externally, and dump computed JEs as text 
files to hand off to beancount.

But you're heading into treacherous waters with inventory.  Shoehorning 
currency exchanges and securities trades into the same inputs as general 
ledger entries is a kludge, and if you analyze the workings of systems that 
actually handle these cases well, you'll see that you will run into 
predictable problems.  If you care about these things and want to do them, 
it's worth formulating a plan for dealing with the obvious issues that 
arise, and incorporating that understanding into the system architecture.

I'm probably not the guy you really want to talk to - my knowledge of 
accounting is as meager as my understanding of computer science.  I can 
only claim to have a reasonable experience of real-world personal finance 
data that play havoc with all kinds of simplifying assumptions that would 
be nice to rely on in an elegant accounting system.  Hence my appeal to 
generality.

A tax attorney of my acquaintance says you can separate people into two 
categories by placing a large bucket of silver dollars on the floor in 
front of them.  One group won't deign to stoop, foregoing the windfall in 
order to retain an upright and dignified posture.  The other group will 
dive into the bucket and start grubbing for money, with their asshole 
winking at the world.

It's important to understand that, at its core, accounting is all about 
sphincter winkery.  If your wash sale problems had amounted to real money, 
I imagine you'd be a lot clearer on that, and have a better understanding 
of what reconciliation is really all about.  As it is, I suppose you have 
this enlightenment to look forward to.

Carry on as you were!

Chris

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/0c1ea6a7-7eb9-4ae1-a092-8eff69b3dbf6%40googlegr

Re: beancount OFX; investment inventory

2017-01-08 Thread Martin Blais
On Sun, Jan 8, 2017 at 11:09 AM, Christopher Singley 
wrote:

>
>
> On Saturday, 7 January 2017 14:33:43 UTC-6, Martin Blais wrote
>>
>>
>> On a somewhat related note: I wonder if a new type of directive could be
>> useful, similar to Balance assertions, that would assert that the total of
>> one account matches that of another. I haven't need it myself just yet, but
>> it's a simple and appealing idea.
>>
>
> I doubt you'd find that useful.  Such assertions are generally needed not
> between various accounts on the general ledger, but between G/L accounts
> and other records whose utility you've not yet perceived.
>

I don't see a problem defining an assertion that works across files. In
fact, I could probably make use of that today when I create separate
ledgers for trips or projects. I think it's a cool idea.


One thing to be aware of is that the goal of this project is not to
>> replicate nor implement traditional methods of accounting.
>> Rather, the purpose is to come up with the simplest possible
>> representation that allows one to enter and effectively query data from
>> text files in the context of personal finance.
>> Given this, I feel quite free to deviate from well-established norms,
>> especially when their existence derives from historical limitations.
>> For example, Beancount adopts Ledger's idea of doing away with credits
>> and debits (preferring signed amounts) and there's no "reconciliation"
>> process, instead you declare balance assertions explicitly.
>> Furthermore, I think there may be simpler ways to solve some accounting
>> problems by taking a CS outlook on them.
>>
>
> The issue is not that traditional methods of accounting are crusty and
> benighted... mapping debits & credits to +/- is just normal industry
> practice; it's been pretty much universal since the release of Visicalc.
>
> The real issue is defining the scope of the problem.  Accountancy treats
> of operations and entities as different from one another as a hummingbird
> and a jellyfish.  In order to do our own work, we make simplifying
> assumptions.  It's important to be clear about what assumptions we're
> making, the trade-offs involved, where they break down, and how to handle
> it when they do break down.
>
> The biggest assumptions made by beancount seem to involve its input format
> - e.g. a single monolothic file with a unified simple format suffices for
> all accounting needs of personal finance, and manual data entry is entirely
> sufficient for personal finance.  I am entirely sympathetic to these design
> goals, but it sounds like you're already starting to bump into problems
> (the wash sale rules) the root cause of which is insufficient separation of
> concerns.  I hate to tell you that there's a lot more where that came
> from... yes, squarely in the realm of personal finance (unless by "personal
> finance" you mean "trivial cases").
>

You're very confused. I'm having no problems with tracking my wash sales.
Having an open data format has allowed me to build a custom solution for
it. Not having any problems with it. Part of the power of an open system
like this is that you can easily extract subsets of data from it and write
custom code to solve a particular problem.


It's an entirely respectable position to limit the scope of the problem to
> just the general ledger - to say "beancount doesn't do inventory".
>

 but it does.
 http://furius.ca/beancount/doc/inventories


Your system looks fine for that use (although I need to test it) - I'm
> pretty sure I could write what I need externally, and dump computed JEs as
> text files to hand off to beancount.
>
> But you're heading into treacherous waters with inventory.  Shoehorning
> currency exchanges and securities trades into the same inputs as general
> ledger entries is a kludge, and if you analyze the workings of systems that
> actually handle these cases well, you'll see that you will run into
> predictable problems.  If you care about these things and want to do them,
> it's worth formulating a plan for dealing with the obvious issues that
> arise, and incorporating that understanding into the system architecture.
>

Well so far I've got accounts over four countries and 10 years' worth of
data and usage that tell me the model I've chosen is working well,
including currencies and investments. If you'd like to criticize it, I
welcome it - it can only make my software better and maybe I learn
something in the process - but you need to be specific, provide specific
examples of where it fails. Talk is cheap; start by doing something, then
present us with results or better, code. Then we can talk about performance
or representational issues and limitations.


I'm probably not the guy you really want to talk to - my knowledge of
> accounting is as meager as my understanding of computer science.  I can
> only claim to have a reasonable experience of real-world personal finance
> data that play havoc with all kinds of simplifying assumptions tha

Issue #153: issue with bean-web since python update to 3.6 (blais/beancount)

2017-01-08 Thread jb M
New issue 153: issue with bean-web since python update to 3.6
https://bitbucket.org/blais/beancount/issues/153/issue-with-bean-web-since-python-update-to

jb M:

Since updating to python 3.6 (Arch Linux), I get a problem when using bean-web.

It fails and returns:


```

Bottle v0.12.12 server starting up (using WSGIRefServer())...
Listening on http://localhost:8080/
Hit Ctrl-C to quit.

Traceback (most recent call last):
  File "/usr/bin/bean-web", line 2, in 
from beancount.web.web import main; main()
  File "/usr/lib/python3.6/site-packages/beancount/web/web.py", line 1190, in 
main
run_app(args)
  File "/usr/lib/python3.6/site-packages/beancount/web/web.py", line 1108, in 
run_app
quiet=args.quiet if hasattr(args, 'quiet') else quiet)
  File "/usr/bin/bottle.py", line 755, in run
run(self, **kwargs)
  File "/usr/bin/bottle.py", line 3127, in run
server.run(app)
  File "/usr/bin/bottle.py", line 2781, in run
srv = make_server(self.host, self.port, app, server_cls, handler_cls)
  File "/usr/lib/python3.6/site-packages/beancount/web/web.py", line 1131, in 
stealing_make_server
server = make_server(*args, **kw)
  File "/usr/lib/python3.6/wsgiref/simple_server.py", line 153, in make_server
server = server_class((host, port), handler_class)
  File "/usr/lib/python3.6/socketserver.py", line 453, in __init__
self.server_bind()
  File "/usr/lib/python3.6/wsgiref/simple_server.py", line 50, in server_bind
HTTPServer.server_bind(self)
  File "/usr/lib/python3.6/http/server.py", line 136, in server_bind
socketserver.TCPServer.server_bind(self)
  File "/usr/lib/python3.6/socketserver.py", line 467, in server_bind
self.socket.bind(self.server_address)

```

Any ideas ?


-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/20170108210706.4643.84766%40celery-worker-101.ash1.bb-inf.net.
For more options, visit https://groups.google.com/d/optout.


Intro documentation

2017-01-08 Thread Martin Blais
I have just completed and opened the introduction to the double-entry
method doc.
Here:
https://furius.ca/beancount/doc/intro

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAK21%2BhPsHntOn_fcYtD-bTzx-cuw%2B4gCp-UKxnOjy2QjTR5cfw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Upcoming changes...

2017-01-08 Thread Martin Blais
The Beancount documentation is now complete.
I had to work through a *lot* of procrastination to get there :-)

I'd like to do a few things before releasing a 2.0 version and move to
semantic versioning thereafter.
These may affect you, especially if you're packaging an installation.
Please let me know ASAP if any of these is going to have any material
impact on what you do (I don't think but I prefer to send a heads-up).

- I'd like to move "src/python/beancount/" to just a "beancount/"
subdirectory under the root, to follow well-worn conventions in the Python
community. Let me know if this makes sense to you. My source code was
located where it is now from an old convention I've had for private
repositories which support multiple programming languages and I realize it
is somewhat unusual. This project is popular enough at this point (we have
122 people on the list) I should try to make it conform to what most people
expect from a Python package before the release. This also means the Emacs
support file (beancount.el) will move somewhere else.

- The beancount.projects.returns code that computes investment returns was
put out there a long time ago, but it had some remaining flaws that made it
difficult to use and especially difficult if not impossible to debug.
Because of this, I doubt anyone uses it (but I can't know for sure). A long
time ago I began to rewrite it and fix those issues but that work fell by
the wayside and now still lives in a branch ("returns2"), sitting there
incomplete. I'd like to clean things up by removing the script and moving
this rewrite to experiments/ until I have time to complete this, where it
belongs. If you're using beancount.projects.returns and it works for you,
please let me know right away (and I'll be really surprised).

- I'll move out codes that are used for development from beancount.* into
tools/. This includes everything under src/python/beancount/docs,
beancount.scripts.example, and beancount.scripts.tutorial. I don't think
this should affect anyone. These don't belong in the main codebase, as they
should not need to be invoked by users.

Other tasks that will be done before the release are:
- Complete small refactoring for conversions to cost basis and market value
- Fix issue #145
- Write some code to download and convert documentation from GDocs to
markdown for inclusion in Dominik Aumayr's generated docs (
http://aumayr.github.io/beancount-docs-static/).

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAK21%2BhNrm7B5BEaSRhg-RVRVXN51jC9hSdjjovboix2Yr1d9fQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Intro documentation

2017-01-08 Thread Oon-Ee Ng
Not sure if this is new (I don't remember seeing it before with your
other docs), but I got this error message. Firefox on Arch Linux 64
bit.

Your connection is not secure

The owner of furius.ca has configured their website improperly. To
protect your information from being stolen, Firefox has not connected
to this website.

furius.ca uses an invalid security certificate. The certificate is
only valid for hg.furius.ca The certificate expired on 28/12/15 04:28.
The current time is 09/01/17 09:22. Error code:
SSL_ERROR_BAD_CERT_DOMAIN

On Mon, Jan 9, 2017 at 6:26 AM, Martin Blais  wrote:
> I have just completed and opened the introduction to the double-entry method
> doc.
> Here:
> https://furius.ca/beancount/doc/intro
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beancount/CAK21%2BhPsHntOn_fcYtD-bTzx-cuw%2B4gCp-UKxnOjy2QjTR5cfw%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAGQ70esEDGWL%3DFcktk34%3DL-wmP%3DV8OpvZ-R0owVU%3D6so30gX0w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Python "Traceback (most recent call last)" on Syntax Error

2017-01-08 Thread jfsbac
Hi Martin,

Happy New Year!

I wasn't sure if this should be entered as an issue, thought I would let 
you decide.  I am working on importing my credit card statements by running 
bean-extract and saving to a file, copying the credit card opening 
statement and expenses to the new file, and then adding the other half of 
the transactions.  When I ran bean-check on the completed file, I got the 
following error.  I figured I must have missed something in the new file, 
so I copied all the completed transactions to my normal beancount file, 
which had passed bean-check.  It then incurred the same error.  By process 
of elimination, I found I had missed putting the 'USD' after a transaction. 
 After adding the 'USD', bean-check worked fine.  Your code seems to handle 
most other errors, so I didn't think the Traceback was your way of 
notifying of a syntax error.

Jonathan


Enter code here...JFSMini1:Beancount$ bean-check jfsgmsbgn.bean 

Traceback (most recent call last):

  File "/usr/local/bin/bean-check", line 2, in 

from beancount.scripts.check import main; main()

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/scripts/check.py",
 
line 39, in main

extra_validations=validation.HARDCORE_VALIDATIONS)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/loader.py",
 
line 87, in load_file

extra_validations, encoding)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/loader.py",
 
line 200, in wrapped

result = function(toplevel_filename, *args, **kw)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/loader.py",
 
line 219, in _load_file

return _load([(filename, True)], *args, **kw)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/loader.py",
 
line 460, in _load

extra_validations)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/ops/validation.py",
 
line 395, in validate

new_errors = validation_function(entries, options_map)

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/ops/validation.py",
 
line 348, in validate_check_transaction_balances

"Transaction does not balance: {}".format(residual),

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/core/inventory.py",
 
line 104, in __str__

return self.to_string()

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/core/inventory.py",
 
line 96, in to_string

', '.join(pos.to_string(dformat) for pos in sorted(self)))

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/core/position.py",
 
line 228, in __lt__

return self.sortkey() < other.sortkey()

  File 
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/beancount/core/position.py",
 
line 210, in sortkey

order_units = CURRENCY_ORDER.get(currency, NCURRENCIES + len(currency))

TypeError: object of type 'type' has no len()

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/df2169e7-a716-496d-9eb8-d38ea670c4da%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Changing Extract Sort Order

2017-01-08 Thread jfsbac
When a csv file is extracted, the transactions are printed out with the 
oldest date first and the newest date last.  I was wondering if there is a 
way to reverse the sort order, i.e. print out the newest date first and the 
oldest date last, as this is how I prefer to have them ordered in my file.  

I looked in the code, and I thought the sort order might be set in 
ingest/importers/data.py by the function sorted(entries).  It seems to call 
the Python function sorted().  Sorted(entries) seems to be a function, so 
it cannot be overridden, so I tried changing the code and adding a True to 
the functin call to reverse it as an experiment (I realize any change I 
make to the code is not the best way, and will break on an update).  It 
didn't work though, the date order was still the same, so either I did not 
interpret things correctly or missed something.

Is there an easy way to reverse the sort order?  Apoligies if it is 
something I should have seen in the documentation or the Google Groups.

Jonathan

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/34af184f-db4e-4978-8177-d4dc7f8636a6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Upcoming changes...

2017-01-08 Thread yegle
Hi Martin,

While you are re-organizing your code, I was wondering if maybe you could
start accepting PR on the official mirror (
https://github.com/beancount/beancount/), or even move the project to
Github? I'm not sure if this has been brought up in the past, but git is
arguably more familiar to many peoples compare to mercurial.

On Sun, Jan 8, 2017 at 3:01 PM, Martin Blais  wrote:

> The Beancount documentation is now complete.
> I had to work through a *lot* of procrastination to get there :-)
>
> I'd like to do a few things before releasing a 2.0 version and move to
> semantic versioning thereafter.
> These may affect you, especially if you're packaging an installation.
> Please let me know ASAP if any of these is going to have any material
> impact on what you do (I don't think but I prefer to send a heads-up).
>
> - I'd like to move "src/python/beancount/" to just a "beancount/"
> subdirectory under the root, to follow well-worn conventions in the Python
> community. Let me know if this makes sense to you. My source code was
> located where it is now from an old convention I've had for private
> repositories which support multiple programming languages and I realize it
> is somewhat unusual. This project is popular enough at this point (we have
> 122 people on the list) I should try to make it conform to what most people
> expect from a Python package before the release. This also means the Emacs
> support file (beancount.el) will move somewhere else.
>
> - The beancount.projects.returns code that computes investment returns was
> put out there a long time ago, but it had some remaining flaws that made it
> difficult to use and especially difficult if not impossible to debug.
> Because of this, I doubt anyone uses it (but I can't know for sure). A long
> time ago I began to rewrite it and fix those issues but that work fell by
> the wayside and now still lives in a branch ("returns2"), sitting there
> incomplete. I'd like to clean things up by removing the script and moving
> this rewrite to experiments/ until I have time to complete this, where it
> belongs. If you're using beancount.projects.returns and it works for you,
> please let me know right away (and I'll be really surprised).
>
> - I'll move out codes that are used for development from beancount.* into
> tools/. This includes everything under src/python/beancount/docs,
> beancount.scripts.example, and beancount.scripts.tutorial. I don't think
> this should affect anyone. These don't belong in the main codebase, as they
> should not need to be invoked by users.
>
> Other tasks that will be done before the release are:
> - Complete small refactoring for conversions to cost basis and market value
> - Fix issue #145
> - Write some code to download and convert documentation from GDocs to
> markdown for inclusion in Dominik Aumayr's generated docs (
> http://aumayr.github.io/beancount-docs-static/).
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/beancount/CAK21%2BhNrm7B5BEaSRhg-RVRVXN51jC9hSdjjovboix2Yr1d9fQ
> %40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Yuchen Ying
http://about.me/yegle

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAFL5w3V2vLy2aA3NJB5btAUt8VwvuxdPnf%2BXrgDsD_vi19L9Dw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Upcoming changes...

2017-01-08 Thread Martin Blais
On Sun, Jan 8, 2017 at 10:54 PM, yegle  wrote:

> Hi Martin,
>
> While you are re-organizing your code, I was wondering if maybe you could
> start accepting PR on the official mirror (https://github.com/beancount/
> beancount/), or even move the project to Github? I'm not sure if this has
> been brought up in the past, but git is arguably more familiar to many
> peoples compare to mercurial.
>

I hear you. Probably not for a while though. I've had difficulties with git
I haven't encountered with Mercurial (and I'm not saying this from just
surface usage, I know it fairly well, its strengths and limitations and to
discuss those issues would require talking about a lot of stuff most people
don't care about. I used to support other devs' usage of git, encountered
so many problems in comparison with hg, so it's much more than "I don't
like it"). Mercurial has been much more robust over the years, and despite
github's popularity, I have heard many times from people who work closely
on scaling these things that they have a similar experience as mine. That
being said, input taken, never say never... I can see github's popularity.

Note that I haven't handled tickets/PRs in a while, mainly because I'm
focused on the boring parts of getting to a release, like finishing the
docs. Once the release is done I want to spend a bit more time processing
tickets and PRs and also some low-hanging fruit.




On Sun, Jan 8, 2017 at 3:01 PM, Martin Blais  wrote:
>
>> The Beancount documentation is now complete.
>> I had to work through a *lot* of procrastination to get there :-)
>>
>> I'd like to do a few things before releasing a 2.0 version and move to
>> semantic versioning thereafter.
>> These may affect you, especially if you're packaging an installation.
>> Please let me know ASAP if any of these is going to have any material
>> impact on what you do (I don't think but I prefer to send a heads-up).
>>
>> - I'd like to move "src/python/beancount/" to just a "beancount/"
>> subdirectory under the root, to follow well-worn conventions in the Python
>> community. Let me know if this makes sense to you. My source code was
>> located where it is now from an old convention I've had for private
>> repositories which support multiple programming languages and I realize it
>> is somewhat unusual. This project is popular enough at this point (we have
>> 122 people on the list) I should try to make it conform to what most people
>> expect from a Python package before the release. This also means the Emacs
>> support file (beancount.el) will move somewhere else.
>>
>> - The beancount.projects.returns code that computes investment returns
>> was put out there a long time ago, but it had some remaining flaws that
>> made it difficult to use and especially difficult if not impossible to
>> debug. Because of this, I doubt anyone uses it (but I can't know for sure).
>> A long time ago I began to rewrite it and fix those issues but that work
>> fell by the wayside and now still lives in a branch ("returns2"), sitting
>> there incomplete. I'd like to clean things up by removing the script and
>> moving this rewrite to experiments/ until I have time to complete this,
>> where it belongs. If you're using beancount.projects.returns and it works
>> for you, please let me know right away (and I'll be really surprised).
>>
>> - I'll move out codes that are used for development from beancount.* into
>> tools/. This includes everything under src/python/beancount/docs,
>> beancount.scripts.example, and beancount.scripts.tutorial. I don't think
>> this should affect anyone. These don't belong in the main codebase, as they
>> should not need to be invoked by users.
>>
>> Other tasks that will be done before the release are:
>> - Complete small refactoring for conversions to cost basis and market
>> value
>> - Fix issue #145
>> - Write some code to download and convert documentation from GDocs to
>> markdown for inclusion in Dominik Aumayr's generated docs (
>> http://aumayr.github.io/beancount-docs-static/).
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Beancount" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to beancount+unsubscr...@googlegroups.com.
>> To post to this group, send email to beancount@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/beancount/CAK21%2BhNrm7B5BEaSRhg-RVRVXN51jC9hSdjjovboix2
>> Yr1d9fQ%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Yuchen Ying
> http://about.me/yegle
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...

Re: Changing Extract Sort Order

2017-01-08 Thread Martin Blais
You got it.
https://bitbucket.org/blais/beancount/commits/80164efbf9ae7d19c1e929f5b4809821e99a0b6d

bean-extract --reverse ...



On Sun, Jan 8, 2017 at 9:09 PM,  wrote:

> When a csv file is extracted, the transactions are printed out with the
> oldest date first and the newest date last.  I was wondering if there is a
> way to reverse the sort order, i.e. print out the newest date first and the
> oldest date last, as this is how I prefer to have them ordered in my file.
>
> I looked in the code, and I thought the sort order might be set in
> ingest/importers/data.py by the function sorted(entries).  It seems to call
> the Python function sorted().  Sorted(entries) seems to be a function, so
> it cannot be overridden, so I tried changing the code and adding a True to
> the functin call to reverse it as an experiment (I realize any change I
> make to the code is not the best way, and will break on an update).  It
> didn't work though, the date order was still the same, so either I did not
> interpret things correctly or missed something.
>
> Is there an easy way to reverse the sort order?  Apoligies if it is
> something I should have seen in the documentation or the Google Groups.
>
> Jonathan
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/beancount/34af184f-db4e-4978-8177-d4dc7f8636a6%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAK21%2BhO4PvycBD4zQp4CjhAVg_rRoK8_EuntVo62PkONzjf0LQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Python "Traceback (most recent call last)" on Syntax Error

2017-01-08 Thread Martin Blais
This looks like a bug. This should not happen. Beancount should never raise
an uncaught exception.

Could you copy your input, isolate the offending transaction, and wittle it
down to the smallest file that will reproduce the problem?  Replace numbers
and other private things if needed. I'd appreciate, would save me time. You
can email to me directly if you're concerned about privacy.

Thanks,





On Sun, Jan 8, 2017 at 9:07 PM,  wrote:

> Hi Martin,
>
> Happy New Year!
>
> I wasn't sure if this should be entered as an issue, thought I would let
> you decide.  I am working on importing my credit card statements by running
> bean-extract and saving to a file, copying the credit card opening
> statement and expenses to the new file, and then adding the other half of
> the transactions.  When I ran bean-check on the completed file, I got the
> following error.  I figured I must have missed something in the new file,
> so I copied all the completed transactions to my normal beancount file,
> which had passed bean-check.  It then incurred the same error.  By process
> of elimination, I found I had missed putting the 'USD' after a
> transaction.  After adding the 'USD', bean-check worked fine.  Your code
> seems to handle most other errors, so I didn't think the Traceback was your
> way of notifying of a syntax error.
>
> Jonathan
>
>
> Enter code here...JFSMini1:Beancount$ bean-check jfsgmsbgn.bean
>
> Traceback (most recent call last):
>
>   File "/usr/local/bin/bean-check", line 2, in 
>
> from beancount.scripts.check import main; main()
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/scripts/check.py", line 39, in main
>
> extra_validations=validation.HARDCORE_VALIDATIONS)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/loader.py", line 87, in load_file
>
> extra_validations, encoding)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/loader.py", line 200, in wrapped
>
> result = function(toplevel_filename, *args, **kw)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/loader.py", line 219, in _load_file
>
> return _load([(filename, True)], *args, **kw)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/loader.py", line 460, in _load
>
> extra_validations)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/ops/validation.py", line 395, in
> validate
>
> new_errors = validation_function(entries, options_map)
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/ops/validation.py", line 348, in
> validate_check_transaction_balances
>
> "Transaction does not balance: {}".format(residual),
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/core/inventory.py", line 104, in __str__
>
> return self.to_string()
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/core/inventory.py", line 96, in
> to_string
>
> ', '.join(pos.to_string(dformat) for pos in sorted(self)))
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/core/position.py", line 228, in __lt__
>
> return self.sortkey() < other.sortkey()
>
>   File "/Library/Frameworks/Python.framework/Versions/3.5/lib/
> python3.5/site-packages/beancount/core/position.py", line 210, in sortkey
>
> order_units = CURRENCY_ORDER.get(currency, NCURRENCIES + len(currency))
>
> TypeError: object of type 'type' has no len()
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/beancount/df2169e7-a716-496d-9eb8-d38ea670c4da%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAK21%2BhMoK-J2Qe9o_A0kzG%3D7qe%3DZbVWC6ZG7wVENe0otKiRrOw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Intro documentation

2017-01-08 Thread Martin Blais
Ah yes, sorry, I meant to share the link as http://
I don't have/need SSL on that machine anymore.
Ignore this.

On Sun, Jan 8, 2017 at 8:23 PM, Oon-Ee Ng  wrote:

> Not sure if this is new (I don't remember seeing it before with your
> other docs), but I got this error message. Firefox on Arch Linux 64
> bit.
>
> Your connection is not secure
>
> The owner of furius.ca has configured their website improperly. To
> protect your information from being stolen, Firefox has not connected
> to this website.
>
> furius.ca uses an invalid security certificate. The certificate is
> only valid for hg.furius.ca The certificate expired on 28/12/15 04:28.
> The current time is 09/01/17 09:22. Error code:
> SSL_ERROR_BAD_CERT_DOMAIN
>
> On Mon, Jan 9, 2017 at 6:26 AM, Martin Blais  wrote:
> > I have just completed and opened the introduction to the double-entry
> method
> > doc.
> > Here:
> > https://furius.ca/beancount/doc/intro
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Beancount" group.
> > To unsubscribe from this group and stop receiving emails from it, send an
> > email to beancount+unsubscr...@googlegroups.com.
> > To post to this group, send email to beancount@googlegroups.com.
> > To view this discussion on the web visit
> > https://groups.google.com/d/msgid/beancount/CAK21%
> 2BhPsHntOn_fcYtD-bTzx-cuw%2B4gCp-UKxnOjy2QjTR5cfw%40mail.gmail.com.
> > For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/beancount/CAGQ70esEDGWL%3DFcktk34%3DL-wmP%3DV8OpvZ-
> R0owVU%3D6so30gX0w%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CAK21%2BhPrBawMKrobhNZLnPpx0LUEx3TrZtTHcA2A-A3%2BhBVuPg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Intro documentation

2017-01-08 Thread Dominik Aumayr
Martin, 

congratulations on this document!

I am really happy about it, as now I can share an introduction document, which 
has references to the way beancount works, with family and friends. Especially 
the diagrams are really useful - did you draw them by hand our auto-gen them 
from real transactions?

Best regards,
Dominik


PS: This will look even more awesome in the Sphinx-documentation, as it has 
Beancount syntax highlighting, etc.


> Am 08.01.2017 um 23:26 schrieb Martin Blais :
> 
> I have just completed and opened the introduction to the double-entry method 
> doc.
> Here:
> https://furius.ca/beancount/doc/intro
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to beancount+unsubscr...@googlegroups.com.
> To post to this group, send email to beancount@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/beancount/CAK21%2BhPsHntOn_fcYtD-bTzx-cuw%2B4gCp-UKxnOjy2QjTR5cfw%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To post to this group, send email to beancount@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/39616492-8FB9-49AE-8D08-55B956D06490%40aumayr.name.
For more options, visit https://groups.google.com/d/optout.


smime.p7s
Description: S/MIME cryptographic signature