Skip to content

fix Base/Quote currency ordering in global symbol conversion #515

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

Merged
merged 2 commits into from
Jan 28, 2020

Conversation

nh43de
Copy link
Contributor

@nh43de nh43de commented Jan 26, 2020

Fixes #500

Global symbols list the base currency first (e.g. BTC) and quote/conversion currency
second (e.g. USD). Global symbols are of the form BASE-QUOTE. BASE-QUOTE is read as
1 BASE is worth y QUOTE.

Examples:
On 1/25/2020,
- BTC-USD: $8,371; 1 BTC (base) is worth $8,371 USD (quote)
- ETH-BTC: 0.01934; 1 ETH is worth 0.01934 BTC
- EUR-USD: 1.2; 1 EUR worth 1.2 USD

Pull Request Changes:

  • Fixed issue with GlobalMarketSymbolToExchangeMarketSymbolAsync returning QUOTE-BASE in base ExchangeAPI class
  • Fixed tests to use standard BASE-QUOTE format
  • Fixed Bitthumb and Kraken exchange APIs as a result of changes
  • Added some better details/docs about currency pairs

@nh43de
Copy link
Contributor Author

nh43de commented Jan 26, 2020

One more note - this is likely a breaking change because of how global symbols were treated in some cases.

@nh43de nh43de requested a review from jjxtra January 26, 2020 19:48
@vslee vslee added the bug label Jan 27, 2020
@vslee vslee changed the title Fix for issue #500 - Making Sense of Base/Quote Currency Ordering for Symbol Strings fix Base/Quote currency ordering in global symbol conversion Jan 27, 2020
@jjxtra
Copy link
Collaborator

jjxtra commented Jan 28, 2020

Anyone have any objections here?

@vslee
Copy link
Collaborator

vslee commented Jan 28, 2020

Will defer to you on this one

@jjxtra
Copy link
Collaborator

jjxtra commented Jan 28, 2020

@vslee Can we rev to a 0.7.0 version as this is a breaking change?

@vslee
Copy link
Collaborator

vslee commented Jan 28, 2020

Yes, I'll set the next nuget version to be 0.7.0.

@vslee vslee merged commit 02b009d into DigitalRuby:master Jan 28, 2020
@jjxtra
Copy link
Collaborator

jjxtra commented Jan 28, 2020

Thank you!

szmcdull pushed a commit to szmcdull/ExchangeSharp that referenced this pull request Mar 5, 2020
…Ruby#515)

* Test and fix base ExhchangeAPI symbol functionality

* Fix bitthumb and Kraken APIs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Making Sense of Base/Quote Currency Ordering for Symbol Strings
3 participants