I am probably missing something obvious, but i am struggling with updating the price of some commodities.
The price update process with beancount goes well for mos of my commodities (i.e: my stocks)
But it does not work for the foreing currencies.
Here is a minimalistic exemple:
root@6c75893b5a4a:/myData# cat test.beancount
;; -*- mode: org; mode: beancount; coding: utf-8; fill-column: 400; -*-
* Initialization
** Options
option "title" "Test"
option "operating_currency" "EUR"
option "name_assets" "Actif"
option "name_liabilities" "Passif"
option "name_equity" "Equity"
option "name_income" "Revenus"
option "name_expenses" "Depenses"
1981-02-07 open Equity:Opening-Balances
* Commodities
1999-01-01 commodity EUR
asset-class: "cash"
price: "USD:yahoo/EURUSD=X"
1999-01-01 commodity CAD
name: "Canadian Dollar"
asset-class: "cash"
price: "EUR:yahoo/^EURCAD=X"
1999-01-01 commodity USD
name: "US Dollar"
asset-class: "cash"
price: "EUR:yahoo/^EURUSD=X"
1999-01-01 commodity GBX
name: "Pence Sterling"
asset-class: "cash"
* Cash Daybook
1981-07-02 open Actif:Cash
1981-07-03 pad Actif:Cash Equity:Opening-Balances
2019-08-23 balance Actif:Cash 7000 EUR
2019-08-23 balance Actif:Cash 1.00 USD
2019-08-23 balance Actif:Cash 1.00 CAD
2019-08-23 balance Actif:Cash 1.00 GBX
When i try to update the price, neither USD or CAD price gets updated:
root@6c75893b5a4a:/myData# /usr/local/bin/bean-price /myData/test.beancount -vv --no-cache
INFO : Processing at date: 2019-10-19
INFO : Loading "/myData/test.beancount"
DEBUG : Ignoring currency with no metadata: GBX
DEBUG : -------- Currencies in primary list:
DEBUG : CAD /EUR
DEBUG : EUR /USD
DEBUG : USD /EUR
DEBUG : -------- Currencies held in assets:
DEBUG : -------- Currencies to fetch:
Any idea why nothing happens ? I would expect bean-price to fetch the current quote for CAD/EUR and USD/EUR.
Side question:
GBX is the ticker for the british pound pence. Most british stocks have their prices in GBX. However, the forex datas are usually for GBP .
Is it possible to ask bean-price to compute GBX from GBP ? a statement like:
1999-01-01 commodity GBX
name: "Pence Sterling"
asset-class: "cash"
price: "EUR:yahoo/1/100*GBPEUR=X)
or should i write a custom price fetcher for that ?
DEBUG : Ignoring currency with no metadata: GBXDEBUG : -------- Currencies in primary list:
DEBUG : CAD /EUR
DEBUG : EUR /USD
DEBUG : USD /EUR
DEBUG : -------- Currencies held in assets:
DEBUG : -------- Currencies to fetch:
Any idea why nothing happens ? I would expect bean-price to fetch the current quote for CAD/EUR and USD/EUR.
Using the --inactive flag is not an option for me. I have too many commodities that have been created, kept in my portfolio for a while, but are not used anymore.
I wonder why any commodity held currently in the portfolio (but the primary commodity of course) is not updated.
foreign currencies by essence are not held at cost. However, i would like their price to be updated.