Skip to content

Fix none error on session close#440

Merged
mjh1 merged 1 commit intomainfrom
mh/close-none
Feb 12, 2026
Merged

Fix none error on session close#440
mjh1 merged 1 commit intomainfrom
mh/close-none

Conversation

@mjh1
Copy link
Copy Markdown
Contributor

@mjh1 mjh1 commented Feb 11, 2026

The culprit ended up being:

await super().stop()

This was not an async function so await was returning object NoneType can't be used in 'await' expression

@mjh1 mjh1 force-pushed the mh/close-none branch 2 times, most recently from e6e09d3 to bd62873 Compare February 11, 2026 12:22
@mjh1 mjh1 requested a review from leszko February 11, 2026 12:22
self.frame_processor.stop()

await super().stop()
# MediaStreamTrack.stop() may be sync or async depending on aiortc version
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we instead of handling both aiortc versions, jus pin to the specific aiortc version?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if we want to pin the exact version just for this? We have aiortc>=1.13.0 set right now. Is there some static analysis tool we can run to check it? Anyways, I've removed the extra check and just made it work with the version we're on.

@mjh1 mjh1 requested a review from leszko February 11, 2026 18:36
# This determines whether we wait for video frames or generate immediately.
self._video_mode = (initial_parameters or {}).get("input_mode") == "video"

# Pipeline chaining support (local mode only)
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I verified this works for remote inference 👍

@mjh1 mjh1 merged commit 77d0f3b into main Feb 12, 2026
6 checks passed
@mjh1 mjh1 deleted the mh/close-none branch February 12, 2026 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants