Skip to content

Commit

Permalink
add pools to graphs
Browse files Browse the repository at this point in the history
  • Loading branch information
prha committed Jan 8, 2025
1 parent a5aa2cf commit adaea1b
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions js_modules/dagster-ui/packages/ui-core/src/graphql/types.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,7 @@ class GrapheneISolidDefinition(graphene.Interface):
input_definitions = non_null_list(GrapheneInputDefinition)
output_definitions = non_null_list(GrapheneOutputDefinition)
assetNodes = non_null_list("dagster_graphql.schema.asset_graph.GrapheneAssetNode")
pools = non_null_list(graphene.String)

class Meta:
name = "ISolidDefinition"
Expand Down Expand Up @@ -464,6 +465,13 @@ def resolve_assetNodes(self, graphene_info: ResolveInfo) -> Sequence["GrapheneAs
for remote_node in remote_nodes
]

def resolve_pools(self, _graphene_info) -> Sequence[str]:
if isinstance(self._solid_def_snap, OpDefSnap):
return [self._solid_def_snap.pool]
if isinstance(self._solid_def_snap, GraphDefSnap):
return list(self._solid_def_snap.pools)
return []


class GrapheneSolidDefinition(graphene.ObjectType, ISolidDefinitionMixin):
config_field = graphene.Field(GrapheneConfigTypeField)
Expand Down

0 comments on commit adaea1b

Please sign in to comment.