pythoncgi
Advanced tools
+1
-1
| Metadata-Version: 2.1 | ||
| Name: pythoncgi | ||
| Version: 0.15.0 | ||
| Version: 0.16.0 | ||
| Summary: Extremely simple Python CGI framework for Apache 2. | ||
@@ -5,0 +5,0 @@ Home-page: http://code.foxe6.kozow.com/pythoncgi/ |
@@ -1,2 +0,2 @@ | ||
| __version__ = "0.15.0" | ||
| __version__ = "0.16.0" | ||
| __keywords__ = ["python cgi apache stream file cache server proxy http cors"] | ||
@@ -3,0 +3,0 @@ |
@@ -60,5 +60,2 @@ from .utils import obj_to_bytes, _should_return_304, _basic_authorization, _cache_control, parse_range, parse_authorization, set_authenticate_response, _write_to_cache_file, _should_read_from_cache_file, request_body_wrapper, parse_multi_body | ||
| def update_settings(w): | ||
| t = type(__SETTINGS[w]) | ||
| if type(w) is not t: | ||
| raise TypeError("{} is not {}".format(type(w), t)) | ||
| __SETTINGS.update(w) | ||
@@ -340,4 +337,4 @@ | ||
| ): | ||
| __FLAGS.update({"cacheable": cacheable}) | ||
| def wrapper(method_main): | ||
| __FLAGS.update({"cacheable": cacheable}) | ||
| limit = None | ||
@@ -344,0 +341,0 @@ chain = True |
+17
-18
@@ -141,3 +141,3 @@ from omnitools import dt2rfc822gmt, rfc822gmt2dt, b64d_and_utf8d, str2html | ||
| b = memoryview(b) | ||
| nl = b[-2:] | ||
| nl = b[-2:].tobytes() | ||
| if nl == b"\r\n": | ||
@@ -162,12 +162,13 @@ return b[:-2].tobytes() | ||
| n = length-read | ||
| read += n | ||
| try: | ||
| return overread.tobytes()+body.read(n) | ||
| finally: | ||
| overread = memoryview(b"") | ||
| _ = body.read(n) | ||
| read += len(_) | ||
| _ = overread.tobytes()+_ | ||
| overread = memoryview(b"") | ||
| return _ | ||
| else: | ||
| if read+n > length: | ||
| n = length-read | ||
| read += n | ||
| return body.read(n) | ||
| _ = body.read(n) | ||
| read += len(_) | ||
| return _ | ||
| def read_file(): | ||
@@ -223,16 +224,14 @@ nonlocal file_read | ||
| _ = overread[:pos+1].tobytes() | ||
| overread = overread[pos+1:] | ||
| if not skip: | ||
| c += _ | ||
| overread = overread[pos+1:] | ||
| except ValueError: | ||
| pass | ||
| while True: | ||
| if read >= length: | ||
| return c | ||
| _ = body.read(1) | ||
| read += 1 | ||
| if not skip: | ||
| c += _ | ||
| if _ == b"\n": | ||
| return c | ||
| if read >= length: | ||
| return c | ||
| _ = body.readline() | ||
| read += len(_) | ||
| if not skip: | ||
| c += _ | ||
| return c | ||
| def skipline(): | ||
@@ -239,0 +238,0 @@ return readline(True) |
+7
-7
@@ -1,4 +0,4 @@ | ||
| pythoncgi/__init__.py,sha256=1jEDAx-uwIBkkIVX80xlhxFukDPwUxaWqPkaJmm51lo,838 | ||
| pythoncgi/core.py,sha256=KROkjW8NsH4dNNnAjZJp_uGZA8GsZM3Unqx4LQg-rH4,12901 | ||
| pythoncgi/utils.py,sha256=R-MrAZQ0tIbWwazXD1_VvvpYs5gst-IGXN_BYQ12pNE,9454 | ||
| pythoncgi/__init__.py,sha256=iZYOMEFkifTcJ0BGD2AK8tDCP4TvDPSGySo-71Vpmos,838 | ||
| pythoncgi/core.py,sha256=2losMlF3AqEtfLuCUvtER7NxqyclmEVJFx-rxEVPn1g,12790 | ||
| pythoncgi/utils.py,sha256=vPNKGlDpMLQJYbbUwfGKwCQwp1DFxZS04I55pysfR7M,9410 | ||
| pythoncgi/__metadata__/DISCLIAIMER.md,sha256=Eh9dhFWbvRMm27jxKYRZqQp_Lb8PkhbYWYQyLoMSrHg,4785 | ||
@@ -19,5 +19,5 @@ pythoncgi/__metadata__/LICENSE,sha256=E_tIpsMacuDitpZQsc6-iVT3tzRJhISS3P0islvZGvo,35182 | ||
| pythoncgi/example/zippyshare_remote_upload.py,sha256=2ZS22-W-L3--uvUQ9rZ4xDWQR6_ITQmG5riLKRWaoK4,2582 | ||
| pythoncgi-0.15.0.dist-info/METADATA,sha256=a_IpR-1puYM0bhZTaHu7D_WgVHX2_n8_F2D_P1qkCek,2139 | ||
| pythoncgi-0.15.0.dist-info/WHEEL,sha256=ewwEueio1C2XeHTvT17n8dZUJgOvyCWCt0WVNLClP9o,92 | ||
| pythoncgi-0.15.0.dist-info/top_level.txt,sha256=4FgkqITdsDhqlKxg5Kpy0sWE5NW6U6bXfQFwArs0qPk,10 | ||
| pythoncgi-0.15.0.dist-info/RECORD,, | ||
| pythoncgi-0.16.0.dist-info/METADATA,sha256=knPhU_jxstm0ndrKO8D1VKNALEtenPuNiFwREoxoQVk,2139 | ||
| pythoncgi-0.16.0.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92 | ||
| pythoncgi-0.16.0.dist-info/top_level.txt,sha256=4FgkqITdsDhqlKxg5Kpy0sWE5NW6U6bXfQFwArs0qPk,10 | ||
| pythoncgi-0.16.0.dist-info/RECORD,, |
+1
-1
| Wheel-Version: 1.0 | ||
| Generator: bdist_wheel (0.37.0) | ||
| Generator: bdist_wheel (0.37.1) | ||
| Root-Is-Purelib: true | ||
| Tag: py3-none-any | ||
Alert delta unavailable
Currently unable to show alert delta for PyPI packages.