mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-27 12:40:35 +00:00
Edit ark_model to get rid of added columns from the json repsonse (#586)
* Edit ark_model to get rid of added columns from the json repsonse * Figure out the mock response. Add ./tests to codespell lineting to avoid all the issues iwth company names...
This commit is contained in:
@@ -40,16 +40,31 @@ def get_ark_orders() -> DataFrame:
|
||||
|
||||
df_orders.drop(
|
||||
[
|
||||
"everything",
|
||||
"everything.profile.customThumbnail",
|
||||
"hidden",
|
||||
"images.thumbnail",
|
||||
"cusip",
|
||||
"estimated_price",
|
||||
"updated_at",
|
||||
"created_at",
|
||||
"region",
|
||||
"country",
|
||||
"isADR",
|
||||
"companyName",
|
||||
"clinicalTrialsSearchHandle",
|
||||
"wasSPACBuy",
|
||||
"currencyMultiplier",
|
||||
"useRapidAPI",
|
||||
"description",
|
||||
"quandlTicker",
|
||||
"customThumbnail",
|
||||
"custom_thumbnail",
|
||||
"id",
|
||||
],
|
||||
axis=1,
|
||||
inplace=True,
|
||||
)
|
||||
|
||||
df_orders["date"] = pd.to_datetime(df_orders["date"], format="%Y-%m-%dZ").dt.date
|
||||
df_orders["date"] = pd.to_datetime(df_orders["date"], format="%Y-%m-%d").dt.date
|
||||
|
||||
return df_orders
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ def ark_orders_view(other_args: List[str]):
|
||||
df_orders = ark_model.get_ark_orders()
|
||||
|
||||
if df_orders.empty:
|
||||
print("The ARK orders aren't anavilable at the moment.\n")
|
||||
print("The ARK orders aren't available at the moment.\n")
|
||||
return
|
||||
|
||||
pd.set_option("mode.chained_assignment", None)
|
||||
|
||||
1393
tests/data/discovery_ark_model.yaml
vendored
1393
tests/data/discovery_ark_model.yaml
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user