Skip to content

Commit

Permalink
polish(incrementalDelivery): filter function is always passed a path
Browse files Browse the repository at this point in the history
  • Loading branch information
Cito committed Feb 11, 2024
1 parent 0c843f9 commit 04c4dd1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/graphql/execution/execute.py
Original file line number Diff line number Diff line change
Expand Up @@ -1866,9 +1866,9 @@ async def execute_stream_iterator(
field_modes: List[FieldNode],
info: GraphQLResolveInfo,
item_type: GraphQLOutputType,
path: Optional[Path],
label: Optional[str],
parent_context: Optional[AsyncPayloadRecord],
path: Path,
label: Optional[str] = None,
parent_context: Optional[AsyncPayloadRecord] = None,
) -> None:
"""Execute stream iterator."""
index = initial_index
Expand Down Expand Up @@ -1912,11 +1912,11 @@ async def execute_stream_iterator(

def filter_subsequent_payloads(
self,
null_path: Optional[Path] = None,
null_path: Path,
current_async_record: Optional[AsyncPayloadRecord] = None,
) -> None:
"""Filter subsequent payloads."""
null_path_list = null_path.as_list() if null_path else []
null_path_list = null_path.as_list()
for async_record in list(self.subsequent_payloads):
if async_record is current_async_record:
# don't remove payload from where error originates
Expand Down

0 comments on commit 04c4dd1

Please sign in to comment.