omlish 0.0.0.dev158__py3-none-any.whl → 0.0.0.dev159__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.
- omlish/__about__.py +2 -2
- omlish/lite/runtime.py +4 -4
- omlish/logs/all.py +1 -1
- omlish/logs/standard.py +7 -5
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/METADATA +1 -1
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/RECORD +10 -10
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/LICENSE +0 -0
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/WHEEL +0 -0
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/entry_points.txt +0 -0
- {omlish-0.0.0.dev158.dist-info → omlish-0.0.0.dev159.dist-info}/top_level.txt +0 -0
    
        omlish/__about__.py
    CHANGED
    
    
    
        omlish/lite/runtime.py
    CHANGED
    
    | @@ -9,9 +9,9 @@ def is_debugger_attached() -> bool: | |
| 9 9 | 
             
                return any(frame[1].endswith('pydevd.py') for frame in inspect.stack())
         | 
| 10 10 |  | 
| 11 11 |  | 
| 12 | 
            -
             | 
| 12 | 
            +
            LITE_REQUIRED_PYTHON_VERSION = (3, 8)
         | 
| 13 13 |  | 
| 14 14 |  | 
| 15 | 
            -
            def  | 
| 16 | 
            -
                if sys.version_info <  | 
| 17 | 
            -
                    raise OSError(f'Requires python { | 
| 15 | 
            +
            def check_lite_runtime_version() -> None:
         | 
| 16 | 
            +
                if sys.version_info < LITE_REQUIRED_PYTHON_VERSION:
         | 
| 17 | 
            +
                    raise OSError(f'Requires python {LITE_REQUIRED_PYTHON_VERSION}, got {sys.version_info} from {sys.executable}')  # noqa
         | 
    
        omlish/logs/all.py
    CHANGED
    
    
    
        omlish/logs/standard.py
    CHANGED
    
    | @@ -5,6 +5,7 @@ TODO: | |
| 5 5 | 
             
             - structured
         | 
| 6 6 | 
             
             - prefixed
         | 
| 7 7 | 
             
             - debug
         | 
| 8 | 
            +
             - optional noisy? noisy will never be lite - some kinda configure_standard callback mechanism?
         | 
| 8 9 | 
             
            """
         | 
| 9 10 | 
             
            import contextlib
         | 
| 10 11 | 
             
            import datetime
         | 
| @@ -49,8 +50,9 @@ class StandardLogFormatter(logging.Formatter): | |
| 49 50 | 
             
            ##
         | 
| 50 51 |  | 
| 51 52 |  | 
| 52 | 
            -
            class  | 
| 53 | 
            -
                 | 
| 53 | 
            +
            class StandardConfiguredLogHandler(ProxyLogHandler):
         | 
| 54 | 
            +
                def __init_subclass__(cls, **kwargs):
         | 
| 55 | 
            +
                    raise TypeError('This class serves only as a marker and should not be subclassed.')
         | 
| 54 56 |  | 
| 55 57 |  | 
| 56 58 | 
             
            ##
         | 
| @@ -81,7 +83,7 @@ def configure_standard_logging( | |
| 81 83 | 
             
                    target: ta.Optional[logging.Logger] = None,
         | 
| 82 84 | 
             
                    force: bool = False,
         | 
| 83 85 | 
             
                    handler_factory: ta.Optional[ta.Callable[[], logging.Handler]] = None,
         | 
| 84 | 
            -
            ) -> ta.Optional[ | 
| 86 | 
            +
            ) -> ta.Optional[StandardConfiguredLogHandler]:
         | 
| 85 87 | 
             
                with _locking_logging_module_lock():
         | 
| 86 88 | 
             
                    if target is None:
         | 
| 87 89 | 
             
                        target = logging.root
         | 
| @@ -89,7 +91,7 @@ def configure_standard_logging( | |
| 89 91 | 
             
                    #
         | 
| 90 92 |  | 
| 91 93 | 
             
                    if not force:
         | 
| 92 | 
            -
                        if any(isinstance(h,  | 
| 94 | 
            +
                        if any(isinstance(h, StandardConfiguredLogHandler) for h in list(target.handlers)):
         | 
| 93 95 | 
             
                            return None
         | 
| 94 96 |  | 
| 95 97 | 
             
                    #
         | 
| @@ -123,4 +125,4 @@ def configure_standard_logging( | |
| 123 125 |  | 
| 124 126 | 
             
                    #
         | 
| 125 127 |  | 
| 126 | 
            -
                    return  | 
| 128 | 
            +
                    return StandardConfiguredLogHandler(handler)
         | 
| @@ -1,5 +1,5 @@ | |
| 1 1 | 
             
            omlish/.manifests.json,sha256=RX24SRc6DCEg77PUVnaXOKCWa5TF_c9RQJdGIf7gl9c,1135
         | 
| 2 | 
            -
            omlish/__about__.py,sha256= | 
| 2 | 
            +
            omlish/__about__.py,sha256=Oft5eCVCcnEMK8rYnJP3QHL7ISL4-IJeS8mYfuDtxXI,3409
         | 
| 3 3 | 
             
            omlish/__init__.py,sha256=SsyiITTuK0v74XpKV8dqNaCmjOlan1JZKrHQv5rWKPA,253
         | 
| 4 4 | 
             
            omlish/c3.py,sha256=ubu7lHwss5V4UznbejAI0qXhXahrU01MysuHOZI9C4U,8116
         | 
| 5 5 | 
             
            omlish/cached.py,sha256=UI-XTFBwA6YXWJJJeBn-WkwBkfzDjLBBaZf4nIJA9y0,510
         | 
| @@ -347,7 +347,7 @@ omlish/lite/maybes.py,sha256=7OlHJ8Q2r4wQ-aRbZSlJY7x0e8gDvufFdlohGEIJ3P4,833 | |
| 347 347 | 
             
            omlish/lite/pycharm.py,sha256=pUOJevrPClSqTCEOkQBO11LKX2003tfDcp18a03QFrc,1163
         | 
| 348 348 | 
             
            omlish/lite/reflect.py,sha256=ad_ya_zZJOQB8HoNjs9yc66R54zgflwJVPJqiBXMzqA,1681
         | 
| 349 349 | 
             
            omlish/lite/resources.py,sha256=YNSmX1Ohck1aoWRs55a-o5ChVbFJIQhtbqE-XwF55Oc,326
         | 
| 350 | 
            -
            omlish/lite/runtime.py,sha256= | 
| 350 | 
            +
            omlish/lite/runtime.py,sha256=XQo408zxTdJdppUZqOWHyeUR50VlCpNIExNGHz4U6O4,459
         | 
| 351 351 | 
             
            omlish/lite/secrets.py,sha256=3Mz3V2jf__XU9qNHcH56sBSw95L3U2UPL24bjvobG0c,816
         | 
| 352 352 | 
             
            omlish/lite/socket.py,sha256=7OYgkXTcQv0wq7TQuLnl9y6dJA1ZT6Vbc1JH59QlxgY,1792
         | 
| 353 353 | 
             
            omlish/lite/socketserver.py,sha256=doTXIctu_6c8XneFtzPFVG_Wq6xVmA3p9ymut8IvBoU,1586
         | 
| @@ -355,7 +355,7 @@ omlish/lite/strings.py,sha256=QURcE4-1pKVW8eT_5VCJpXaHDWR2dW2pYOChTJnZDiQ,1504 | |
| 355 355 | 
             
            omlish/lite/typing.py,sha256=U3-JaEnkDSYxK4tsu_MzUn3RP6qALBe5FXQXpD-licE,1090
         | 
| 356 356 | 
             
            omlish/logs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
         | 
| 357 357 | 
             
            omlish/logs/abc.py,sha256=ho4ABKYMKX-V7g4sp1BByuOLzslYzLlQ0MESmjEpT-o,8005
         | 
| 358 | 
            -
            omlish/logs/all.py,sha256= | 
| 358 | 
            +
            omlish/logs/all.py,sha256=4Z6cNB0E1xbX0IOQWZEWLA0Jw-yyjhXa3PD_Nvfewu8,556
         | 
| 359 359 | 
             
            omlish/logs/color.py,sha256=02feYPZm4A7qHeBABpiar2J2E6tf-vtw1pOQAsJs_1c,668
         | 
| 360 360 | 
             
            omlish/logs/configs.py,sha256=XOc8rWxfPpPMxJESVD2mLCUoLtbQnGnZwvYhhqe7DD8,772
         | 
| 361 361 | 
             
            omlish/logs/filters.py,sha256=2noFRyBez3y519fpfsDSt1vo8wX-85b8sMXZi5o_xyE,208
         | 
| @@ -363,7 +363,7 @@ omlish/logs/handlers.py,sha256=zgSnKQA5q9Fu7T0Nkd7twog9H1Wg9-bDCzz4_F1TOBo,319 | |
| 363 363 | 
             
            omlish/logs/json.py,sha256=zyqMWpZY3lk4WRk4wgmataBomGX9S3iDsydiM1sS-lI,1366
         | 
| 364 364 | 
             
            omlish/logs/noisy.py,sha256=Ubc-eTH6ZbGYsLfUUi69JAotwuUwzb-SJBeGo_0dIZI,348
         | 
| 365 365 | 
             
            omlish/logs/proxy.py,sha256=A-ROPUUAlF397qTbEqhel6YhQMstNuXL3Xmts7w9dAo,2347
         | 
| 366 | 
            -
            omlish/logs/standard.py,sha256= | 
| 366 | 
            +
            omlish/logs/standard.py,sha256=BVFn8pFyafxuco1sjA5COYxX5Q0Wv80_OE9zo6uDp2Q,3164
         | 
| 367 367 | 
             
            omlish/logs/utils.py,sha256=mzHrZ9ji75p5A8qR29eUr05CBAHMb8J753MSkID_VaQ,393
         | 
| 368 368 | 
             
            omlish/manifests/__init__.py,sha256=P2B0dpT8D7l5lJwRGPA92IcQj6oeXfd90X5-q9BJrKg,51
         | 
| 369 369 | 
             
            omlish/manifests/load.py,sha256=8R-S5CyQpAbxDHt5wcNF6mAYri8bGndn6R2uEVOh52Y,4809
         | 
| @@ -525,9 +525,9 @@ omlish/text/glyphsplit.py,sha256=Ug-dPRO7x-OrNNr8g1y6DotSZ2KH0S-VcOmUobwa4B0,329 | |
| 525 525 | 
             
            omlish/text/indent.py,sha256=6Jj6TFY9unaPa4xPzrnZemJ-fHsV53IamP93XGjSUHs,1274
         | 
| 526 526 | 
             
            omlish/text/parts.py,sha256=7vPF1aTZdvLVYJ4EwBZVzRSy8XB3YqPd7JwEnNGGAOo,6495
         | 
| 527 527 | 
             
            omlish/text/random.py,sha256=jNWpqiaKjKyTdMXC-pWAsSC10AAP-cmRRPVhm59ZWLk,194
         | 
| 528 | 
            -
            omlish-0.0.0. | 
| 529 | 
            -
            omlish-0.0.0. | 
| 530 | 
            -
            omlish-0.0.0. | 
| 531 | 
            -
            omlish-0.0.0. | 
| 532 | 
            -
            omlish-0.0.0. | 
| 533 | 
            -
            omlish-0.0.0. | 
| 528 | 
            +
            omlish-0.0.0.dev159.dist-info/LICENSE,sha256=B_hVtavaA8zCYDW99DYdcpDLKz1n3BBRjZrcbv8uG8c,1451
         | 
| 529 | 
            +
            omlish-0.0.0.dev159.dist-info/METADATA,sha256=5v5tXuLmc6Vhu3AbvfFi0Gt4uKcFAqMr5g2Ca5t_CeA,4264
         | 
| 530 | 
            +
            omlish-0.0.0.dev159.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
         | 
| 531 | 
            +
            omlish-0.0.0.dev159.dist-info/entry_points.txt,sha256=Lt84WvRZJskWCAS7xnQGZIeVWksprtUHj0llrvVmod8,35
         | 
| 532 | 
            +
            omlish-0.0.0.dev159.dist-info/top_level.txt,sha256=pePsKdLu7DvtUiecdYXJ78iO80uDNmBlqe-8hOzOmfs,7
         | 
| 533 | 
            +
            omlish-0.0.0.dev159.dist-info/RECORD,,
         | 
| 
            File without changes
         | 
| 
            File without changes
         | 
| 
            File without changes
         | 
| 
            File without changes
         |