Metadata-Version: 2.1
Name: pyeonclient
Version: 0.2.0
Summary: Nanobind bindings to the eOn C++ client (Matter, Parameters, Potential, Jobs)
Keywords: eOn,AKMC,nanobind,Matter,atomistic
Author-Email: Rohit Goswami <rgoswami@ieee.org>
License: BSD-3-Clause
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: C++
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Programming Language :: Python :: Free Threading :: 2 - Beta
Classifier: Topic :: Scientific/Engineering
Classifier: Operating System :: POSIX :: Linux
Classifier: Operating System :: MacOS
Project-URL: Homepage, https://github.com/TheochemUI/eOn
Project-URL: Documentation, https://theochemuieon.readthedocs.io/
Project-URL: Repository, https://github.com/TheochemUI/eOn
Project-URL: Issues, https://github.com/TheochemUI/eOn/issues
Project-URL: Changelog, https://github.com/TheochemUI/eOn/blob/main/CHANGELOG.md
Requires-Python: >=3.12
Requires-Dist: numpy>=1.26.4
Requires-Dist: readcon>=0.8.0
Provides-Extra: ase
Requires-Dist: ase>=3.22; extra == "ase"
Description-Content-Type: text/markdown

## Install

```bash
pip install pyeonclient
pip install 'pyeonclient[ase]'  # optional
```

# pyeonclient

Nanobind-only bindings for the eOn C++ client library (`libeonclib`).

**No pybind11.** This module supersedes the old unused `with_pybind11` option.

## ABI policy

| Interpreter | Extension build |
|-------------|-----------------|
| CPython ≥ 3.12 (GIL) | **Stable ABI (abi3)** — `Py_LIMITED_API=0x030C0000` |
| CPython ≥ 3.13 free-threaded (`Py_GIL_DISABLED`) | **Free-threaded** (`NB_FREE_THREADED`); stable ABI not available yet |

Meson detects free-threaded vs GIL builds from `sysconfig.Py_GIL_DISABLED` and
sets exactly one of the two modes (same rule as nanobind’s CMake
`STABLE_ABI` + `FREE_THREADED` pair).

## Package layout

```
client/python/
  meson.build              # -Dwith_pyeonclient=true
  pyeonclient/
    __init__.py            # re-exports
    bridge.py              # Structure <-> Matter (server)
  bind/
    module.cpp             # NB_MODULE(_core, ...)
    bind_*.cpp
    eigen_numpy.hpp
```

Artifact: `pyeonclient/_core*.so` (or `_core*.abi3.so`).

## Build

```bash
# needs nanobind>=2.2 on the build Python
meson setup build -Dwith_pyeonclient=true
meson compile -C build
pytest tests/test_pyeonclient_matter.py -v
```

## Design

Bottom-up surface: **Matter**, **Parameters**, **Potential**, enums/I/O —
not a thin job wrapper. Jobs and communicators layer on Matter later.
`.con` I/O uses ConFileIO / readcon-core (same path as `eonclient`).
