kaqing 1.98.92__py3-none-any.whl → 1.98.94__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.
Potentially problematic release.
This version of kaqing might be problematic. Click here for more details.
- adam/commands/bash.py +1 -1
- adam/commands/shell.py +33 -0
- adam/commands/user_entry.py +0 -1
- adam/repl.py +5 -0
- adam/repl_commands.py +2 -1
- adam/version.py +1 -1
- {kaqing-1.98.92.dist-info → kaqing-1.98.94.dist-info}/METADATA +1 -1
- {kaqing-1.98.92.dist-info → kaqing-1.98.94.dist-info}/RECORD +11 -10
- {kaqing-1.98.92.dist-info → kaqing-1.98.94.dist-info}/WHEEL +0 -0
- {kaqing-1.98.92.dist-info → kaqing-1.98.94.dist-info}/entry_points.txt +0 -0
- {kaqing-1.98.92.dist-info → kaqing-1.98.94.dist-info}/top_level.txt +0 -0
adam/commands/bash.py
CHANGED
adam/commands/shell.py
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import os
|
|
2
|
+
|
|
3
|
+
from adam.commands.command import Command
|
|
4
|
+
from adam.repl_state import ReplState
|
|
5
|
+
|
|
6
|
+
class Shell(Command):
|
|
7
|
+
COMMAND = ':sh'
|
|
8
|
+
|
|
9
|
+
# the singleton pattern
|
|
10
|
+
def __new__(cls, *args, **kwargs):
|
|
11
|
+
if not hasattr(cls, 'instance'): cls.instance = super(Shell, cls).__new__(cls)
|
|
12
|
+
|
|
13
|
+
return cls.instance
|
|
14
|
+
|
|
15
|
+
def __init__(self, successor: Command=None):
|
|
16
|
+
super().__init__(successor)
|
|
17
|
+
|
|
18
|
+
def command(self):
|
|
19
|
+
return Shell.COMMAND
|
|
20
|
+
|
|
21
|
+
def run(self, cmd: str, s0: ReplState):
|
|
22
|
+
if not(args := self.args(cmd)):
|
|
23
|
+
return super().run(cmd, s0)
|
|
24
|
+
|
|
25
|
+
_, args = self.apply_state(args, s0)
|
|
26
|
+
|
|
27
|
+
os.system('QING_DROPPED=true bash')
|
|
28
|
+
|
|
29
|
+
def completion(self, state: ReplState):
|
|
30
|
+
return super().completion(state)
|
|
31
|
+
|
|
32
|
+
def help(self, _: ReplState):
|
|
33
|
+
return f'{Shell.COMMAND}\t drop down to shell'
|
adam/commands/user_entry.py
CHANGED
adam/repl.py
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import os
|
|
1
2
|
import re
|
|
2
3
|
import time
|
|
3
4
|
import traceback
|
|
@@ -22,6 +23,10 @@ from adam.apps import Apps
|
|
|
22
23
|
from . import __version__
|
|
23
24
|
|
|
24
25
|
def enter_repl(state: ReplState):
|
|
26
|
+
if os.getenv('QING_DROPPED', 'false') == 'true':
|
|
27
|
+
log2('You have dropped to bash from another qing instance. Please enter "exit" to go back to qing.')
|
|
28
|
+
return
|
|
29
|
+
|
|
25
30
|
cmd_list: list[Command] = ReplCommands.repl_cmd_list() + [Help()]
|
|
26
31
|
# head with the Chain of Responsibility pattern
|
|
27
32
|
cmds: Command = Command.chain(cmd_list)
|
adam/repl_commands.py
CHANGED
|
@@ -8,6 +8,7 @@ from adam.commands.deploy.deploy_pod import DeployPod
|
|
|
8
8
|
from adam.commands.deploy.undeploy import Undeploy
|
|
9
9
|
from adam.commands.deploy.undeploy_frontend import UndeployFrontend
|
|
10
10
|
from adam.commands.deploy.undeploy_pod import UndeployPod
|
|
11
|
+
from adam.commands.shell import Shell
|
|
11
12
|
from adam.commands.show.show_app_queues import ShowAppQueues
|
|
12
13
|
from adam.commands.cp import ClipboardCopy
|
|
13
14
|
from adam.commands.bash import Bash
|
|
@@ -77,7 +78,7 @@ class ReplCommands:
|
|
|
77
78
|
return Medusa.cmd_list() + [Restart(), RollOut(), Watch()] + Reaper.cmd_list() + Repair.cmd_list()
|
|
78
79
|
|
|
79
80
|
def tools() -> list[Command]:
|
|
80
|
-
return [Cqlsh(), Postgres(), Bash(), CodeStart(), CodeStop(), DeployFrontend(), UndeployFrontend(), DeployPod(), UndeployPod()]
|
|
81
|
+
return [Cqlsh(), Postgres(), Bash(), Shell(), CodeStart(), CodeStop(), DeployFrontend(), UndeployFrontend(), DeployPod(), UndeployPod()]
|
|
81
82
|
|
|
82
83
|
def app() -> list[Command]:
|
|
83
84
|
return [ShowAppActions(), ShowAppId(), ShowAppQueues(), AppPing(), App()]
|
adam/version.py
CHANGED
|
@@ -9,12 +9,12 @@ adam/embedded_apps.py,sha256=lKPx63mKzJbNmwz0rgL4gF76M9fDGxraYTtNAIGnZ_s,419
|
|
|
9
9
|
adam/embedded_params.py,sha256=sHOxnZLjaDX7oN5VKeCzCpbEMb-1x6Nn9lRA7PE7mos,4362
|
|
10
10
|
adam/log.py,sha256=gg5DK52wLPc9cjykeh0WFHyAk1qI3HEpGaAK8W2dzXY,1146
|
|
11
11
|
adam/pod_exec_result.py,sha256=nq0xnCNOpUGBSijGF0H-YNrwBc9vUQs4DkvLMIFS5LQ,951
|
|
12
|
-
adam/repl.py,sha256=
|
|
13
|
-
adam/repl_commands.py,sha256=
|
|
12
|
+
adam/repl.py,sha256=5uGsu24qVAfATHIRdLJ4er44_9uUnVZ14pr-VXCILI0,7224
|
|
13
|
+
adam/repl_commands.py,sha256=ionPWjPhzrzm59zbhO1WsGGcLVba3bnPl6uPjvQ4C34,4093
|
|
14
14
|
adam/repl_session.py,sha256=uIogcvWBh7wd8QQ-p_JgLsyJ8YJgINw5vOd6JIsd7Vo,472
|
|
15
15
|
adam/repl_state.py,sha256=QarrUAwYWOz3YTemtaf2opbHLa5a3LEsyuonNwhvOhk,7131
|
|
16
16
|
adam/utils.py,sha256=j7p7iruLuV11swa0z9ZLBgoJHu_nkTSVKtQe0q71gmk,7025
|
|
17
|
-
adam/version.py,sha256=
|
|
17
|
+
adam/version.py,sha256=3HKhLTR-_liQFfS4cpfHeuuQulfg53k3jfkqxWaZiyo,140
|
|
18
18
|
adam/checks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
19
19
|
adam/checks/check.py,sha256=Qopr3huYcMu2bzQgb99dEUYjFzkjKHRI76S6KA9b9Rk,702
|
|
20
20
|
adam/checks/check_context.py,sha256=FEHkQ32jY1EDopQ2uYWqy9v7aEEX1orLpJWhopwAlh4,402
|
|
@@ -49,7 +49,7 @@ adam/columns/volume_root.py,sha256=29ujLoCAf9LO75u62LxEaPD58s6ihV-tcK17OeLSOM0,5
|
|
|
49
49
|
adam/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
50
50
|
adam/commands/app.py,sha256=7alV8wK801t67_rUe6EmhtHJTl-6K7fGCm6Uz1dDgpM,1963
|
|
51
51
|
adam/commands/app_ping.py,sha256=Xk7cfefphXM2w-UvpnhNUTZ3BU38f0deehUb2FEyLCI,1337
|
|
52
|
-
adam/commands/bash.py,sha256=
|
|
52
|
+
adam/commands/bash.py,sha256=1O9cCl9JHQdttqNAgdB44rO0NjCqHzHv4psAEQMJcjw,2714
|
|
53
53
|
adam/commands/cd.py,sha256=XEoiMhbJgA2KVKwhHFcs5BRAlf9qpgbAh6IImpKOtHI,4486
|
|
54
54
|
adam/commands/check.py,sha256=853FPfgTMGxQXI_5UaPAtzaSWB_BvEVm48EkJhsHe4w,2181
|
|
55
55
|
adam/commands/cli_commands.py,sha256=PEEyrG9yz7RAEZwHbbuFpyE3fVi8vrIWbr0d1H0Gp9o,3620
|
|
@@ -75,7 +75,8 @@ adam/commands/pwd.py,sha256=VlgFjxFl66I7Df1YI6cuiEeY6Q13lEavMKfrzHLESKo,2340
|
|
|
75
75
|
adam/commands/report.py,sha256=Ky45LIzSlB_X4V12JZWjU3SA2u4_FKRencRTq7psOWU,1944
|
|
76
76
|
adam/commands/restart.py,sha256=Hik1t5rjH2ATZv4tzwrGB3e44b3dNuATgY327_Nb8Bs,2044
|
|
77
77
|
adam/commands/rollout.py,sha256=52_4ijna3v-8Oug12et43DRHFDNhiN34p6xLTQmhdbQ,2959
|
|
78
|
-
adam/commands/
|
|
78
|
+
adam/commands/shell.py,sha256=wY_PIx7Lt6vuxhFArlfxdEnBbrouCJ3yNHhFn17DEqw,848
|
|
79
|
+
adam/commands/user_entry.py,sha256=TJBffUJTVAuJw-UJWv2JOoeEy1iQBXAOLahQJsmX1RY,4719
|
|
79
80
|
adam/commands/watch.py,sha256=mmBFpB8T1V7zrNs5b2YNyDDztMym_ILPDdkrbdAXTas,2438
|
|
80
81
|
adam/commands/deploy/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
81
82
|
adam/commands/deploy/code_start.py,sha256=-iH8HThTNM83IfBxT_LqTByuHVatV9d-Il4OYOfrwLI,1370
|
|
@@ -156,8 +157,8 @@ adam/sso/idp.py,sha256=fvcwUw_URTgsO6ySaqTIw0zQT2qRO1IPSGhf6rPtybo,5804
|
|
|
156
157
|
adam/sso/idp_login.py,sha256=t49CRlMyHA76BAj_kKq0Wa9URIYlzBsUCSmn7Jf5o6I,1721
|
|
157
158
|
adam/sso/idp_session.py,sha256=9BUHNRf70u4rVKrVY1HKPOEmOviXvkjam8WJxmXSKIM,1735
|
|
158
159
|
adam/sso/sso_config.py,sha256=5N8WZgIJQBtHUy585XLRWKjpU87_v6QluyNK9E27D5s,2459
|
|
159
|
-
kaqing-1.98.
|
|
160
|
-
kaqing-1.98.
|
|
161
|
-
kaqing-1.98.
|
|
162
|
-
kaqing-1.98.
|
|
163
|
-
kaqing-1.98.
|
|
160
|
+
kaqing-1.98.94.dist-info/METADATA,sha256=oW3isoB8nfZxIhpxtJSPYCs74XdIl1QuTF-96cfoK7U,133
|
|
161
|
+
kaqing-1.98.94.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
|
|
162
|
+
kaqing-1.98.94.dist-info/entry_points.txt,sha256=SkzhuQJUWsXOzHeZ5TgQ2c3_g53UGK23zzJU_JTZOZI,39
|
|
163
|
+
kaqing-1.98.94.dist-info/top_level.txt,sha256=8_2PZkwBb-xDcnc8a2rAbQeJhXKXskc7zTP7pSPa1fw,5
|
|
164
|
+
kaqing-1.98.94.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|