portune 0.1.16__py3-none-any.whl → 0.1.18__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 portune might be problematic. Click here for more details.
- portune/portune.py +5 -4
- portune/version.py +2 -2
- {portune-0.1.16.dist-info → portune-0.1.18.dist-info}/METADATA +2 -1
- portune-0.1.18.dist-info/RECORD +9 -0
- portune-0.1.16.dist-info/RECORD +0 -9
- {portune-0.1.16.dist-info → portune-0.1.18.dist-info}/WHEEL +0 -0
- {portune-0.1.16.dist-info → portune-0.1.18.dist-info}/entry_points.txt +0 -0
- {portune-0.1.16.dist-info → portune-0.1.18.dist-info}/licenses/LICENSE +0 -0
- {portune-0.1.16.dist-info → portune-0.1.18.dist-info}/top_level.txt +0 -0
portune/portune.py
CHANGED
|
@@ -30,7 +30,6 @@ from email.mime.text import MIMEText
|
|
|
30
30
|
from email.mime.multipart import MIMEMultipart
|
|
31
31
|
from email.mime.application import MIMEApplication
|
|
32
32
|
from typing import List, Dict, Tuple, Any, Optional, Union
|
|
33
|
-
import shlex
|
|
34
33
|
|
|
35
34
|
# Constants and global variables
|
|
36
35
|
OS = platform.system().lower()
|
|
@@ -723,7 +722,7 @@ def ping_host(ip: str, timeout: float = 2.0) -> bool:
|
|
|
723
722
|
True if host responds to ping, False otherwise
|
|
724
723
|
"""
|
|
725
724
|
timeoutms = str(int(timeout * 1000))
|
|
726
|
-
ping_cmd =
|
|
725
|
+
ping_cmd = PING.format(ip=ip, timeout=timeout, timeoutms=timeoutms).split()
|
|
727
726
|
try:
|
|
728
727
|
output = subprocess.run(ping_cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, timeout=timeout + 1)
|
|
729
728
|
return output.returncode == 0
|
|
@@ -1280,7 +1279,8 @@ def generate_html_report(
|
|
|
1280
1279
|
<th>Port</th>
|
|
1281
1280
|
<th>Status</th>
|
|
1282
1281
|
<th>Ping</th>
|
|
1283
|
-
{"
|
|
1282
|
+
{"""
|
|
1283
|
+
""".join([f"<th>{d}</th>" for d in desc_titles])}
|
|
1284
1284
|
</tr>
|
|
1285
1285
|
</thead>
|
|
1286
1286
|
<tbody>
|
|
@@ -1302,7 +1302,8 @@ def generate_html_report(
|
|
|
1302
1302
|
<td style="text-align: right;">{port}</td>
|
|
1303
1303
|
<td style="text-align: center;"><span class="{status_class} status">{escape(status)}</span></td>
|
|
1304
1304
|
<td style="text-align: center;"><span class="{ping_class} ping">{ping_status}</span></td>
|
|
1305
|
-
{"
|
|
1305
|
+
{"""
|
|
1306
|
+
""".join([f'<td class="desc">{escape(desc[i] if i < len(desc) else "")}</td>' for i in range(len(desc_titles))])}
|
|
1306
1307
|
</tr>
|
|
1307
1308
|
''')
|
|
1308
1309
|
|
portune/version.py
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: portune
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.18
|
|
4
4
|
Summary: Simple Python HTTP Exec Server
|
|
5
5
|
Author: Franck Jouvanceau
|
|
6
6
|
Maintainer: Franck Jouvanceau
|
|
@@ -36,6 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
[](https://shields.io/)
|
|
37
37
|
[](https://pepy.tech/project/portune)
|
|
38
38
|
[](https://shields.io/)
|
|
39
|
+
[]()
|
|
39
40
|
|
|
40
41
|
# portune
|
|
41
42
|
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
portune/__init__.py,sha256=RfXuNfHBqfRt_z4IukwN1a0oeCXahuMOO8_eBt4T8NM,58
|
|
2
|
+
portune/portune.py,sha256=XqQeHUmdnrnaY4IrEz9Itnmdieu25Wjca0O0RbyzKs0,67713
|
|
3
|
+
portune/version.py,sha256=mhAYdSWzD7l6mXhR3foHESbkj_QM4Asoa3WlsLLYkfM,513
|
|
4
|
+
portune-0.1.18.dist-info/licenses/LICENSE,sha256=gRJf0JPT_wsZJsUGlWPTS8Vypfl9vQ1qjp6sNbKykuA,1064
|
|
5
|
+
portune-0.1.18.dist-info/METADATA,sha256=ZiJbxdsqQQ69_FPRnkzvCy6_52UGoFEoyiMjazDZUCE,2372
|
|
6
|
+
portune-0.1.18.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
7
|
+
portune-0.1.18.dist-info/entry_points.txt,sha256=6j7jAf5fOZrLPbVIs3z92R1tT891WyY9YxQ6OVnPKG0,80
|
|
8
|
+
portune-0.1.18.dist-info/top_level.txt,sha256=CITDikHhRKAsSOGmNJzD-xSp6D5iBhSr9ZS1qy8-SL0,8
|
|
9
|
+
portune-0.1.18.dist-info/RECORD,,
|
portune-0.1.16.dist-info/RECORD
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
portune/__init__.py,sha256=RfXuNfHBqfRt_z4IukwN1a0oeCXahuMOO8_eBt4T8NM,58
|
|
2
|
-
portune/portune.py,sha256=ObXQFrmPNnEt6d0hNYFHaA2SyHmRFbSC573C2QlrZ2k,67680
|
|
3
|
-
portune/version.py,sha256=VYJNWHISWEW-KD_clKUYcTY_Z30r993Sjws4URJIL0g,513
|
|
4
|
-
portune-0.1.16.dist-info/licenses/LICENSE,sha256=gRJf0JPT_wsZJsUGlWPTS8Vypfl9vQ1qjp6sNbKykuA,1064
|
|
5
|
-
portune-0.1.16.dist-info/METADATA,sha256=viabm-g74udivm_7HymwhFC7-uG6EFMsbGBCwUZ15Ao,2249
|
|
6
|
-
portune-0.1.16.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
7
|
-
portune-0.1.16.dist-info/entry_points.txt,sha256=6j7jAf5fOZrLPbVIs3z92R1tT891WyY9YxQ6OVnPKG0,80
|
|
8
|
-
portune-0.1.16.dist-info/top_level.txt,sha256=CITDikHhRKAsSOGmNJzD-xSp6D5iBhSr9ZS1qy8-SL0,8
|
|
9
|
-
portune-0.1.16.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|