Announcement: v3 and git branches

1,300 views
Skip to first unread message

Martin Blais

unread,
Jun 16, 2024, 4:22:59 PM (13 days ago) Jun 16
to Beancount
Based on our recent discussion around Beancount branches being confusing, I did the following to branches:

- v2: remains the same (no change); but v2 is now even less subject to freeze exceptions than before, because v3 is now officially born and PyPI releases will be made for it.  The default reply to patches to v2 will be "move that to v3."

- cpp: I turned the previous master branch's state with all C++ and Bazel build into a new 'cpp' branch. 
  All work on the C++ rewrite -- if it is to continue -- will live on that branch.
  If things do move to Rust, I will probably salvage bits and pieces of that manually into a 'rust' branch.
  In particular, the schema defined in the proto files is something I'd like to carry forward (nicely
  documented and distinguishes between the pre and post interpolation data structures explicitly), 
  and perhaps the new reFlex parser will be useful at some point.

- v3: a new branch, to contain the state of the master branch MINUS the C++ bits. 
  As stated above, the C++ code remains only on branch 'cpp'.
  This is now the official release branch and PyPI releases will be made of it.

- master: this branch is now where new work on v3 might live.
  I'm not sure we really need it or what it should mean, but it should track v3 for now.

I've reviewed missing PyPI releases and made sure we have these:

The inclusion of v3 releases for PyPI and new PyPI releases for subprojects should normalize the versioning situation in Beancount. Note that packaging and following other people's conventions are not my forte (and I don't use PyPI for my own projects I just use source), if you have any suggestions or something's missing please reply to this thread.

Thanks for your patience, 

Brian Lalor

unread,
Jun 17, 2024, 6:00:23 AM (12 days ago) Jun 17
to bean...@googlegroups.com
This is great! Thank you! Is there a summary of what’s new/different in 3.0.0 from 2.3.6? (Also I don’t see a 3.0.0 tag in GitHub; was that an oversight?)
-- 
Brian Lalor (he/him)
bla...@bravo5.org

On Jun 16, 2024, at 4:23 PM, Martin Blais <bl...@furius.ca> wrote:


--
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+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/beancount/CAK21%2BhNfFy-Y%3DiOgnNLFf04c42b4hBiqgfcjGCx-re2H02y_ww%40mail.gmail.com.

Martin Blais

unread,
Jun 17, 2024, 7:34:10 AM (12 days ago) Jun 17
to bean...@googlegroups.com
On Mon, Jun 17, 2024 at 6:00 AM Brian Lalor <bjl...@bravo5.org> wrote:
This is great! Thank you! Is there a summary of what’s new/different in 3.0.0 from 2.3.6? (Also I don’t see a 3.0.0 tag in GitHub; was that an oversight?)

v3 
- removes beanquery, beanprice, beanweb and more, is pretty stripped down. Use the subprojects instead.
- has a number of really minor fixes added over time but no major new features
If you were using the 'master' branch there's no change.

You should not use v2 anymore.


 

Martin Blais

unread,
Jun 17, 2024, 7:35:48 AM (12 days ago) Jun 17
to Martin Blais, bean...@googlegroups.com
I'd forgotten the tag. There's one now.

Stefano Zacchiroli

unread,
Jun 17, 2024, 7:37:08 AM (12 days ago) Jun 17
to bean...@googlegroups.com
On Sun, Jun 16, 2024 at 04:22:43PM -0400, Martin Blais wrote:
> Based on our recent discussion around Beancount branches being confusing, I
> did the following to branches:

Thanks Martin, this is awesome!

As a user report: I've migrated all my beancount toolchain to v3,
without any issue (aside from the Fava incompatibility, which was
already known and discussed here in the previous thread).

For those using Fava, beware that if you "pip install fava" after "pip
install beancount" (with the latest release), that will revert your
beancount back to 2.x.

Cheers
--
Stefano Zacchiroli . za...@upsilon.cc . https://upsilon.cc/zack _. ^ ._
Full professor of Computer Science o o o \/|V|\/
Télécom Paris, Polytechnic Institute of Paris o o o </> <\>
Co-founder & CTO Software Heritage o o o o /\|^|/\
https://twitter.com/zacchiro . https://mastodon.xyz/@zacchiro '" V "'

Martin Michlmayr

unread,
Jun 17, 2024, 7:41:41 AM (12 days ago) Jun 17
to bean...@googlegroups.com
* Martin Blais <bl...@furius.ca> [2024-06-17 07:33]:
> v3

Are there any syntax changes in v3?

When I tried to compile a list in 2022, I came up with:

* Single-character currency names are now supported
* Currency symbols now support a leading slash (/)
* Flags: Any of the A-Z characters are now supported, but have to be preceded by a single quote: 'A
* The limitation for currency names to be 24 characters long has been dropped (I think)

Did this make into into this v3 or not (and are there any other
changes?)

--
Martin Michlmayr
https://www.cyrius.com/

Chary Chary

unread,
Jun 17, 2024, 9:05:43 AM (12 days ago) Jun 17
to Beancount
Martin,

thank you for the clarification!

And what about the documentation? Will you create new google docs for V3?

I think so far the biggest affected part if beanquery, but I notice that also other part of the extensive documentation set is affected here and there by changes to V3

Daniele Nicolodi

unread,
Jun 17, 2024, 9:39:32 AM (12 days ago) Jun 17
to bean...@googlegroups.com
On 17/06/24 13:41, Martin Michlmayr wrote:
> * Martin Blais <bl...@furius.ca> [2024-06-17 07:33]:
>> v3
>
> Are there any syntax changes in v3?
>
> When I tried to compile a list in 2022, I came up with:
>
> * Single-character currency names are now supported
> * Currency symbols now support a leading slash (/)
> * Flags: Any of the A-Z characters are now supported, but have to be preceded by a single quote: 'A

Prepending the single quote to flags was introduced to disambiguate
flags from single character currencies in the lexer. However, I didn't
like like it and tweaked the parser to do the disambiguation in the
grammar instead. Flag characters do not need to be prefixed with a
single quote anymore.

> * The limitation for currency names to be 24 characters long has been dropped (I think)
>
> Did this make into into this v3 or not (and are there any other
> changes?)

All that was on the master branch as of yesterday is in the 3.0.0
release. I don't remember any other changes to the syntax beside what
you mention.

Cheers,
Dan

Lover O'Bean

unread,
Jun 17, 2024, 12:13:17 PM (12 days ago) Jun 17
to Beancount
Great news!

Stefano Zacchiroli

unread,
Jun 18, 2024, 3:27:20 AM (12 days ago) Jun 18
to bean...@googlegroups.com
Heads up for people transitioning to v3: the bean-extract executable is
gone. I didn't realize this as first; it might be useful to others to
know this in advance.

I welcome migration tips on what's the easiest migration path (to
beangulp, I guess?)

Meanwhile I'm temporarily reverting back to v2,

Martin Michlmayr

unread,
Jun 18, 2024, 3:36:46 AM (12 days ago) Jun 18
to bean...@googlegroups.com
* Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
> I welcome migration tips on what's the easiest migration path (to
> beangulp, I guess?)

Yes.

Stefano Zacchiroli

unread,
Jun 18, 2024, 3:43:22 AM (12 days ago) Jun 18
to bean...@googlegroups.com
About this:

On Sun, Jun 16, 2024 at 04:22:43PM -0400, Martin Blais wrote:
> I've reviewed missing PyPI releases and made sure we have these:
> https://pypi.org/project/beancount2ledger/

did you mean to release the current beancount2ledger to PyPI?

Because it currently isn't released (last release on PyPI is 4-year old,
last commit in Git 2-year old) and there are a couple of useful changes
in Git: a missing dependency in requirements.txt and the configurability
of a metadata key used (ledger side) to store payees.

I'm listed as co-maintainer of beancount2ledger so I can do this too,
but wanted to check with you before proceeding to avoid an upload race.

Let me know,

Stefano Zacchiroli

unread,
Jun 18, 2024, 4:13:23 AM (11 days ago) Jun 18
to bean...@googlegroups.com
On Tue, Jun 18, 2024 at 03:36:34PM +0800, Martin Michlmayr wrote:
> * Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
> > I welcome migration tips on what's the easiest migration path (to
> > beangulp, I guess?)
>
> Yes.

Thanks, although I'm still a bit confused.

This document
https://docs.google.com/document/d/1hBfsHZcoHgz5rvhCdP42g2FJ5ouycIMV4H1tfgXpwBU/
"Importing External Data in Beancount" is about v3 ("This document is
about Beancount v3, under development, and a work in progress.") and
Beangulp, but still talks about bean-extract as an executable involved
in importing transactions with v3/beangulp.

What am I missing?

Daniele Nicolodi

unread,
Jun 18, 2024, 5:57:26 AM (11 days ago) Jun 18
to bean...@googlegroups.com
On 18/06/24 10:13, Stefano Zacchiroli wrote:
> On Tue, Jun 18, 2024 at 03:36:34PM +0800, Martin Michlmayr wrote:
>> * Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
>>> I welcome migration tips on what's the easiest migration path (to
>>> beangulp, I guess?)
>>
>> Yes.
>
> Thanks, although I'm still a bit confused.
>
> This document
> https://docs.google.com/document/d/1hBfsHZcoHgz5rvhCdP42g2FJ5ouycIMV4H1tfgXpwBU/
> "Importing External Data in Beancount" is about v3 ("This document is
> about Beancount v3, under development, and a work in progress.") and
> Beangulp, but still talks about bean-extract as an executable involved
> in importing transactions with v3/beangulp.
>
> What am I missing?

The "under development, and a work in progress" warning refers to the
content of the document rather than to the subject of the document :-)

The best documentation there is for beangulp is the example included in
the repository
https://github.com/beancount/beangulp/tree/master/examples and the
docstrings in the code.

In a nutshell, to upgrade from beancount.ingest to beangulp, it shoul be
sufficient to modify all Python imports from the beancount.ingest
namespace to the beangulp namespace and to turn the configuration file
that was used to be passed to bean-extract into a self-standing script
as demonstrated here
https://github.com/beancount/beangulp/blob/master/examples/import.py
Then, calling such script with a '--help' argument should be enough to
understand how to use it.

A second (optional) step would be to update the importers from the old
beangulp.ImporterProtocol interface to the new beangulp.Importer
interface, which allows to implement some new features.

Cheers,
Dan

Daniele Nicolodi

unread,
Jun 18, 2024, 6:05:19 AM (11 days ago) Jun 18
to bean...@googlegroups.com
On 18/06/24 11:57, Daniele Nicolodi wrote:
> On 18/06/24 10:13, Stefano Zacchiroli wrote:
>> On Tue, Jun 18, 2024 at 03:36:34PM +0800, Martin Michlmayr wrote:
>>> * Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
>>>> I welcome migration tips on what's the easiest migration path (to
>>>> beangulp, I guess?)
>>>
>>> Yes.
>>
>> Thanks, although I'm still a bit confused.
>>
>> This document
>> https://docs.google.com/document/d/1hBfsHZcoHgz5rvhCdP42g2FJ5ouycIMV4H1tfgXpwBU/
>> "Importing External Data in Beancount" is about v3 ("This document is
>> about Beancount v3, under development, and a work in progress.") and
>> Beangulp, but still talks about bean-extract as an executable involved
>> in importing transactions with v3/beangulp.
>>
>> What am I missing?
>
> The "under development, and a work in progress" warning refers to the
> content of the document rather than to the subject of the document :-)
>
> The best documentation there is for beangulp is the example included in
> the repository
> https://github.com/beancount/beangulp/tree/master/examples and the
> docstrings in the code.

The doctests
https://github.com/beancount/beangulp/tree/master/beangulp/tests may
also be useful.

Martin Blais

unread,
Jun 18, 2024, 7:09:43 AM (11 days ago) Jun 18
to Beancount


On Tue, Jun 18, 2024, 04:13 Stefano Zacchiroli <za...@upsilon.cc> wrote:
On Tue, Jun 18, 2024 at 03:36:34PM +0800, Martin Michlmayr wrote:
> * Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
> > I welcome migration tips on what's the easiest migration path (to
> > beangulp, I guess?)
>
> Yes.

Thanks, although I'm still a bit confused.

This document
https://docs.google.com/document/d/1hBfsHZcoHgz5rvhCdP42g2FJ5ouycIMV4H1tfgXpwBU/
"Importing External Data in Beancount" is about v3 ("This document is
about Beancount v3, under development, and a work in progress.") and
Beangulp, but still talks about bean-extract as an executable involved
in importing transactions with v3/beangulp.

What am I missing?

Ah yes.... I should rename all the v3 docs to sometime more generic, like roadmap to the future or something. Will do.
 Thanks for reminding me






--
Stefano Zacchiroli . za...@upsilon.cc . https://upsilon.cc/zack  _. ^ ._
Full professor of Computer Science              o     o   o     \/|V|\/
Télécom Paris, Polytechnic Institute of Paris     o     o o    </>   <\>
Co-founder & CTO Software Heritage            o o o     o       /\|^|/\
https://twitter.com/zacchiro . https://mastodon.xyz/@zacchiro   '" V "'

--
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+...@googlegroups.com.

Martin Blais

unread,
Jun 18, 2024, 7:49:09 AM (11 days ago) Jun 18
to bean...@googlegroups.com
On Tue, Jun 18, 2024 at 3:43 AM Stefano Zacchiroli <za...@upsilon.cc> wrote:
About this:

On Sun, Jun 16, 2024 at 04:22:43PM -0400, Martin Blais wrote:
> I've reviewed missing PyPI releases and made sure we have these:
> https://pypi.org/project/beancount2ledger/

did you mean to release the current beancount2ledger to PyPI?

Not really, but if it needs to we could.


Because it currently isn't released (last release on PyPI is 4-year old,
last commit in Git 2-year old) and there are a couple of useful changes
in Git: a missing dependency in requirements.txt and the configurability
of a metadata key used (ledger side) to store payees.

I'm listed as co-maintainer of beancount2ledger so I can do this too,
but wanted to check with you before proceeding to avoid an upload race.

Please do! SGTM



 

Let me know,
Cheers
--
Stefano Zacchiroli . za...@upsilon.cc . https://upsilon.cc/zack  _. ^ ._
Full professor of Computer Science              o     o   o     \/|V|\/
Télécom Paris, Polytechnic Institute of Paris     o     o o    </>   <\>
Co-founder & CTO Software Heritage            o o o     o       /\|^|/\
https://twitter.com/zacchiro . https://mastodon.xyz/@zacchiro   '" V "'

--
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+...@googlegroups.com.

Martin Blais

unread,
Jun 18, 2024, 8:03:22 AM (11 days ago) Jun 18
to Beancount
On Tue, Jun 18, 2024 at 7:09 AM Martin Blais <bl...@furius.ca> wrote:
On Tue, Jun 18, 2024, 04:13 Stefano Zacchiroli <za...@upsilon.cc> wrote:
On Tue, Jun 18, 2024 at 03:36:34PM +0800, Martin Michlmayr wrote:
> * Stefano Zacchiroli <za...@upsilon.cc> [2024-06-18 09:27]:
> > I welcome migration tips on what's the easiest migration path (to
> > beangulp, I guess?)
>
> Yes.

Thanks, although I'm still a bit confused.

This document
https://docs.google.com/document/d/1hBfsHZcoHgz5rvhCdP42g2FJ5ouycIMV4H1tfgXpwBU/
"Importing External Data in Beancount" is about v3 ("This document is
about Beancount v3, under development, and a work in progress.") and
Beangulp, but still talks about bean-extract as an executable involved
in importing transactions with v3/beangulp.

What am I missing?

Ah yes.... I should rename all the v3 docs to sometime more generic, like roadmap to the future or something. Will do.
 Thanks for reminding me

Two "v3" docs are really about a future rewrite or a desiderata. I've renamed those to "Vnext."
Those are very much still relevant for future work.

Some of the other "v3" docs were about "v3" as in "C++ rewrite," and now that that's moved to a branch, 
I just called those "C++ version". You can safely ignore these.

The content is largely unchanged. You've already read all those docs, there's nothing really new but a change in name.

I'm hoping to restart doing some needed changes incrementally to what is now called "v3" this summer.
In particular, I think making precision and tolerance explicit can be done backwards-compatibly and a lot of questions come about that.
Modernizing a bit, I've applied auto-formatting (via ruff format) over the weekend, and will be adding types as well over time.

Marcio A. Vianna F. (mvianna)

unread,
Jun 18, 2024, 10:31:14 AM (11 days ago) Jun 18
to Beancount
Hi,

Let me avail this thread for a request: Could anyone give a recepy for computer semi-literate people of how to remain on the latest version 2 + reds importers + fava for the time being?

Shoul I "pip install beancount<3" or something? Should I pin the version?

Thanks in advance.

Marcio

francois PEGORY

unread,
Jun 20, 2024, 6:51:29 AM (9 days ago) Jun 20
to bean...@googlegroups.com
i agree that it is a great news.
nows , fava need to be updated in orer to work beancount  3...

Le lun. 17 juin 2024 à 18:13, Lover O'Bean <lover...@gmail.com> a écrit :
Great news!

--
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+...@googlegroups.com.

Martin Blais

unread,
Jun 22, 2024, 2:49:05 PM (7 days ago) Jun 22
to Martin Blais, bean...@googlegroups.com
I just fixed the github actions/workflows to produce and upload valid wheels.
It includes wheels from 3.8 to 3.12 for windows, macos, linux for 3.0.0.


Reply all
Reply to author
Forward
0 new messages