ka-uts-com 1.0.0.240823__py3-none-any.whl → 2.0.0.250407__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. build/lib/ka_uts_com/__version__.py +1 -1
  2. build/lib/ka_uts_com/base/app_.py +50 -0
  3. build/lib/ka_uts_com/base/cfg_.py +35 -0
  4. build/lib/ka_uts_com/base/exit_.py +37 -0
  5. build/lib/ka_uts_com/base/log_.py +131 -0
  6. build/lib/ka_uts_com/com.py +91 -192
  7. build/lib/ka_uts_com/data/log.std.yml +107 -0
  8. build/lib/ka_uts_com/data/{log.standard.yml → log.usr.yml} +47 -27
  9. build/lib/ka_uts_com/decorators/dec.py +13 -0
  10. build/lib/ka_uts_com/fnc.py +29 -24
  11. build/lib/ka_uts_com/ioc/jinja2_.py +42 -0
  12. build/lib/ka_uts_com/ioc/yaml_.py +30 -0
  13. build/lib/ka_uts_com/log.py +48 -25
  14. build/lib/ka_uts_com/timer.py +24 -27
  15. build/lib/ka_uts_com/utils/aoeqstmt.py +37 -0
  16. build/lib/ka_uts_com/{date.py → utils/date.py} +4 -4
  17. build/lib/ka_uts_com/utils/doeq.py +99 -0
  18. build/lib/ka_uts_com/utils/pacmod.py +123 -0
  19. build/lib/ka_uts_com/{str.py → utils/str.py} +36 -39
  20. ka_uts_com/__version__.py +1 -1
  21. ka_uts_com/base/app_.py +50 -0
  22. ka_uts_com/base/cfg_.py +35 -0
  23. ka_uts_com/base/exit_.py +37 -0
  24. ka_uts_com/base/log_.py +131 -0
  25. ka_uts_com/com.py +91 -192
  26. ka_uts_com/data/log.std.yml +107 -0
  27. ka_uts_com/data/{log.standard.yml → log.usr.yml} +47 -27
  28. ka_uts_com/decorators/dec.py +13 -0
  29. ka_uts_com/fnc.py +29 -24
  30. ka_uts_com/ioc/jinja2_.py +42 -0
  31. ka_uts_com/ioc/yaml_.py +30 -0
  32. ka_uts_com/log.py +48 -25
  33. ka_uts_com/timer.py +24 -27
  34. ka_uts_com/utils/aoeqstmt.py +37 -0
  35. ka_uts_com/{date.py → utils/date.py} +4 -4
  36. ka_uts_com/utils/doeq.py +99 -0
  37. ka_uts_com/utils/pacmod.py +123 -0
  38. ka_uts_com/{str.py → utils/str.py} +36 -39
  39. ka_uts_com-2.0.0.250407.dist-info/METADATA +1611 -0
  40. ka_uts_com-2.0.0.250407.dist-info/RECORD +49 -0
  41. {ka_uts_com-1.0.0.240823.dist-info → ka_uts_com-2.0.0.250407.dist-info}/WHEEL +1 -1
  42. {ka_uts_com-1.0.0.240823.dist-info → ka_uts_com-2.0.0.250407.dist-info/licenses}/LICENSE.txt +1 -2
  43. build/lib/dist/ka_uts_com-1.0.0.240823-py3-none-any.whl +0 -0
  44. build/lib/dist/ka_uts_com-1.0.0.240823.tar.gz +0 -0
  45. build/lib/ka_uts_com/aeq.py +0 -87
  46. build/lib/ka_uts_com/argv.py +0 -49
  47. build/lib/ka_uts_com/data/log.personal.yml +0 -93
  48. build/lib/ka_uts_com/ioc.py +0 -57
  49. build/lib/ka_uts_com/pacmod.py +0 -111
  50. dist/ka_uts_com-1.0.0.240823-py3-none-any.whl +0 -0
  51. dist/ka_uts_com-1.0.0.240823.tar.gz +0 -0
  52. ka_uts_com/aeq.py +0 -87
  53. ka_uts_com/argv.py +0 -49
  54. ka_uts_com/data/log.personal.yml +0 -93
  55. ka_uts_com/ioc.py +0 -57
  56. ka_uts_com/pacmod.py +0 -111
  57. ka_uts_com-1.0.0.240823.dist-info/METADATA +0 -943
  58. ka_uts_com-1.0.0.240823.dist-info/RECORD +0 -41
  59. {ka_uts_com-1.0.0.240823.dist-info → ka_uts_com-2.0.0.250407.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,30 @@
1
+ # coding=utf-8
2
+ import yaml
3
+
4
+ from typing import Any
5
+ TyAny = Any
6
+ TyArr = list[Any]
7
+ TyDic = dict[Any, Any]
8
+
9
+ TnAny = None | Any
10
+
11
+
12
+ class Yaml_:
13
+ """ Manage Object to Yaml file affilitation
14
+ """
15
+ @staticmethod
16
+ def read(path: str, log) -> TnAny:
17
+ try:
18
+ with open(path) as fd:
19
+ # The Loader parameter handles the conversion from YAML
20
+ # scalar values to Python object format
21
+ obj = yaml.load(fd, Loader=yaml.SafeLoader)
22
+ return obj
23
+ except FileNotFoundError:
24
+ log.error(f"No such file or directory: {path}")
25
+ except IOError:
26
+ # if Com.Log is not None:
27
+ # fnc_error = Com.Log.error
28
+ # fnc_error(exc, exc_info=True)
29
+ raise
30
+ return None
ka_uts_com/log.py CHANGED
@@ -1,6 +1,6 @@
1
1
  from ka_uts_com.com import Com
2
-
3
- from typing import Any, Callable
2
+ from typing import Any
3
+ TyDic = dict[Any, Any]
4
4
 
5
5
 
6
6
  class Log:
@@ -8,56 +8,79 @@ class Log:
8
8
  """
9
9
  class Eq:
10
10
 
11
- @staticmethod
12
- def sh(key: Any, value: Any) -> str:
13
- """ Show Key, Value as Equate
14
- """
15
- return f"{key} = {value}"
11
+ @classmethod
12
+ def error(cls, key: Any, value: Any) -> None:
13
+ Log.error(f"{key} = {value}", stacklevel=3)
14
+
15
+ @classmethod
16
+ def warning(cls, key: Any, value: Any) -> None:
17
+ Log.warning(f"{key} = {value}", stacklevel=3)
18
+
19
+ @classmethod
20
+ def info(cls, key: Any, value: Any) -> None:
21
+ Log.info(f"{key} = {value}", stacklevel=3)
22
+
23
+ @classmethod
24
+ def log(cls, key: Any, value: Any) -> None:
25
+ Log.log(f"{key} = {value}", stacklevel=3)
16
26
 
17
27
  @classmethod
18
28
  def debug(cls, key: Any, value: Any) -> None:
19
- Log.debug(cls.sh(key, value), stacklevel=3)
29
+ Log.debug(f"{key} = {value}", stacklevel=3)
30
+
31
+ class Dic:
20
32
 
21
33
  @classmethod
22
- def error(cls, key: Any, value: Any) -> None:
23
- Log.error(cls.sh(key, value), stacklevel=3)
34
+ def debug(cls, dic: TyDic) -> None:
35
+ for key, value in dic.items():
36
+ Log.debug(f"{key} = {value}", stacklevel=3)
24
37
 
25
38
  @classmethod
26
- def info(cls, key: Any, value: Any) -> None:
27
- Log.info(cls.sh(key, value), stacklevel=3)
39
+ def error(cls, dic: TyDic) -> None:
40
+ for key, value in dic.items():
41
+ Log.error(f"{key} = {value}", stacklevel=3)
28
42
 
29
43
  @classmethod
30
- def warning(cls, key: Any, value: Any) -> None:
31
- Log.warning(cls.sh(key, value), stacklevel=3)
44
+ def info(cls, dic: TyDic) -> None:
45
+ for key, value in dic.items():
46
+ Log.info(f"{key} = {value}", stacklevel=3)
47
+
48
+ @classmethod
49
+ def warning(cls, dic: TyDic) -> None:
50
+ for key, value in dic.items():
51
+ Log.warning(f"{key} = {value}", stacklevel=3)
32
52
 
33
53
  @staticmethod
34
- def debug(*args, **kwargs) -> None:
54
+ def error(*args, **kwargs) -> None:
35
55
  if kwargs is None:
36
56
  kwargs = {}
37
57
  kwargs['stacklevel'] = kwargs.get('stacklevel', 2)
38
- fnc_debug: Callable = Com.Log.debug
39
- fnc_debug(*args, **kwargs)
58
+ Com.Log.error(*args, **kwargs)
40
59
 
41
60
  @staticmethod
42
- def error(*args, **kwargs) -> None:
61
+ def warning(*args, **kwargs) -> None:
43
62
  if kwargs is None:
44
63
  kwargs = {}
45
64
  kwargs['stacklevel'] = kwargs.get('stacklevel', 2)
46
- fnc_error: Callable = Com.Log.error
47
- fnc_error(*args, **kwargs)
65
+ Com.Log.warning(*args, **kwargs)
48
66
 
49
67
  @staticmethod
50
68
  def info(*args, **kwargs) -> None:
51
69
  if kwargs is None:
52
70
  kwargs = {}
53
71
  kwargs['stacklevel'] = kwargs.get('stacklevel', 2)
54
- fnc_info: Callable = Com.Log.info
55
- fnc_info(*args, **kwargs)
72
+ Com.Log.info(*args, **kwargs)
56
73
 
57
74
  @staticmethod
58
- def warning(*args, **kwargs) -> None:
75
+ def log(*args, **kwargs) -> None:
76
+ if kwargs is None:
77
+ kwargs = {}
78
+ kwargs['stacklevel'] = kwargs.get('stacklevel', 2)
79
+ Com.Log.log(*args, **kwargs)
80
+
81
+ @staticmethod
82
+ def debug(*args, **kwargs) -> None:
59
83
  if kwargs is None:
60
84
  kwargs = {}
61
85
  kwargs['stacklevel'] = kwargs.get('stacklevel', 2)
62
- fnc_warning: Callable = Com.Log.warning
63
- fnc_warning(*args, **kwargs)
86
+ Com.Log.debug(*args, **kwargs)
ka_uts_com/timer.py CHANGED
@@ -1,25 +1,22 @@
1
1
  # coding=utf-8
2
-
3
2
  from datetime import datetime
4
3
 
5
4
  from ka_uts_com.com import Com
6
5
  from ka_uts_com.log import Log
7
6
 
8
- from typing import Any, List
9
-
10
- T_Any = Any
11
- T_Arr = List[Any]
12
- T_Str = str
13
-
14
- TN_Any = None | T_Any
15
- TN_Str = None | T_Str
7
+ from typing import Any
8
+ TyAny = Any
9
+ TyArr = list[Any]
10
+ TyDic = dict[Any, Any]
11
+ TyStr = str
12
+ TnAny = None | TyAny
13
+ TnStr = None | TyStr
16
14
 
17
15
 
18
16
  class Timestamp:
19
17
 
20
18
  @staticmethod
21
- def sh_elapse_time_sec(
22
- end: Any, start: TN_Any) -> TN_Any:
19
+ def sh_elapse_time_sec(end: Any, start: TnAny) -> TnAny:
23
20
  if start is None:
24
21
  return None
25
22
  return end.timestamp()-start.timestamp()
@@ -29,12 +26,15 @@ class Timer:
29
26
  """ Timer Management
30
27
  """
31
28
  @staticmethod
32
- def sh_task_id(
33
- class_id: Any, parms: TN_Any, separator: T_Str) -> T_Str:
34
- """ start Timer
29
+ def sh_task_id(d_pacmod: TyDic, class_id: TyAny, parms: TnAny, sep: TyStr) -> TyStr:
30
+ """
31
+ Show task id, which is created by the concationation of the following items:
32
+ package, module, class_name and parms if they are defined; the items package
33
+ and module are get from the package-module directory; the item class_name is
34
+ the class_id if its a string, otherwise the attribute __qualname__ is used.
35
35
  """
36
- package = Com.pacmod_curr['package']
37
- module = Com.pacmod_curr['module']
36
+ package = d_pacmod.get('package')
37
+ module = d_pacmod.get('module')
38
38
  if isinstance(class_id, str):
39
39
  class_name = class_id
40
40
  else:
@@ -43,28 +43,25 @@ class Timer:
43
43
  parms = ""
44
44
  else:
45
45
  parms = f" {parms}"
46
- arr: T_Arr = []
46
+ arr: TyArr = []
47
47
  for item in [package, module, class_name, parms]:
48
48
  if not item:
49
49
  continue
50
50
  arr.append(item)
51
- return separator.join(arr)
51
+ return sep.join(arr)
52
52
 
53
53
  @classmethod
54
- def start(
55
- cls, class_id: T_Any,
56
- parms: TN_Any = None, separator: T_Str = ".") -> None:
57
- """ start Timer
54
+ def start(cls, class_id: TyAny, parms: TnAny = None, sep: TyStr = ".") -> None:
55
+ """ Start Timer
58
56
  """
59
- task_id = cls.sh_task_id(class_id, parms, separator)
57
+ task_id = cls.sh_task_id(Com.d_app_pacmod, class_id, parms, sep)
60
58
  Com.d_timer[task_id] = datetime.now()
61
59
 
62
60
  @classmethod
63
- def end(cls, class_id: T_Any,
64
- parms: TN_Any = None, separator: T_Str = ".") -> None:
65
- """ end Timer
61
+ def end(cls, class_id: TyAny, parms: TnAny = None, sep: TyStr = ".") -> None:
62
+ """ End Timer
66
63
  """
67
- task_id = cls.sh_task_id(class_id, parms, separator)
64
+ task_id = cls.sh_task_id(Com.d_app_pacmod, class_id, parms, sep)
68
65
  start = Com.d_timer.get(task_id)
69
66
  end = datetime.now()
70
67
  elapse_time_sec = Timestamp.sh_elapse_time_sec(end, start)
@@ -0,0 +1,37 @@
1
+ # coding=utf-8
2
+ from ka_uts_com.utils.doeq import DoEq
3
+
4
+ from typing import Any
5
+ TyArr = list[Any]
6
+ TyDic = dict[Any, Any]
7
+
8
+ TnArr = None | TyArr
9
+ TnDic = None | TyDic
10
+ TnStr = None | str
11
+
12
+
13
+ class AoEqStmt:
14
+ """ Dictionary of Equates
15
+ """
16
+ @staticmethod
17
+ def init_d_eq(a_eqstmt: TyArr) -> TyDic:
18
+ d_eq = {}
19
+ for s_eq in a_eqstmt[1:]:
20
+ a_eq = s_eq.split('=')
21
+ if len(a_eq) == 1:
22
+ d_eq['cmd'] = a_eq[0]
23
+ else:
24
+ d_eq[a_eq[0]] = a_eq[1]
25
+ d_eq[a_eq[0]] = a_eq[1]
26
+ return d_eq
27
+
28
+ @classmethod
29
+ def sh_d_eq(cls, a_eqstmt: TyArr, **kwargs) -> TyDic:
30
+ """ show equates dictionary
31
+ """
32
+ d_parms: TnDic = kwargs.get('d_parms')
33
+ _sh_prof = kwargs.get('sh_prof')
34
+ d_eq: TyDic = cls.init_d_eq(a_eqstmt)
35
+ d_eq_new: TyDic = DoEq.verify(d_eq, d_parms)
36
+ DoEq._set_sh_prof(d_eq_new, _sh_prof)
37
+ return d_eq_new
@@ -1,15 +1,15 @@
1
1
  from datetime import datetime
2
2
  from datetime import date
3
3
 
4
- T_Date = date
5
- TN_Date = None | T_Date
6
- TN_Str = None | str
4
+ TyDate = date
5
+ TnDate = None | TyDate
6
+ TnStr = None | str
7
7
 
8
8
 
9
9
  class Date:
10
10
 
11
11
  @staticmethod
12
- def sh(datestring: TN_Str, fmt: str) -> TN_Date:
12
+ def sh(datestring: TnStr, fmt: str) -> TnDate:
13
13
  if not datestring:
14
14
  return None
15
15
  return datetime.strptime(datestring, fmt).date()
@@ -0,0 +1,99 @@
1
+ # coding=utf-8
2
+ from collections.abc import Callable
3
+ from typing import Any
4
+
5
+ # from ka_uts_com.utils.pacmod import PacMod
6
+ from ka_uts_com.utils.str import Str
7
+ from ka_uts_com.utils.date import Date
8
+
9
+
10
+ TyArr = list[Any]
11
+ TyCall = Callable[..., Any]
12
+ TyDic = dict[Any, Any]
13
+ TyStr = str
14
+
15
+ TnArr = None | TyArr
16
+ TnDic = None | TyDic
17
+ TnStr = None | TyStr
18
+
19
+
20
+ class DoEq:
21
+ """ Manage Commandline Arguments
22
+ """
23
+ @classmethod
24
+ def sh_value(cls, key: str, value: Any, d_valid_parms: TnDic) -> Any:
25
+
26
+ # print(f"key = {key}, type(key) = {type(key)}")
27
+ # print(f"value = {value}, type(value) = {type(value)}")
28
+ if not d_valid_parms:
29
+ return value
30
+ _type: TnStr = d_valid_parms.get(key)
31
+ # print(f"_type = {_type}")
32
+ if not _type:
33
+ return value
34
+ if isinstance(_type, str):
35
+ match _type:
36
+ case 'int':
37
+ value = int(value)
38
+ case 'bool':
39
+ value = Str.sh_boolean(value)
40
+ case 'dict':
41
+ value = Str.sh_dic(value)
42
+ case 'list':
43
+ value = Str.sh_arr(value)
44
+ case '%Y-%m-%d':
45
+ value = Date.sh(value, _type)
46
+ case '_':
47
+ match _type[0]:
48
+ case '[', '{':
49
+ _obj = Str.sh_dic(_type)
50
+ if value not in _obj:
51
+ msg = (f"parameter={key} value={value} is invalid; "
52
+ f"valid values are={_obj}")
53
+ raise Exception(msg)
54
+
55
+ # print(f"value = {value}, type(value) = {type(value)}")
56
+ return value
57
+
58
+ # @staticmethod
59
+ # def _set_d_pacmod(d_eq: TyDic, root_cls) -> None:
60
+ # """ set current pacmod dictionary
61
+ # """
62
+ # tenant = d_eq.get('tenant')
63
+ # d_eq['d_pacmod'] = PacMod.sh_d_pacmod(root_cls, tenant)
64
+
65
+ @staticmethod
66
+ def _set_sh_prof(d_eq: TyDic, sh_prof: TyCall | Any) -> None:
67
+ """ set current pacmod dictionary
68
+ """
69
+ if callable(sh_prof):
70
+ d_eq['sh_prof'] = sh_prof()
71
+ else:
72
+ d_eq['sh_prof'] = sh_prof
73
+
74
+ @classmethod
75
+ def verify(cls, d_eq: TyDic, d_parms: TnDic) -> TyDic:
76
+ if d_parms is None:
77
+ return d_eq
78
+ if 'cmd' in d_eq:
79
+ _d_valid_parms = d_parms
80
+ _cmd = d_eq['cmd']
81
+ _valid_commands = list(d_parms.keys())
82
+ if _cmd not in _valid_commands:
83
+ msg = (f"Wrong command: {_cmd}; "
84
+ f"valid commands are: {_valid_commands}")
85
+ raise Exception(msg)
86
+ _d_valid_parms = d_parms[_cmd]
87
+ else:
88
+ _d_valid_parms = d_parms
89
+ if _d_valid_parms is None:
90
+ return d_eq
91
+
92
+ d_eq_new = {}
93
+ for key, value in d_eq.items():
94
+ if key not in _d_valid_parms:
95
+ msg = (f"Wrong parameter: {key}; "
96
+ f"valid parameters are: {_d_valid_parms}")
97
+ raise Exception(msg)
98
+ d_eq_new[key] = cls.sh_value(key, value, _d_valid_parms)
99
+ return d_eq_new
@@ -0,0 +1,123 @@
1
+ # coding=utf-8
2
+ from typing import Any
3
+
4
+ from os import path as os_path
5
+ # import pkg_resources
6
+ import importlib.resources as resources
7
+
8
+ TyArr = list[Any]
9
+ TyDic = dict[Any, Any]
10
+ TyPath = str
11
+
12
+ TnDic = None | TyDic
13
+ TnPath = None | TyPath
14
+
15
+
16
+ class PacMod:
17
+ """ Package Module Management
18
+ """
19
+ @staticmethod
20
+ def sh_d_pacmod(cls) -> TyDic:
21
+ """ Show Pacmod Dictionary
22
+ """
23
+ a_pacmod: TyArr = cls.__module__.split(".")
24
+ return {'package': a_pacmod[0], 'module': a_pacmod[1]}
25
+
26
+ @staticmethod
27
+ def sh_path_module_yaml(d_pacmod: TyDic) -> str:
28
+ """ show directory
29
+ """
30
+ # def sh_path_cfg_yaml(d_pacmod: TyDic) -> str:
31
+ package = d_pacmod['package']
32
+ module = d_pacmod['module']
33
+ filename = f"{module}.yml"
34
+ file = resources.files(f"{package}.data")
35
+ print("sh_path_module_yaml files = {files}")
36
+ path: TyPath = file.joinpath(filename)
37
+ return path
38
+
39
+ @staticmethod
40
+ def sh_path_keys(
41
+ d_pacmod: TyDic, filename: str = 'keys.yml') -> TyPath:
42
+ """ show directory
43
+ """
44
+ package = d_pacmod['package']
45
+ files = resources.files(f"{package}.data")
46
+ print("sh_path_keys files = {files}")
47
+ path: TyPath = files.joinpath(filename)
48
+ return path
49
+
50
+ # @staticmethod
51
+ # def sh_path_log_cfg(com) -> TyPath:
52
+ # """ show directory
53
+ # """
54
+ # package = com.d_app_pacmod['package']
55
+ # path = resources.files(package).joinpath(f"data/log.{com.log_type}.yml")
56
+ # if path.is_file():
57
+ # return path
58
+ # package = com.d_com_pacmod['package']
59
+ # path = resources.files(package).joinpath(f"data/log.{com.log_type}.yml")
60
+ # if path.is_file():
61
+ # return path
62
+ # raise ModuleNotFoundError
63
+
64
+ @staticmethod
65
+ def sh_path_cfg(com) -> TyPath:
66
+ """ show directory
67
+ """
68
+ filename = 'cfg.yml'
69
+ package = com.d_app_pacmod['package']
70
+ files = resources.files(f"{package}.data")
71
+ print(f"sh_path_cfg files = {files}")
72
+ path: TyPath = files.joinpath(filename)
73
+ return path
74
+
75
+ # @staticmethod
76
+ # def sh_path_type(d_pacmod: TyDic, type_: str) -> str:
77
+ # """ show Data File Path
78
+ # """
79
+ # # def sh_pacmod_type(d_pacmod: TyDic, type_: str) -> str:
80
+ # package = d_pacmod['package']
81
+ # module = d_pacmod['module']
82
+ # return f"/data/{package}/{module}/{type_}"
83
+
84
+ # @classmethod
85
+ # def sh_file_path(
86
+ # cls, d_pacmod: TyDic, type_: str, suffix: str,
87
+ # pid: Any, ts: Any, **kwargs) -> str:
88
+ # """ show type specific path
89
+ # """
90
+ # filename_ = kwargs.get('filename', type_)
91
+ # sw_run_pid_ts = kwargs.get('sw_run_pid_ts', True)
92
+ # if sw_run_pid_ts is None:
93
+ # sw_run_pid_ts = True
94
+ #
95
+ # _dir: str = cls.sh_pacmod_type(d_pacmod, type_)
96
+ # if sw_run_pid_ts:
97
+ # file_path = os_path.join(
98
+ # _dir, f"{filename_}_{pid}_{ts}.{suffix}")
99
+ # else:
100
+ # file_path = os_path.join(_dir, f"{filename_}.{suffix}")
101
+ # return file_path
102
+
103
+ @staticmethod
104
+ def sh_dir_type(com, type_: str) -> str:
105
+ """Show run_dir
106
+ """
107
+ dir_dat: str = com.dir_dat
108
+ tenant: str = com.tenant
109
+ package: str = com.d_app_pacmod['package']
110
+ module: str = com.d_app_pacmod['module']
111
+ if not tenant:
112
+ return f"{dir_dat}/{tenant}/{package}/{module}/{type_}"
113
+ else:
114
+ return f"{dir_dat}/{package}/{module}/{type_}"
115
+
116
+ @classmethod
117
+ def sh_path_pattern(
118
+ cls, com, filename, type_: str, suffix: str) -> str:
119
+ """ show type specific path
120
+ """
121
+ _dir: str = cls.sh_dir_type(com, type_)
122
+ path: TyPath = os_path.join(_dir, f"{filename}*.{suffix}")
123
+ return path