winipedia-utils 0.1.10__py3-none-any.whl → 0.1.12__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.
@@ -84,3 +84,20 @@ def get_all_functions_from_module(module: ModuleType | str) -> list[Callable[...
84
84
  ]
85
85
  # sort by definition order
86
86
  return sorted(funcs, key=get_def_line)
87
+
88
+
89
+ def unwrap_method(method: Any) -> Callable[..., Any] | Any:
90
+ """Unwrap a method to its underlying function.
91
+
92
+ Args:
93
+ method: The method to unwrap
94
+
95
+ Returns:
96
+ The underlying function of the method
97
+
98
+ """
99
+ if isinstance(method, (staticmethod, classmethod)):
100
+ method = method.__func__
101
+ if isinstance(method, property):
102
+ method = method.fget
103
+ return inspect.unwrap(method)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: winipedia-utils
3
- Version: 0.1.10
3
+ Version: 0.1.12
4
4
  Summary: A package with many utility functions
5
5
  License: MIT
6
6
  Author: Winipedia
@@ -25,7 +25,7 @@ winipedia_utils/logging/config.py,sha256=NAXCxVRkEfkf119HCg1zrdP1l37DW4cFDHvKrBE
25
25
  winipedia_utils/logging/logger.py,sha256=tCcUwAVLVr3Bec7_i-SoKvBPNCJSEmyuvBW2gbqjPMk,727
26
26
  winipedia_utils/modules/__init__.py,sha256=e3CFaC3FhK4ibknFOv1bqOZxA7XeVwmLqWX7oajUm78,51
27
27
  winipedia_utils/modules/class_.py,sha256=RDjal6QYYs9z81DT1mIFrnEhQ9vgN2tCAYN1WWnN24Y,2462
28
- winipedia_utils/modules/function.py,sha256=Qn1OPV5dwO-7f3a0f0RpWcrH-E9teGPwldRtwbFYzRM,2551
28
+ winipedia_utils/modules/function.py,sha256=cHLGiD7huPdfwUDdI0IlbB_Pd4woWGgbyvrsjivHBpc,2987
29
29
  winipedia_utils/modules/module.py,sha256=mxaAsRl02CAq_bTW2HsmzRWoyC9jKNM8Q4xdgdQlgd0,12719
30
30
  winipedia_utils/modules/package.py,sha256=kCm4pXQdllafo-2dmWZTvaAqRruzh3iF4hseHlCmTlU,12605
31
31
  winipedia_utils/oop/__init__.py,sha256=wGjsVwLbTVEQWOfDJvN9nlvC-3NmAi8Doc2xIrm6e78,47
@@ -61,7 +61,7 @@ winipedia_utils/testing/tests/base/utils/utils.py,sha256=dUPDrgAxlfREQb33zz23Mfz
61
61
  winipedia_utils/testing/tests/conftest.py,sha256=8RounBlI8Jq1aLaLNpv84MW4ne8Qq0aavQextDOp5ng,920
62
62
  winipedia_utils/text/__init__.py,sha256=j2bwtK6kyeHI6SnoBjpRju0C1W2n2paXBDlNjNtaUxA,48
63
63
  winipedia_utils/text/string.py,sha256=1jbBftlgxffGgSlPnQh3aRPIr8XekEwpSenjFCW6JyM,3478
64
- winipedia_utils-0.1.10.dist-info/LICENSE,sha256=3PrKJ2CWNrnyyHaC_r0wPDSukVWgmjOxHr__eQVH7cw,1087
65
- winipedia_utils-0.1.10.dist-info/METADATA,sha256=-jB1-lzknCwX6DQlK-fiAt8jkwg86Z5xlzHa5OyQ6CA,12385
66
- winipedia_utils-0.1.10.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
67
- winipedia_utils-0.1.10.dist-info/RECORD,,
64
+ winipedia_utils-0.1.12.dist-info/LICENSE,sha256=3PrKJ2CWNrnyyHaC_r0wPDSukVWgmjOxHr__eQVH7cw,1087
65
+ winipedia_utils-0.1.12.dist-info/METADATA,sha256=u2sgf1gcfep7whVI1VvB9GMrkXyvX2rNl_FxzxIQ5Zs,12385
66
+ winipedia_utils-0.1.12.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
67
+ winipedia_utils-0.1.12.dist-info/RECORD,,