{"id":4381,"library":"pyandoc","title":"pyandoc","description":"pyandoc is an unmaintained Python wrapper for Pandoc, the universal document converter. It allows for converting text document formats by interacting with a Document object's attributes. The last release was version 0.2.0 in February 2016, and the project is no longer actively developed. Users seeking a current Pandoc wrapper for Python should consider 'pypandoc' instead.","status":"abandoned","version":"0.2.0","language":"python","source_language":"en","source_url":"http://github.com/kennethreitz/pyandoc","tags":["pandoc","document conversion","text processing","abandoned"],"install":[{"cmd":"pip install pyandoc","lang":"bash","label":"PyPI (unmaintained)"}],"dependencies":[{"reason":"pyandoc is a wrapper and requires a separate installation of Pandoc on the system PATH.","package":"Pandoc","optional":false}],"imports":[{"note":"The primary interaction is through a 'pandoc' module, not directly importing Document from the top-level package.","wrong":"from pyandoc import Document","symbol":"Document","correct":"import pandoc\ndoc = pandoc.Document()"}],"quickstart":{"code":"import pandoc\n\n# Ensure Pandoc is installed and accessible in your system's PATH.\n# For example, on Ubuntu/Debian: sudo apt-get install pandoc\n# Or refer to Pandoc's official installation guide.\n\n# Create a Document object\ndoc = pandoc.Document()\n\n# Assign Markdown content\ndoc.markdown = '''# Hello from pyandoc\n\n* This is a list item\n* Another item with **bold** text'''\n\n# Convert to reStructuredText\nrst_output = doc.rst\nprint(\"\\n--- reStructuredText Output ---\\n\")\nprint(rst_output)\n\n# Convert to HTML\nhtml_output = doc.html\nprint(\"\\n--- HTML Output ---\\n\")\nprint(html_output)","lang":"python","description":"This quickstart demonstrates how to initialize a `pandoc.Document` object, assign content in Markdown, and then convert it to other formats like reStructuredText and HTML by accessing the respective properties. Ensure Pandoc is installed separately on your system for `pyandoc` to function."},"warnings":[{"fix":"Migrate to an actively maintained Pandoc wrapper like 'pypandoc'. This library provides similar functionality and is regularly updated.","message":"Project is abandoned and unmaintained. pyandoc has not been updated since February 2016. It is highly likely to be incompatible with recent Python versions (3.6+) and newer Pandoc releases, leading to runtime errors or unexpected behavior.","severity":"breaking","affected_versions":"0.2.0 (all versions)"},{"fix":"Install Pandoc separately via your system's package manager (e.g., `sudo apt-get install pandoc` on Debian/Ubuntu, `brew install pandoc` on macOS) or by downloading an installer from the official Pandoc website. Verify installation by running `pandoc --version` in your terminal.","message":"Lack of direct Pandoc installation. pyandoc is just a wrapper; it does not install Pandoc itself. Users must manually install Pandoc and ensure it's available in their system's PATH for pyandoc to work. Failure to do so will result in errors when attempting conversions.","severity":"gotcha","affected_versions":"0.2.0 (all versions)"},{"fix":"Avoid using pyandoc in Python 3.x projects. For Python 3.x, use 'pypandoc', which actively supports current Python versions and has dropped Python 2.x support.","message":"Python 2.x compatibility. While pyandoc was released with Python 2.6-3.5 compatibility, Python 2.x is officially end-of-life. Using pyandoc in a modern Python 3 environment without legacy shims is not recommended and may cause issues.","severity":"deprecated","affected_versions":"0.2.0 (all versions)"}],"env_vars":null,"search_vec":"'0.2.0':34 '2016':37 'abandon':63 'activ':44 'allow':15 'attribut':28 'consid':55 'convers':60 'convert':13,17 'current':49 'develop':45 'document':12,19,25,59 'februari':36 'format':20 'instead':57 'interact':22 'last':30 'longer':43 'object':26 'pandoc':9,50,58 'process':62 'project':40 'pyandoc':1,2 'pypandoc':56 'python':6,53 'releas':31 'seek':47 'text':18,61 'univers':11 'unmaintain':5 'user':46 'version':33 'wrapper':7,51","created_at":"2026-04-12T08:53:20.494153+00:00","updated_at":"2026-04-16T18:18:41.519251+00:00","problems":[{"fix":"Ensure the `pyandoc` package is correctly installed using `pip install pyandoc`. Then, use `import pandoc` as specified in the library's documentation.","cause":"The `pyandoc` library is installed via `pip install pyandoc`, but its usage pattern requires `import pandoc`. This error occurs if the `pyandoc` package itself is not installed, or if the Python environment cannot find the installed `pyandoc` package when `import pandoc` is attempted.","error":"ModuleNotFoundError: No module named 'pandoc'"},{"fix":"Install the `pandoc` universal document converter directly on your operating system (e.g., via Homebrew on macOS, `apt` on Debian/Ubuntu, `choco` on Windows, or by downloading the installer from the official Pandoc website: `https://pandoc.org/installing.html`). Ensure the `pandoc` executable's location is included in your system's PATH.","cause":"`pyandoc` is a Python wrapper that relies on the external `pandoc` command-line utility. This error indicates that the `pandoc` executable is either not installed on your system or is not found in your system's PATH environment variable.","error":"OSError: You probably do not have pandoc installed."},{"fix":"Perform conversions by setting the source content to the appropriate input format attribute and reading the result from the desired output format attribute. For example: `doc = pandoc.Document(); doc.markdown = '# Hello'; html_output = doc.html`.","cause":"Unlike its successor `pypandoc` which provides a `convert()` method, `pyandoc` (version 0.2.0) primarily handles conversions by assigning source content to an input format attribute (e.g., `doc.markdown`) and retrieving the converted output from an output format attribute (e.g., `doc.rst`). Attempting to call a `convert()` method on a `pyandoc.Document` object will result in an `AttributeError`.","error":"AttributeError: 'Document' object has no attribute 'convert'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"0.2.0","cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"http://github.com/kennethreitz/pyandoc","docs":null,"changelog":null,"pypi":"https://pypi.org/project/pyandoc/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["serialization"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-06-28","last_verified":"2026-08-29","next_check":"2026-07-28","install_tag":null}}