New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop calling handle_demand after end of stream #568
Conversation
This reverts commit dd01b9e.
e15599e
to
89614d4
Compare
when action not in [:latency, :notify_parent] do | ||
raise ActionError, action: action, reason: {:invalid_callback, :handle_init} | ||
def handle_action(action, callback, params, state) do | ||
state = Map.update!(state, :callback_depth_counter, &(&1 + 1)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of that, I'd set a handling_callback?
flag in the callback handler
@@ -25,6 +25,9 @@ defmodule Membrane.Core.Element.ActionHandlerTest do | |||
playback: :stopped, | |||
synchronization: %{clock: nil, parent_clock: nil}, | |||
delayed_demands: MapSet.new(), | |||
callback_depth_counter: 0, | |||
pads_to_snapshot: MapSet.new(), | |||
pads_to_snapshot: MapSet.new(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pads_to_snapshot: MapSet.new(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bump
94ba8e4
to
9d339b8
Compare
reraise e, __STACKTRACE__ | ||
end | ||
end) | ||
old_handling_action? = state.handling_action? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
old_handling_action? = state.handling_action? | |
was_handling_action? = state.handling_action? |
@@ -25,6 +25,9 @@ defmodule Membrane.Core.Element.ActionHandlerTest do | |||
playback: :stopped, | |||
synchronization: %{clock: nil, parent_clock: nil}, | |||
delayed_demands: MapSet.new(), | |||
callback_depth_counter: 0, | |||
pads_to_snapshot: MapSet.new(), | |||
pads_to_snapshot: MapSet.new(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bump
Related Jira ticket: https://membraneframework.atlassian.net/browse/MC-204