A simple client for this library and Django. #50
Sigularusrex
started this conversation in
Show and tell
Replies: 2 comments
-
Here are a few basic tests in case you want to try it in your project:
|
Beta Was this translation helpful? Give feedback.
0 replies
-
For the record, here is the code I use to make sure I always have the latest rates (it is in the README as well). It downloads the data for the day, unless it has already been downloaded: import os.path as op
import urllib.request
from datetime import date
from currency_converter import ECB_URL, CurrencyConverter
filename = f"ecb_{date.today():%Y%m%d}.zip"
if not op.isfile(filename):
urllib.request.urlretrieve(ECB_URL, filename)
c = CurrencyConverter(filename) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I thought I'd share my client implementation for using this library. It's quite specific to my needs at the moment, but with a little discussion, maybe it can be improved.
Beta Was this translation helpful? Give feedback.
All reactions