multiSSH3 5.80__tar.gz → 5.81__tar.gz

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 multiSSH3 might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: multiSSH3
3
- Version: 5.80
3
+ Version: 5.81
4
4
  Summary: Run commands on multiple hosts via SSH
5
5
  Home-page: https://github.com/yufei-pan/multiSSH3
6
6
  Author: Yufei Pan
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: multiSSH3
3
- Version: 5.80
3
+ Version: 5.81
4
4
  Summary: Run commands on multiple hosts via SSH
5
5
  Home-page: https://github.com/yufei-pan/multiSSH3
6
6
  Author: Yufei Pan
@@ -55,10 +55,10 @@ except AttributeError:
55
55
  # If neither is available, use a dummy decorator
56
56
  def cache_decorator(func):
57
57
  return func
58
- version = '5.80'
58
+ version = '5.81'
59
59
  VERSION = version
60
60
  __version__ = version
61
- COMMIT_DATE = '2025-07-09'
61
+ COMMIT_DATE = '2025-07-15'
62
62
 
63
63
  CONFIG_FILE_CHAIN = ['./multiSSH3.config.json',
64
64
  '~/multiSSH3.config.json',
@@ -934,7 +934,7 @@ def compact_hostnames(Hostnames,verify = True):
934
934
  if not __global_suppress_printout:
935
935
  eprint(f"Error compacting hostnames: {hostSet} -> {compact_hosts}")
936
936
  compact_hosts = hostSet
937
- return compact_hosts
937
+ return sorted(compact_hosts)
938
938
 
939
939
  #%% ------------ Expanding Hostnames ----------------
940
940
  @cache_decorator
@@ -2355,7 +2355,7 @@ def generate_output(hosts, usejson = False, greppable = False):
2355
2355
  outputs.setdefault(hostPrintOut, set()).add(host['name'])
2356
2356
  rtnStr = ''
2357
2357
  for output, hostSet in outputs.items():
2358
- compact_hosts = sorted(compact_hostnames(hostSet))
2358
+ compact_hosts = compact_hostnames(hostSet)
2359
2359
  rtnStr += '*'*80+'\n'
2360
2360
  if __global_suppress_printout:
2361
2361
  rtnStr += f'Abnormal returncode produced by {",".join(compact_hosts)}:\n'
@@ -2493,8 +2493,7 @@ def formHostStr(host) -> str:
2493
2493
  if 'local_shell' in host:
2494
2494
  host.remove('local_shell')
2495
2495
  host.add('localhost')
2496
- host = ','.join(host)
2497
- return host
2496
+ return ','.join(compact_hostnames(host))
2498
2497
 
2499
2498
  @cache_decorator
2500
2499
  def __formCommandArgStr(oneonone = DEFAULT_ONE_ON_ONE, timeout = DEFAULT_TIMEOUT,password = DEFAULT_PASSWORD,
@@ -2777,7 +2776,7 @@ def run_command_on_hosts(hosts = DEFAULT_HOSTS,commands = None,oneonone = DEFAUL
2777
2776
  skipHostsDic = expand_hostnames(skipHostStr.split(','))
2778
2777
  skipHostSet = set(skipHostsDic).union(skipHostsDic.values())
2779
2778
  if skipHostSet:
2780
- eprint(f"Skipping hosts: \"{' '.join(sorted(compact_hostnames(skipHostSet)))}\"")
2779
+ eprint(f"Skipping hosts: \"{' '.join(compact_hostnames(skipHostSet))}\"")
2781
2780
  if copy_id:
2782
2781
  if 'ssh-copy-id' in _binPaths:
2783
2782
  # we will copy the id to the hosts
@@ -3227,12 +3226,12 @@ def main():
3227
3226
  if __mainReturnCode > 0:
3228
3227
  if not __global_suppress_printout:
3229
3228
  eprint(f'Complete. Failed hosts (Return Code not 0) count: {__mainReturnCode}')
3230
- eprint(f'failed_hosts: {",".join(sorted(compact_hostnames(__failedHosts)))}')
3229
+ eprint(f'failed_hosts: {",".join(compact_hostnames(__failedHosts))}')
3231
3230
  else:
3232
3231
  if not __global_suppress_printout: eprint('Complete. All hosts returned 0.')
3233
3232
 
3234
3233
  if args.success_hosts and not __global_suppress_printout:
3235
- eprint(f'succeeded_hosts: {",".join(sorted(compact_hostnames(succeededHosts)))}')
3234
+ eprint(f'succeeded_hosts: {",".join(compact_hostnames(succeededHosts))}')
3236
3235
 
3237
3236
  if threading.active_count() > 1 and not __global_suppress_printout:
3238
3237
  eprint(f'Remaining active thread: {threading.active_count()}')
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes