refix 0.3.2

A FIX engine written in pure Rust with Python bindings
Documentation

ReFIX

crates-badge pypi-badge docs-badge codecov CI License: MIT License: Apache 2.0

ReFIX is a FIX engine written in pure Rust with first-party bindings for Python.

Documentation

[!WARNING] ReFIX is in early development. Currently, it supports reading TagValue FIX messages and code generation for typed messages. Message serialisation, the network and session layers are not implemented yet, and APIs change between 0.x releases.

Quick start

The Python bindings require Python 3.12 or later.

pip install refix refix-fix44
import refix
from refix_fix44 import CODEC, NewOrderSingle

for record in refix.decode_log("fix.log", CODEC):
    if isinstance(record.message, NewOrderSingle):
        print(record.message.header.sender_comp_id, record.message.cl_ord_id)

In Rust, cargo add refix refix-fix44; see refix-fix44.

Why ReFIX?

ReFIX builds FIX building blocks with first-class support for both Rust and Python. See the longer blog post for the motivations. If you need a complete FIX 4.4 engine today, see HotFIX, which I built before ReFIX.

Reading a message from Python is 7 to 8 times faster than the QuickFIX bindings and 50 to 90 times faster than simplefix. See the benchmarks.

Near-term goals

Reading and typing messages works in both languages. Planned next:

  • stock packages for more FIX versions
  • building and serialising messages
  • the session layer

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.