Typing fixes for the stream controller (#2540)
* work in progress
* mypy fixes for streams.py
* Fix typos
* Another typo
* PR review changes
* Fixes after merge conflicts
* Revert unnecessary change
* Remove unnecessary comments
* More changes post conflict resolve
* Remove exclude
* organise imports
* Updates post other commits
* Catch possible no stream details
* Updates for new commits
* Fix type error post conflict merge
* Simplify
* Simplify with type hints to config controller
* Typing adjustments
* Fix missing return type
* improve code clarity
* switch to assert for none check
* Fix return type mypy error
* Revert unnecessary bracket
* Use default parameter