paper FAK parity: no ask inside the protected band -> honest miss, not a pretend fill

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
jaxperro
2026-07-15 23:48:56 -04:00
parent d833168c05
commit 646139dfa3
4 changed files with 158 additions and 5 deletions
+3 -2
View File
@@ -336,8 +336,9 @@ class LedgerPaperExecutor(PaperExecutor):
def buy(self, token_id, shares, price, meta):
r = super().buy(token_id, shares, price, meta)
self.fills.append({"side": "BUY", "token": token_id,
"shares": r["filled_shares"], "price": r["price"]})
if r["ok"]: # a paper FAK no-match is not a fill
self.fills.append({"side": "BUY", "token": token_id,
"shares": r["filled_shares"], "price": r["price"]})
return r
def sell(self, token_id, shares, price, meta):