raise another exception

This commit is contained in:
Diogo Sousa
2023-07-21 16:30:40 +01:00
parent 0855883e9d
commit 95e297770d

View File

@@ -56,6 +56,8 @@ class CommandOutput(GenericModel, Generic[T], Tagged):
df.index = pd.to_datetime(df.index)
except ValueError:
df = pd.DataFrame(self.dict()["results"], index=["values"]).T
except Exception as e:
raise OpenBBError("Failed to convert results to dataframe.") from e
return df