2121# along with this program; if not, see <http://www.gnu.org/licenses/>.
2222############################################################################
2323
24+ from __future__ import annotations
25+
2426import sys
2527import os
2628import re
@@ -428,8 +430,10 @@ def _import(name):
428430 return sys .modules [name ]
429431
430432
431- def get_entry_point (group , name ):
432- # try to find an extension using setuptools entry points
433+ def get_entry_point (group : str , name : str ):
434+ """
435+ Try to find an extension using entry points.
436+ """
433437 if pkg_resources is None :
434438 return None
435439 entry_points = tuple (pkg_resources .iter_entry_points (group , name ))
@@ -440,7 +444,7 @@ def get_entry_point(group, name):
440444 return entry_points [0 ]
441445
442446
443- def get_camera_module (name ):
447+ def get_camera_module (name : str ):
444448 """Returns the python module for the given camera type"""
445449 entry_point = get_entry_point ("Lima_tango_camera" , name )
446450 if entry_point is None :
@@ -450,7 +454,7 @@ def get_camera_module(name):
450454 return entry_point .load ()
451455
452456
453- def get_plugin_module (name ):
457+ def get_plugin_module (name : str ):
454458 """Returns the python module for the given plugin type"""
455459 entry_point = get_entry_point ("Lima_tango_plugin" , name )
456460 if entry_point is None :
0 commit comments