Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

TL-Store

TL-Store 是 TradeLearn 的适配器集合,负责接入不同的交易平台与行情来源。适配器按组件独立维护,用户通过 TradeLearn 的 Store 接口配置和使用。

当前发行包为 tl-store,首个内置组件是 cTrader,导入路径为 tl_store.ctrader。当前支持的框架为 NautilusTrader,用于承接执行与行情能力;后续适配按组件扩展。

接入 TradeLearn

TradeLearn 负责可选依赖的版本锁定:

python -m pip install "trade-learn[nautilus,tl-store]==0.3.2"

正式 TradeLearn 0.3.2 选择 Store 0.2.1a4,而不是 a6。 独立安装 a6 不等于升级并验证了该固定组合。请使用所选 TL 发行版对应的版本和导入方式;新的 bt.stores.NautilusStore、普通 bt.Strategy 透明接线仍属 TL 后续候选,不能套用到旧正式版。

a5新增原生只读观察状态及有界订单/成交分页,a6新增标准 NA 盘口订阅和只读拒绝码。适配器独立升级不要求未变化的 TradeLearn 代码同时发行。

下一修复候选 0.2.1a7 正在验收盘口观测精度与下单步长的解耦;尚未发布,不能使用该版本的公网安装命令。已有a6字节不覆盖。

独立安装

当前已发布版本为 0.2.1a6(Alpha),使用 CPython 3.13 或 3.14:

python -m pip install "tl-store==0.2.1a6"
python -m pip check

当前实现依赖固定为未修改的官方 nautilus_trader==2.0.0rc7。构建和离线测试通过,不代表真实券商账户已获得全部能力或交易权限。

平台 已发布 wheel 验证范围
macOS Apple Silicon CPython 3.13 / 3.14 已安装运行离线测试;3.13完成随包对应源码离线重建
Linux x86_64,glibc 2.34+ CPython 3.13 / 3.14 已安装运行离线测试;3.13完成随包对应源码离线重建
Windows x64 CPython 3.13 / 3.14 仅构建通过,尚无同等运行验证
Linux ARM64,glibc 2.34+ CPython 3.13 / 3.14 仅构建通过,尚无同等运行验证

本次发行矩阵不包含 macOS Intel wheel。

当前框架:NautilusTrader

from tl_store import ctrader

除通过TL接入外,当前适配器也可独立用于NautilusTrader,不要求安装TL或监控服务。适配器提供 CTraderDataClientFactory、CTraderExecutionClientFactory、账户配置及原生扩展 tl_store.ctrader._native。通过官方 NA 客户端工厂接口装配;仅采集数据时使用数据工厂保留的只读会话,不必创建执行客户端。

配置、能力限制、只读采集和盘口接口见 cTrader 使用说明。

能力与边界

  • 券商元数据解析、报价、账户观察、执行报告、普通 Market IOC、撤单及指定持仓平仓。
  • 复用原生 DepthBook 输出标准 NA 已观察盘口;真实账户/品种的深度权限须单独核验。
  • 时间 K 线使用官方 NA 内部聚合,不另建聚合或执行循环。
  • Limit、止损、追踪和关联单仍有适配器实现限制,不能从 NA 枚举或券商协议能力推断已支持。
  • 缺少的盘口源时间、完整性和报价数量不伪造为真实市场事实。

构建与测试

使用 Rust 1.97.0、CPython 3.13/3.14、maturin 1.13.1;发行元数据以根目录 pyproject.toml 为准。

python -m pip install "maturin==1.13.1"
python tools/check_release.py
python tools/build_release.py --out raw-dist
cargo vendor --locked --versioned-dirs \
  --manifest-path adapters/ctrader/native/Cargo.toml recipient-vendor

逐个处理实际生成的 wheel,将占位文件名替换为真实名称:

python tools/finalize_wheel.py raw-dist/<wheel>.whl dist/<wheel>.whl \
  --vendor-dir recipient-vendor
python tools/check_release.py --wheel dist/<wheel>.whl

构建器启用优化和编译路径重映射。Linux必须通过 manylinux 2.34 审计,不能靠重命名伪造 ABI 兼容。CI构建八个 wheel,在 macOS ARM64/Linux x86_64运行离线测试,并在其3.13任务中离线重建对应源码;Windows/Linux ARM64只证明构建。

独立测试需先安装已构建的原生扩展:

python -m pip install "pytest>=9,<10"
python -m pytest adapters/ctrader/tests \
  --ignore=adapters/ctrader/tests/test_store.py
cargo test --locked --manifest-path adapters/ctrader/native/Cargo.toml --lib

test_store.py 另需兼容的 TL adapter API 2/interface 1。测试采用合成身份、回环传输和确定性事件,不连接真实账户或下单。

发行工作流读取成功且源码一致的 CI 产物,通过 GitHub OIDC 发布 PyPI;整理文档不要求重新构建或覆盖已发布 wheel。

使用说明

项目仍在持续完善,建议先在测试环境验证,再根据实际需求使用。请妥善保管账户与凭据,避免提交敏感信息。

许可见 LICENSE、COPYING、COPYING.LESSER 和 NOTICE。

Metadata

Release files for tl-store 0.2.1a7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for tl-store 0.2.1a7
File Actions
tl_store-0.2.1a7-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details for tl_store-0.2.1a7-cp314-cp314-win_amd64.whl
tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.34+ x86-64 Details for tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_x86_64.whl
tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_aarch64.whl CPython 3.14 CPython 3.14 Linux glibc 2.34+ ARM64 Details for tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_aarch64.whl
tl_store-0.2.1a7-cp314-cp314-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 macOS 11.0+ ARM64 Details for tl_store-0.2.1a7-cp314-cp314-macosx_11_0_arm64.whl
tl_store-0.2.1a7-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details for tl_store-0.2.1a7-cp313-cp313-win_amd64.whl
tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.34+ x86-64 Details for tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_x86_64.whl
tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.34+ ARM64 Details for tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_aarch64.whl
tl_store-0.2.1a7-cp313-cp313-macosx_11_0_arm64.whl CPython 3.13 CPython 3.13 macOS 11.0+ ARM64 Details for tl_store-0.2.1a7-cp313-cp313-macosx_11_0_arm64.whl

Total release size: 373.7 MB

Release files / tl_store-0.2.1a7-cp314-cp314-win_amd64.whl

Download URL tl_store-0.2.1a7-cp314-cp314-win_amd64.whl
Size 46.5 MB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
9fb05f5beaad1de36e10896a5e8f82021474a2a14fdf00fb40dc05814dad641b
BLAKE2b-256 checksum
How to use checksums
4a993193247bbed472d2089c0ae0eb37ea0897bdfc93592058ccc584357d32a3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_x86_64.whl

Download URL tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_x86_64.whl
Size 46.9 MB
Tags CPython 3.14 Linux glibc 2.34+ x86-64
SHA-256 checksum
How to use checksums
e0bcb0f8c98f4dd3ae8a8a738a043c8fcadeb3a41654c223e7a24de7f8d25ded
BLAKE2b-256 checksum
How to use checksums
a82d39de87b427f018c0f53939c0cab0c3ba9ad1333976dc65cff81c5b28bce5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_aarch64.whl

Download URL tl_store-0.2.1a7-cp314-cp314-manylinux_2_34_aarch64.whl
Size 47.0 MB
Tags CPython 3.14 Linux glibc 2.34+ ARM64
SHA-256 checksum
How to use checksums
66fa55977eec8263be9fe0770f9844f5d68159df987eb299bcd45b5c8b9d7d63
BLAKE2b-256 checksum
How to use checksums
0de9703b1cef766bc1562f0ccf2351f5092ae4ed6629624f3879d20e2e8c5bad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp314-cp314-macosx_11_0_arm64.whl

Download URL tl_store-0.2.1a7-cp314-cp314-macosx_11_0_arm64.whl
Size 46.6 MB
Tags CPython 3.14 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
a03d6dac177f7661e1600b507693834e48bdadc100e7776db76329e563985797
BLAKE2b-256 checksum
How to use checksums
914d0a29e1c92186565ce212a72e3d48cae3b8ecdbdf53dcce9819f582331aff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp313-cp313-win_amd64.whl

Download URL tl_store-0.2.1a7-cp313-cp313-win_amd64.whl
Size 46.2 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
04c478418e39e722292a8060a46fa6d3e2f2ebd8a5d5f90a1e0dd432622f67cc
BLAKE2b-256 checksum
How to use checksums
d160dd5f1c847efd2b1a77ca681a76fed3718041c26a50a5746ef80d655f85bb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_x86_64.whl

Download URL tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_x86_64.whl
Size 46.9 MB
Tags CPython 3.13 Linux glibc 2.34+ x86-64
SHA-256 checksum
How to use checksums
a519a25f0124986951d5e242e3f569e9131dffba6f87040576bd96070f980392
BLAKE2b-256 checksum
How to use checksums
e033da3d39f3bb1a2aa3c0fd17d8e42d7d0aabcf27eb57d54a851e4f1980ba3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_aarch64.whl

Download URL tl_store-0.2.1a7-cp313-cp313-manylinux_2_34_aarch64.whl
Size 47.0 MB
Tags CPython 3.13 Linux glibc 2.34+ ARM64
SHA-256 checksum
How to use checksums
92ababf72667387b3842938d408f153dc1570c230ab7f6a2eccd3c2cb839c558
BLAKE2b-256 checksum
How to use checksums
3fd97a0c79377b45a59e2172e60ad7442fb8cf4b42ea4cb2baaac071bb6f6975
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Release files / tl_store-0.2.1a7-cp313-cp313-macosx_11_0_arm64.whl

Download URL tl_store-0.2.1a7-cp313-cp313-macosx_11_0_arm64.whl
Size 46.6 MB
Tags CPython 3.13 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
530e6c00b5a17259a4e2207ba6c10426f9b0dfef5a06287018fed8e9ead2b2f4
BLAKE2b-256 checksum
How to use checksums
b66c28b9d095975fb63a51c2c79b4a34cb443edc45bfc49606db8a977c56c966
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

Security for tl-store 0.2.1a7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 8 files in this release have been uploaded with provenance metadata.

Select from 8 files

Attestation for tl_store-0.2.1a7-cp314-cp314-win_amd64.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 13, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page