balabs-kit 0.0.6__py3-none-any.whl → 0.0.8__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.
bakit/__init__.py
CHANGED
bakit/cli.py
CHANGED
|
@@ -132,15 +132,11 @@ def _make_wrapper_command(mod, cmd_name):
|
|
|
132
132
|
return _wrap_tree(cmd)
|
|
133
133
|
|
|
134
134
|
|
|
135
|
-
def _load_scripts_group(
|
|
135
|
+
def _load_scripts_group(pkg_name):
|
|
136
136
|
# Create the group from package name`myproject package`
|
|
137
137
|
grp = click.Group(name=pkg_name)
|
|
138
138
|
|
|
139
|
-
|
|
140
|
-
scripts_pkg = f"{pkg_name}.scripts"
|
|
141
|
-
else:
|
|
142
|
-
scripts_pkg = f"{base_pkg}.{pkg_name}.scripts"
|
|
143
|
-
|
|
139
|
+
scripts_pkg = f"{pkg_name}.scripts"
|
|
144
140
|
try:
|
|
145
141
|
scripts_mod = importlib.import_module(scripts_pkg)
|
|
146
142
|
except ModuleNotFoundError:
|
|
@@ -172,15 +168,10 @@ def _iter_immediate_packages(root_dir):
|
|
|
172
168
|
yield p.name
|
|
173
169
|
|
|
174
170
|
|
|
175
|
-
def autodiscover_and_attach(
|
|
176
|
-
if not base_pkg:
|
|
177
|
-
# If running as a script (python cli.py), fall back to directory name.
|
|
178
|
-
# Prefer running as a module / console script so __package__ is set.
|
|
179
|
-
base_pkg = Path(base_file).resolve().parent.name
|
|
180
|
-
|
|
171
|
+
def autodiscover_and_attach(base_file, cli):
|
|
181
172
|
root_dir = Path(base_file).resolve().parent
|
|
182
173
|
|
|
183
174
|
for pkg_name in _iter_immediate_packages(root_dir):
|
|
184
|
-
grp = _load_scripts_group(
|
|
175
|
+
grp = _load_scripts_group(pkg_name)
|
|
185
176
|
if grp:
|
|
186
177
|
cli.add_command(grp, name=pkg_name)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: balabs-kit
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.8
|
|
4
4
|
Author-email: tsifrer <3967564+tsifrer@users.noreply.github.com>
|
|
5
5
|
License-Expression: Apache-2.0
|
|
6
6
|
Requires-Python: >=3.13
|
|
@@ -12,7 +12,6 @@ Requires-Dist: discord-py>=2.6.4
|
|
|
12
12
|
Requires-Dist: environs>=14.5.0
|
|
13
13
|
Requires-Dist: ipython>=9.8.0
|
|
14
14
|
Requires-Dist: nest-asyncio>=1.6.0
|
|
15
|
-
Requires-Dist: orjson>=3.11.5
|
|
16
15
|
Requires-Dist: sentry-sdk>=2.48.0
|
|
17
16
|
Requires-Dist: statsd>=4.0.1
|
|
18
17
|
Requires-Dist: tortoise-orm>=0.25.1
|
|
@@ -21,6 +20,7 @@ Provides-Extra: arq
|
|
|
21
20
|
Requires-Dist: arq<1.0.0,>=0.26.3; extra == 'arq'
|
|
22
21
|
Requires-Dist: tortoise-plastron>=0.1.1; extra == 'arq'
|
|
23
22
|
Provides-Extra: sanic
|
|
23
|
+
Requires-Dist: orjson>=3.11.5; extra == 'sanic'
|
|
24
24
|
Requires-Dist: sanic-ext>=24.12.0; extra == 'sanic'
|
|
25
25
|
Requires-Dist: sanic>=25.3.0; extra == 'sanic'
|
|
26
26
|
Description-Content-Type: text/markdown
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
bakit/__init__.py,sha256=
|
|
2
|
-
bakit/cli.py,sha256=
|
|
1
|
+
bakit/__init__.py,sha256=XMG_u43ldXqLHrJF_M9xkELRnSAsRgzLyOW4cwXhEew,114
|
|
2
|
+
bakit/cli.py,sha256=5eoyVi1MdI5FcK2_0mms4dZpAPJiakqR87ZIIAUCILo,5532
|
|
3
3
|
bakit/config.py,sha256=32ADsCi2qSwHJCRGU8jXzlRCwLpHZwixWcv_9Vmw6o0,4348
|
|
4
4
|
bakit/init.py,sha256=uzkB22ZcZEC_eC8tGDfiJ_AfRlymVfqGhj7zvyGdoi8,1301
|
|
5
5
|
bakit/settings.py,sha256=F4mA53W63VasDpAXUFDfdw9LA28U6t-4vkIMThy3taI,159
|
|
@@ -21,6 +21,6 @@ bakit/utils/db.py,sha256=aKL20rB8aBxb26wUHmPDIOwcwE46_ypqckcWw_EEu08,1551
|
|
|
21
21
|
bakit/utils/discord.py,sha256=o575uH8DY9o01lp7uxFgxjhs-CfvmQ3lIPE4Vru6Ikk,651
|
|
22
22
|
bakit/utils/metrics.py,sha256=ggQkoTmi8fL_H_cIQrzvrDIp8lGCwGIaB_aMFJs0RXQ,7551
|
|
23
23
|
bakit/utils/sql_helpers.py,sha256=JhgA7WPZQb-LFfjW_fXYRnc2yS0p-kxGzSNaX9cSULE,2046
|
|
24
|
-
balabs_kit-0.0.
|
|
25
|
-
balabs_kit-0.0.
|
|
26
|
-
balabs_kit-0.0.
|
|
24
|
+
balabs_kit-0.0.8.dist-info/METADATA,sha256=-haPAUj2lMz2Qs4G3HcpF-J3AfHmc2pq0cRVXyY3uls,1012
|
|
25
|
+
balabs_kit-0.0.8.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
26
|
+
balabs_kit-0.0.8.dist-info/RECORD,,
|
|
File without changes
|