jupyter-server / enterprise_gateway

A lightweight, multi-tenant, scalable and secure gateway that enables Jupyter Notebooks to share resources across distributed clusters such as Apache Spark, Kubernetes and others.
https://jupyter-enterprise-gateway.readthedocs.io/en/latest/
Other
617 stars 222 forks source link

Add typing hints to session managers and handler #1135

Closed kiersten-stokes closed 2 years ago

kiersten-stokes commented 2 years ago

Fixes #850

Most of these changes are pretty straightforward. The only uncertainty I have is the type hint for the kernel_manager __init__ param for the session managers. I have the type as MappingKernelManager right now. The docstring of the base session manager is listed as SeedingMappingKernelManager, but the RemoteMappingKernelManager is what I see during debug. I split the difference with the common base class MappingKernelManager.

kevin-bates commented 2 years ago

Hi @kiersten-stokes - these changes look good. The SeedingMappingKernelManager was the MappingKernelManager introduced by Jupyter Kernel Gateway. Since we use RemoteMappingKernelManager exclusively within EG, I think it would be best to update all MappingKernelManager type references to RemoteMappingKernelManager as well as the help-string refs of SeedingMappingKernelManager (if you could please). Thank you.

lresende commented 2 years ago

@kiersten-stokes are we still waiting on an update to @kevin-bates comments above or is this ready to merge?

kiersten-stokes commented 2 years ago

@lresende everything from above has been addressed! 🙂