mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-30 14:02:06 +00:00
Fix 3018 (#3269)
* fix(docs): added margin between sections * fix: added autocompletion Co-authored-by: James Maslek <jmaslek11@gmail.com>
This commit is contained in:
@@ -128,7 +128,10 @@ class CryptoController(CryptoBaseController):
|
||||
]
|
||||
},
|
||||
}
|
||||
choices["price"] = {c: {} for c in pyth_model.ASSETS.keys()}
|
||||
choices["price"] = {
|
||||
"--symbol": {c: {} for c in pyth_model.ASSETS.keys()},
|
||||
"-s": "--symbol",
|
||||
}
|
||||
choices["headlines"] = {c: {} for c in finbrain_crypto_view.COINS}
|
||||
# choices["prt"]["--vs"] = {c: {} for c in coingecko_coin_ids} # list is huge. makes typing buggy
|
||||
|
||||
@@ -258,12 +261,14 @@ class CryptoController(CryptoBaseController):
|
||||
ns_parser = self.parse_known_args_and_warn(parser, other_args)
|
||||
|
||||
if ns_parser:
|
||||
|
||||
if ns_parser.symbol in pyth_model.ASSETS.keys():
|
||||
upper_symbol = ns_parser.symbol.upper()
|
||||
if "-USD" not in ns_parser.symbol:
|
||||
upper_symbol += "-USD"
|
||||
if upper_symbol in pyth_model.ASSETS.keys():
|
||||
console.print(
|
||||
"[param]If it takes too long, you can use 'Ctrl + C' to cancel.\n[/param]"
|
||||
)
|
||||
pyth_view.display_price(ns_parser.symbol)
|
||||
pyth_view.display_price(upper_symbol)
|
||||
else:
|
||||
console.print("[red]The symbol selected does not exist.[/red]\n")
|
||||
|
||||
|
||||
@@ -20,7 +20,6 @@ ASSETS = {
|
||||
"APE-USD": {"feedID": "EfnLcrwxCgwALc5vXr4cwPZMVcmotZAuqmHa8afG8zJe"},
|
||||
"ATLAS-USD": {"feedID": "Dzs6SE1cssUqBpWCKzE4jeS5PrmRK1Fp2Kw1WMaDCiVR"},
|
||||
"ATOM-USD": {"feedID": "7YAze8qFUMkBnyLVdKT4TFUUFui99EwS5gfRArMcrvFk"},
|
||||
"AUST-UST": {"feedID": "9g8mGLKcDiKSrWahbjKGtpGCcrLkC5kbwmpFFGRs6euf"},
|
||||
"AVAX-USD": {"feedID": "FVb5h1VmHPfVb1RfqZckchq18GxRv4iKt8T4eVTQAqdz"},
|
||||
"BCH-USD": {"feedID": "4EQrNZYk5KR1RnjyzbaaRbHsv8VqZWzSUtvx58wLsZbj"},
|
||||
"BETH-USD": {"feedID": "HyShqBUTtwAaCas9Dnib3ut6GmEDk9hTdKsrNfRffX8E"},
|
||||
|
||||
@@ -17,6 +17,7 @@ find eth --source Coinbase
|
||||
|
||||
# Price
|
||||
# price eth
|
||||
price eth
|
||||
|
||||
# Headlines
|
||||
headlines
|
||||
|
||||
Reference in New Issue
Block a user