I guess a link has the advantage that it would support multiple uuids, if you for some reason wanted to combine multiple YNAB transactions into a single beancount transaction. However, the limited character set supported by links/tags can make it a bit challenging to encode the relevant information. In this case it seems like ynab.xxxxx would work fine for this case, though.
In beancount-import, the existing data sources currently use transaction or posting metadata fields for all of that type of information. It is normally recorded on a per-posting basis -- only some specialized sources, like the amazon one, use transaction metadata. If per-posting links were supported, that would solve part of the problem, though it would still be complicated/inconvenient to encode the information in the link character set. Using metadata fields also conveniently enforces the restriction that there be only a single value. On Tue, Oct 9, 2018 at 4:31 PM Martin Blais <[email protected]> wrote: > On Sat, Oct 6, 2018 at 4:45 AM Justus Pendleton <[email protected]> > wrote: > >> On Friday, October 5, 2018 at 6:52:57 AM UTC+7, Jeremy Maitin-Shepard >> wrote: >>> >>> - it includes metadata in imported entries that allow it to reliably >>> associate entries in the journal with external data, so that you don't need >>> to manually track what has already been imported. >>> >> >> Can you give a point to the code for how this works? It is something that >> individual Source implementations can override or control? >> >> I ask because I have a YNAB4 importer[1] which uses metadata on each >> transaction to achieve a similar result. In YNAB, each transaction has a >> UUID, so by shoving that in beancount metadata, I can keep track of what >> has already been imported. >> > > BTW you should consider using a ^link for that; they were designed for > that purpose. > When there's a unique transaction id available from the files I import, I > always add them as a link. > > > I'm vaguely interested in rewriting the YNAB importer to use your >> framework -- since yours has lots of other nice things -- but I don't >> really want to have to deal with re-confirming years worth of already >> imported YNAB transactions. So ideally I could have a YNAB Source in your >> framework that UUID. Is something like that possible? >> >> [1]: https://github.com/hoostus/beancount-ynab >> >>> -- >> 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 [email protected]. >> To post to this group, send email to [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/beancount/a4287678-ff62-4a58-9ba7-f07ec7c86c4f%40googlegroups.com >> <https://groups.google.com/d/msgid/beancount/a4287678-ff62-4a58-9ba7-f07ec7c86c4f%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> 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 [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/beancount/CAK21%2BhPodK3faT5YhMQrYp74PriWNj486oe5j-nh1n%3DykUP-nw%40mail.gmail.com > <https://groups.google.com/d/msgid/beancount/CAK21%2BhPodK3faT5YhMQrYp74PriWNj486oe5j-nh1n%3DykUP-nw%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > 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 [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beancount/CAKJfoCEthmogrc8Ua2hZ%3D85MFoAWV-zT-8jRw4%3DT_ZCR_ZyPSQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
