Hi we got this GraphQL error on 0.15.2 ```Operati...
# ask-community
Hi we got this GraphQL error on 0.15.2
Copy code
Operation name: PipelineExplorerRootQuery

Message: 'PandasDataFrame'

Path: ["pipelineSnapshotOrError","solidHandles",0,"solid","definition","outputDefinitions",0,"type"]

Locations: [{"line":350,"column":5}]
stack trace from a local dagit
Copy code
INFO:dagster.code_server:Started Dagster code server for file /home/ystanley/src/cdf-pipeline/cdf_pipeline/repo.py in process 23794
An error occurred while resolving field OutputDefinition.type
Traceback (most recent call last):
  File "/home/ystanley/.local/share/virtualenvs/cdf-pipeline-tmfbeboM/lib/python3.7/site-packages/graphql/execution/executor.py", line 452, in resolve_or_error
    return executor.execute(resolve_fn, source, info, **args)
  File "/home/ystanley/.local/share/virtualenvs/cdf-pipeline-tmfbeboM/lib/python3.7/site-packages/graphql/execution/executors/sync.py", line 16, in execute
    return fn(*args, **kwargs)
  File "/home/ystanley/.local/share/virtualenvs/cdf-pipeline-tmfbeboM/lib/python3.7/site-packages/dagster_graphql/schema/solids.py", line 93, in resolve_type
  File "/home/ystanley/.local/share/virtualenvs/cdf-pipeline-tmfbeboM/lib/python3.7/site-packages/dagster_graphql/schema/dagster_types.py", line 36, in to_dagster_type
  File "/home/ystanley/.local/share/virtualenvs/cdf-pipeline-tmfbeboM/lib/python3.7/site-packages/dagster/core/snap/dagster_types.py", line 55, in get_dagster_type_snap
    return self.all_dagster_type_snaps_by_key[key]
KeyError: 'PandasDataFrame'
the root cause ended up being:
Copy code
def my_op(start) -> dagster_pandas.DataFrame:
instead of
Copy code
def my_op(start) -> pandas.DataFrame:
it would have been nice if the stack trace was able to point to the problematic ops
Hey Stanley - I'll file an issue for this, agree this is a very confusing experience that could use a much better error. @Dagster Bot issue confusing error message when an op function returns a dagster_pandas.DataFrame (the Dagster Type) instead of a pandas.DataFrame
do you happen to have a job that we could use to reproduce? Seems like having an op that reutrns that type isn't quite sufficient to make the error happen
@daniel sorry for the delay. The real root cause seems to be nesting graphs.
Copy code
import dagster
import dagster_pandas
import pandas as pd

def my_op():
    return pd.DataFrame()

def my_graph() -> dagster_pandas.DataFrame:
    df = my_op()
    return df

def my_outer_graph():
    return my_graph()

def my_repo():
    return [my_outer_graph.to_job()]
interestingly, in this simple graph, it also fails even if I change
. The error becomes:
Copy code
Operation name: PipelineExplorerRootQuery

Message: '_TypeHintInferred[pandas.core.frame.DataFrame]'

Path: ["pipelineSnapshotOrError","solidHandles",0,"solid","definition","outputDefinitions",0,"type"]

Locations: [{"line":350,"column":5}]
I will post this same information in the github issue