From 935a5ab26cd204125919398045da3db7d308dbf1 Mon Sep 17 00:00:00 2001 From: Miha Kralj Date: Wed, 4 Mar 2026 11:59:42 -0800 Subject: [PATCH] fix(python): align QtlEacp export params with Eacp.Batch signature MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The NativeAOT export had stale parameter names (period, minPeriod, maxPeriod, useMedian) from an older API. Renamed to match the actual Eacp.Batch(minPeriod, maxPeriod, avgLength, enhance) signature. ABI preserved — same 7 params, same types, no Python-side changes needed. --- python/src/Exports.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/python/src/Exports.cs b/python/src/Exports.cs index ec488172..82c65de7 100644 --- a/python/src/Exports.cs +++ b/python/src/Exports.cs @@ -1387,13 +1387,13 @@ public static unsafe partial class Exports catch { return StatusCodes.QTL_ERR_INTERNAL; } } - // Eacp: Pattern A (int period, int min, int max, bool useSimd → int) + // Eacp: (int minPeriod, int maxPeriod, int avgLength, bool enhance → int) [UnmanagedCallersOnly(EntryPoint = "qtl_eacp")] - public static int QtlEacp(double* src, int n, double* dst, int period, int minPeriod, int maxPeriod, int useMedian) + public static int QtlEacp(double* src, int n, double* dst, int minPeriod, int maxPeriod, int avgLength, int enhance) { int v = Chk1(src, dst, n); if (v != 0) return v; - v = ChkPeriod(period); if (v != 0) return v; - try { Eacp.Batch(Src(src, n), Dst(dst, n), period, minPeriod, maxPeriod, useMedian != 0); return StatusCodes.QTL_OK; } + v = ChkPeriod(minPeriod); if (v != 0) return v; + try { Eacp.Batch(Src(src, n), Dst(dst, n), minPeriod, maxPeriod, avgLength, enhance != 0); return StatusCodes.QTL_OK; } catch { return StatusCodes.QTL_ERR_INTERNAL; } }