beancount / beanprice

Daily price quotes fetching library for plain-text accounting
GNU General Public License v2.0
70 stars 38 forks source link

bean-price --update no longer exists #88

Open RicardoBlank opened 6 months ago

RicardoBlank commented 6 months ago

I am starting to use bean-price and one thing that I noted is that there is no --update option.

usage: bean-price [-h] [--version] [-e] [-v] [-d DATE] [-i] [-u UNDECLARED] [-c] [-a] [-s] [-n] [--cache CACHE_FILENAME] [--no-cache] [--clear-cache] sources [sources ...]

Fetch prices from the internet and output them as Beancount price directives.

positional arguments: sources A list of filenames (or source "module/symbol", if -e is specified) from which to create a list of jobs.

options: -h, --help show this help message and exit --version, -V show program's version number and exit -e, --expressions, --expression Interpret the arguments as "module/symbol" source strings. -v, --verbose Print out progress log. Specify twice for debugging info. -d DATE, --date DATE Specify the date for which to fetch the prices. -i, --inactive Select all commodities from input files, not just the ones active on the date -u UNDECLARED, --undeclared UNDECLARED Include commodities viewed in the file even without a corresponding Commodity directive, from this default source. The currency name itself is used as the lookup symbol in this default source. -c, --clobber Do not skip prices which are already present in input files; fetch them anyway. -a, --all A shorthand for --inactive, --undeclared, --clobber. -s, --swap-inverted For inverted sources, swap currencies instead of inverting the rate. For example, if fetching the rate for CAD from 'USD:google/^CURRENCY:USDCAD' results in 1.25, by default we would output "price CAD 0.8000 USD". Using this option we would instead output " price USD 1.2500 CAD". -n, --dry-run Don't actually fetch the prices, just print the list of the ones to be fetched.

cache: --cache CACHE_FILENAME Enable the cache and with the given cache name. --no-cache Disable the price cache. --clear-cache Clear the cache prior to startup

By the way this is the version I am using: Beancount 2.3.6 (git:d77540c4; 2023-10-05)

carposio commented 1 month ago

I ran into the same issue, but upgrading to the latest version from master branch fixed it for me:

pip install --upgrade git+https://github.com/beancount/beanprice.git@master