atomic-lines


Nameatomic-lines JSON
Version 0.1.1rc6 PyPI version JSON
download
home_page
SummaryHelpers for asynchronous line processing. Some asynchronous readline implementations consume data if a readline() call times out. This is a wrapper for those implementations, guranteeing that either full lines are returned or nothing.
upload_time2023-11-21 10:03:43
maintainer
docs_urlNone
author
requires_python>=3.11
licenseMIT
keywords readline async
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage
            # Atomic-Lines

# Intro
A toy project, wrapping asynchronous one byte readers into a sane(?) readline semantic.
If no end of line is found the request is considered timedout, and the data is kept in the buffer,
otherwise lines are returned (without the EOL character) for further processing.

The main goal is to help wrap i.e. serial access or other apis which consume data if readline times out.

For more userfriendly documentation see https://maltevesper.github.io/atomiclines/.

# Logging configuration

Logging can be configured by pointing the environment variable `ATOMICLINES_LOG_CONFIG` to a yaml file.

```
ATOMICLINES_LOG_CONFIG=logging_configuration.yaml pytest
```

The yaml file, should contain a logging dict. Example file:

```
version: 1
disable_existing_loggers: true

formatters:
    standard:
        format: "%(asctime)s - %(name)s - %(levelname)s - %(message)s"
    error:
        format: "%(levelname)s <PID %(process)d:%(processName)s> %(name)s.%(funcName)s(): %(message)s"

handlers:
    console:
        class: logging.StreamHandler
        level: DEBUG
        formatter: standard
        stream: ext://sys.stdout

loggers:
    atomiclines:
        level: INFO
        handlers: [console]
        propogate: no
```

## For Developers

### Bash Completion for pytest
```
pip install argcomplete # is a dev dependency too
activate-global-python-argcomplete
```
            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "atomic-lines",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.11",
    "maintainer_email": "",
    "keywords": "readline async",
    "author": "",
    "author_email": "Malte Vesper <malte.vesper@gmx.net>",
    "download_url": "https://files.pythonhosted.org/packages/e5/f6/3cfe21f0ab94f50ccc8d9575ef02b8e184f2bd209cafae87e5aca3233d25/atomic_lines-0.1.1rc6.tar.gz",
    "platform": null,
    "description": "# Atomic-Lines\n\n# Intro\nA toy project, wrapping asynchronous one byte readers into a sane(?) readline semantic.\nIf no end of line is found the request is considered timedout, and the data is kept in the buffer,\notherwise lines are returned (without the EOL character) for further processing.\n\nThe main goal is to help wrap i.e. serial access or other apis which consume data if readline times out.\n\nFor more userfriendly documentation see https://maltevesper.github.io/atomiclines/.\n\n# Logging configuration\n\nLogging can be configured by pointing the environment variable `ATOMICLINES_LOG_CONFIG` to a yaml file.\n\n```\nATOMICLINES_LOG_CONFIG=logging_configuration.yaml pytest\n```\n\nThe yaml file, should contain a logging dict. Example file:\n\n```\nversion: 1\ndisable_existing_loggers: true\n\nformatters:\n    standard:\n        format: \"%(asctime)s - %(name)s - %(levelname)s - %(message)s\"\n    error:\n        format: \"%(levelname)s <PID %(process)d:%(processName)s> %(name)s.%(funcName)s(): %(message)s\"\n\nhandlers:\n    console:\n        class: logging.StreamHandler\n        level: DEBUG\n        formatter: standard\n        stream: ext://sys.stdout\n\nloggers:\n    atomiclines:\n        level: INFO\n        handlers: [console]\n        propogate: no\n```\n\n## For Developers\n\n### Bash Completion for pytest\n```\npip install argcomplete # is a dev dependency too\nactivate-global-python-argcomplete\n```",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Helpers for asynchronous line processing. Some asynchronous readline implementations consume data if a readline() call times out. This is a wrapper for those implementations, guranteeing that either full lines are returned or nothing.",
    "version": "0.1.1rc6",
    "project_urls": {
        "Changelog": "https://github.com/maltevesper/atomiclines/blob/main/CHANGELOG.md",
        "Documentation": "https://maltevesper.github.io/atomiclines/",
        "Repository": "https://github.com/maltevesper/atomiclines"
    },
    "split_keywords": [
        "readline",
        "async"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "cd2893cd9a1a455f32aca3e60e869ce6a823bb3a4a74ebdc63f5c4f994c93e6c",
                "md5": "8d5f874d483cf0ad12fea0abab97b78b",
                "sha256": "a0e66a8a81c20e02ab83cb7369e2164f68ce5e343ea6b2ef483ec39305eba23d"
            },
            "downloads": -1,
            "filename": "atomic_lines-0.1.1rc6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "8d5f874d483cf0ad12fea0abab97b78b",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11",
            "size": 11832,
            "upload_time": "2023-11-21T10:03:42",
            "upload_time_iso_8601": "2023-11-21T10:03:42.114047Z",
            "url": "https://files.pythonhosted.org/packages/cd/28/93cd9a1a455f32aca3e60e869ce6a823bb3a4a74ebdc63f5c4f994c93e6c/atomic_lines-0.1.1rc6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e5f63cfe21f0ab94f50ccc8d9575ef02b8e184f2bd209cafae87e5aca3233d25",
                "md5": "a88c36f5e2b9568bdcd945e8158d3a99",
                "sha256": "4940bf07eee586669ed5450e12d0b87f9025977f6697c87b97106153072371ec"
            },
            "downloads": -1,
            "filename": "atomic_lines-0.1.1rc6.tar.gz",
            "has_sig": false,
            "md5_digest": "a88c36f5e2b9568bdcd945e8158d3a99",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11",
            "size": 17395,
            "upload_time": "2023-11-21T10:03:43",
            "upload_time_iso_8601": "2023-11-21T10:03:43.798929Z",
            "url": "https://files.pythonhosted.org/packages/e5/f6/3cfe21f0ab94f50ccc8d9575ef02b8e184f2bd209cafae87e5aca3233d25/atomic_lines-0.1.1rc6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-21 10:03:43",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "maltevesper",
    "github_project": "atomiclines",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": false,
    "lcname": "atomic-lines"
}
        
Elapsed time: 0.33117s