bite-parser


Namebite-parser JSON
Version 0.2.5 PyPI version JSON
download
home_pagehttps://github.com/jgosmann/bite-parser/
SummaryAsynchronous parser taking incremental bites out of your byte input stream.
upload_time2024-10-27 08:23:15
maintainerNone
docs_urlNone
authorJan Gosmann
requires_python<4.0,>=3.9
licenseMIT
keywords asyncio parser peg incremental parser expression grammar
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            .. image:: https://github.com/jgosmann/bite-parser/actions/workflows/ci.yml/badge.svg
  :target: https://github.com/jgosmann/bite-parser/actions/workflows/ci.yml
  :alt: CI and release pipeline
.. image:: https://codecov.io/gh/jgosmann/bite-parser/branch/main/graph/badge.svg?token=O4M05YWNQK
  :target: https://codecov.io/gh/jgosmann/bite-parser
  :alt: Codecov coverage
.. image:: https://img.shields.io/pypi/v/bite-parser
  :target: https://pypi.org/project/bite-parser/
  :alt: PyPI
.. image:: https://img.shields.io/pypi/pyversions/bite-parser
  :target: https://pypi.org/project/bite-parser/
  :alt: PyPI - Python Version
.. image:: https://img.shields.io/pypi/l/bite-parser
  :target: https://pypi.org/project/bite-parser/
  :alt: PyPI - License

Welcome to bite-parser
======================

   Asynchronous parser taking incremental bites out of your byte input stream.

The bite-parser is a parser combinator library for Python.
It is similar to `PyParsing <https://github.com/pyparsing/pyparsing>`_
in that it allows the construction of grammars for parsing
from simple building blocks in pure Python.
This approach is also known as `Parsing Expression Grammar (PEG)
<https://en.wikipedia.org/wiki/Parsing_expression_grammar>`_.
While PyParsing
(and many other Python parsing libraries)
only support string,
bite-parser operates on bytes.
In addition,
bite-parser makes use of `asyncio`
and can asynchronously generate parsed items
from an input stream.

A typical use-case would be the parsing of a network protocol
like IMAP.
In fact,
I wrote this library for the IMAP implementation of my
`dmarc-metrics-exporter <https://github.com/jgosmann/dmarc-metrics-exporter>`_.

.. note::
   I have implemented the fundamental set of parsers,
   which should allow constructing most or all grammars
   recognizable by this type of parser.
   However, many convenience or higher level parsers are not yet implemented.

   Other areas that still need improvement are:

   * Abilitiy to debug the parsing.
   * Better error messages.
   * Performance: Currently, only a basic recursive descent parser is
     implemented which can exhibit exponential worst case performance.
     This could be improved by implementing a packrat parser.

Important links
---------------

* `Documentation <https://jgosmann.github.io/bite-parser/docs/en/main/>`_
* `GitHub repository <https://github.com/jgosmann/bite-parser>`_

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/jgosmann/bite-parser/",
    "name": "bite-parser",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.9",
    "maintainer_email": null,
    "keywords": "asyncio, parser, PEG, incremental, parser expression grammar",
    "author": "Jan Gosmann",
    "author_email": "jan@hyper-world.de",
    "download_url": "https://files.pythonhosted.org/packages/c0/cd/0e621c1d031fbfc26c2c918cd524e51899b262db28f0bbfbabb361991bf4/bite_parser-0.2.5.tar.gz",
    "platform": null,
    "description": ".. image:: https://github.com/jgosmann/bite-parser/actions/workflows/ci.yml/badge.svg\n  :target: https://github.com/jgosmann/bite-parser/actions/workflows/ci.yml\n  :alt: CI and release pipeline\n.. image:: https://codecov.io/gh/jgosmann/bite-parser/branch/main/graph/badge.svg?token=O4M05YWNQK\n  :target: https://codecov.io/gh/jgosmann/bite-parser\n  :alt: Codecov coverage\n.. image:: https://img.shields.io/pypi/v/bite-parser\n  :target: https://pypi.org/project/bite-parser/\n  :alt: PyPI\n.. image:: https://img.shields.io/pypi/pyversions/bite-parser\n  :target: https://pypi.org/project/bite-parser/\n  :alt: PyPI - Python Version\n.. image:: https://img.shields.io/pypi/l/bite-parser\n  :target: https://pypi.org/project/bite-parser/\n  :alt: PyPI - License\n\nWelcome to bite-parser\n======================\n\n   Asynchronous parser taking incremental bites out of your byte input stream.\n\nThe bite-parser is a parser combinator library for Python.\nIt is similar to `PyParsing <https://github.com/pyparsing/pyparsing>`_\nin that it allows the construction of grammars for parsing\nfrom simple building blocks in pure Python.\nThis approach is also known as `Parsing Expression Grammar (PEG)\n<https://en.wikipedia.org/wiki/Parsing_expression_grammar>`_.\nWhile PyParsing\n(and many other Python parsing libraries)\nonly support string,\nbite-parser operates on bytes.\nIn addition,\nbite-parser makes use of `asyncio`\nand can asynchronously generate parsed items\nfrom an input stream.\n\nA typical use-case would be the parsing of a network protocol\nlike IMAP.\nIn fact,\nI wrote this library for the IMAP implementation of my\n`dmarc-metrics-exporter <https://github.com/jgosmann/dmarc-metrics-exporter>`_.\n\n.. note::\n   I have implemented the fundamental set of parsers,\n   which should allow constructing most or all grammars\n   recognizable by this type of parser.\n   However, many convenience or higher level parsers are not yet implemented.\n\n   Other areas that still need improvement are:\n\n   * Abilitiy to debug the parsing.\n   * Better error messages.\n   * Performance: Currently, only a basic recursive descent parser is\n     implemented which can exhibit exponential worst case performance.\n     This could be improved by implementing a packrat parser.\n\nImportant links\n---------------\n\n* `Documentation <https://jgosmann.github.io/bite-parser/docs/en/main/>`_\n* `GitHub repository <https://github.com/jgosmann/bite-parser>`_\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Asynchronous parser taking incremental bites out of your byte input stream.",
    "version": "0.2.5",
    "project_urls": {
        "Homepage": "https://github.com/jgosmann/bite-parser/",
        "Repository": "https://github.com/jgosmann/bite-parser/"
    },
    "split_keywords": [
        "asyncio",
        " parser",
        " peg",
        " incremental",
        " parser expression grammar"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ab5f147f2d06a3df0bd626bd7eb2cd20c46ff62cd33ab4653c50f680fbc2e7d7",
                "md5": "091f55a3b07f1d959c04060c5571a958",
                "sha256": "b07ba8b0ebcde4eba51b19cd689d6c0db5c5f15a316f1a7b07c98f48af75c252"
            },
            "downloads": -1,
            "filename": "bite_parser-0.2.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "091f55a3b07f1d959c04060c5571a958",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.9",
            "size": 19396,
            "upload_time": "2024-10-27T08:23:14",
            "upload_time_iso_8601": "2024-10-27T08:23:14.350984Z",
            "url": "https://files.pythonhosted.org/packages/ab/5f/147f2d06a3df0bd626bd7eb2cd20c46ff62cd33ab4653c50f680fbc2e7d7/bite_parser-0.2.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c0cd0e621c1d031fbfc26c2c918cd524e51899b262db28f0bbfbabb361991bf4",
                "md5": "479b714519221583cdbda8b673971ea0",
                "sha256": "44e19586f099501a343ea3514169d0fbe4ae83a2d97ba920c38492cdffbb42a1"
            },
            "downloads": -1,
            "filename": "bite_parser-0.2.5.tar.gz",
            "has_sig": false,
            "md5_digest": "479b714519221583cdbda8b673971ea0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.9",
            "size": 16965,
            "upload_time": "2024-10-27T08:23:15",
            "upload_time_iso_8601": "2024-10-27T08:23:15.829417Z",
            "url": "https://files.pythonhosted.org/packages/c0/cd/0e621c1d031fbfc26c2c918cd524e51899b262db28f0bbfbabb361991bf4/bite_parser-0.2.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-27 08:23:15",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "jgosmann",
    "github_project": "bite-parser",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "bite-parser"
}
        
Elapsed time: 0.35059s