Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sometimes, I do not have access to the exchange rate for fiat #29

Closed
Nogreedy opened this issue Jan 13, 2014 · 8 comments
Closed

Sometimes, I do not have access to the exchange rate for fiat #29

Nogreedy opened this issue Jan 13, 2014 · 8 comments
Milestone

Comments

@Nogreedy
Copy link

This morning (and yesterday afternoon) I hadn't access to exchange rate and then I could'nt choose fiat currency. Only one fiat currency was available (dollar, but I'm not sure exchange rate $/LTC was updated correctly) and I couldn't choose euro (see screencapture below) ...

sc20140113-151545

Since 1 hour, it works : I have access to all foreign currencies and I can choose between €, $, ... (see below)

sc20140113-194419

@hank
Copy link
Member

hank commented Jan 18, 2014

Have you seen this happen recently? I may add some more fiat exchange APIs for when the Yahoo! query fails...

@Nogreedy
Copy link
Author

Now, it works perfectly, but yesterday it didn't work for a few hours...

On 18/01/2014 04:03, hank - notifications@github.com wrote:

Have you seen this happen recently? I may add some more fiat exchange
APIs for when the Yahoo! query fails...


Reply to this email directly or view it on GitHub
#29 (comment).

@hank
Copy link
Member

hank commented Jan 18, 2014

OK - it seems like your Yahoo! exchange API request is failing occasionally. It would be good to have a backup for this anyway. I found this:

https://blockchain.info/ticker

Since this has USD on it, we should be able to parse it into BigDecimal and get the fiat currency scaling factors (which is exactly what I'm doing with the Yahoo! API). It wouldn't take too much code to add this. I'm scheduling it for the next release and leaving it unassigned for now.

@adv0r
Copy link

adv0r commented Jan 18, 2014

I can try looking into that.

But simply reading the readme of the wallet, quote

https://github.com/adv0r/bitcoin-wallet/tree/messy/wallet

EXCHANGE RATES

Bitcoin Wallet reads this feed from "bitcoin charts" for getting exchange rates:

    http://bitcoincharts.com/t/weighted_prices.json

The feed is described on this page (see Weighted Prices):

    http://bitcoincharts.com/about/markets-api/

I chose this feed because it is not dependent on a single exchange. However, you should keep in
mind it's always a 24h average (falling back to 7d or even 30d if no trade occurred for a long
time).

If Bitcoincharts is not available, the feed from "Blockchain" is fetched instead:

    https://blockchain.info/ticker

The feed is described here:

    https://blockchain.info/api/exchange_rates_api

So its either the readme outdated or the issue is different.

There is an inner class into ExchangeRateProvider called YahooRatesProvider . Should I create a BlockchainRateProvider ? Or maybe should look deep into this issue and check against the documentation?

@hank
Copy link
Member

hank commented Jan 18, 2014

This wallet is a fork - that readme was written for the original wallet. You have the right idea with the BlockchainRateProvider, but you mentioned there might be some java libs around for doing these API calls so we don't have to do them ourselves - that's worth looking into as well. Also, make it prefer Yahoo since there are more currencies, but fall back to blockchain. Feel free to update the readme as well to reflect the current implementation. Upstream changes can just be ignored for that readme file.

@Nogreedy
Copy link
Author

Is it possible to use the well known BitcoinAverage?
https://bitcoinaverage.com/faq.htm
-enhancement scheduled : add LTC/BTC support on https://github.com/bitcoinaverage/bitcoinaverage/issues

Or perhaps : http://www.cryptocoincharts.info/v2/
http://www.cryptocoincharts.info/v2/tools/api

@hank
Copy link
Member

hank commented Jan 19, 2014

That should work. Maybe we can even make a preference

Nogreedy notifications@github.com wrote:

Is it possible to use the well known BitcoinAverage?
https://bitcoinaverage.com/faq.htm
-enhancement scheduled : add LTC/BTC support on
https://github.com/bitcoinaverage/bitcoinaverage/issues

Or perhaps : http://www.cryptocoincharts.info/v2/
http://www.cryptocoincharts.info/v2/tools/api


Reply to this email directly or view it on GitHub:
#29 (comment)

Sent from my Android device with K-9 Mail. Please excuse my brevity.

@Nogreedy
Copy link
Author

version 3.30.2 (french version)
Now, I haven't access to the exchange rate for fiat.
The only fiat currency I can use is USD $.
I haven't access to the exchange rate since approximately 12 hours.

@hank hank closed this as completed in 1258f32 Feb 2, 2014
hank added a commit that referenced this issue Feb 4, 2014
This uses a google spreadsheets hack to provide exchange rate data
using the Google APIs.  It seems work very well.

Relevant to #29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants