jgrusewski
da91c412ab
fix(cli): distinct paper-envelope refuse message + reject negative --paper-envelope (Task 9 review)
...
Two execute-CLI gaps from the C3 port:
- `execute_multistrat`'s generic `except Exception` caught the ValueError `plan_and_record` raises
when a paper-envelope is refused (account not paper) and printed it as a connectivity failure
("broker error: ... reachable? ... creds/gateway set?") — misleading for a deliberate safety
refusal. `execute_bybit` had no try/except at all, so the same refusal from `run_bybit_testnet`
surfaced as a raw traceback. Both commands now catch `ValueError` distinctly, print
"paper-envelope refused: <msg>", and exit 1 — same exit code and zero orders placed, just an
honest message.
- `_resolve_paper_envelope` silently fell back to the config default whenever the flag was <= 0.0,
so `--paper-envelope -5` looked identical to "unset" and hid an operator typo. A negative flag
now raises `typer.BadParameter` instead of falling through.
Extends test_cli_execute_helpers.py: the negative-envelope rejection, and two new tests (no live
broker — YahooDataProvider/AlpacaBroker faked, run_bybit_testnet faked) proving each command's
refuse path prints the distinct message and never reaches order placement.
2026-07-11 02:15:12 +02:00
..
2026-06-23 15:13:27 +02:00
2026-06-14 23:35:59 +02:00
2026-06-22 11:16:06 +02:00
2026-07-09 21:07:23 +02:00
2026-07-09 20:58:21 +02:00
2026-06-21 20:18:38 +02:00
2026-07-10 00:12:17 +02:00
2026-06-15 00:20:48 +02:00
2026-06-14 17:03:11 +02:00
2026-06-22 12:21:09 +02:00
2026-06-14 16:45:01 +02:00
2026-06-23 13:38:51 +02:00
2026-06-24 20:21:06 +02:00
2026-06-23 22:45:14 +02:00
2026-07-11 00:58:52 +02:00
2026-06-28 16:17:41 +02:00
2026-07-10 10:09:43 +02:00
2026-06-26 23:19:51 +02:00
2026-07-10 11:06:37 +02:00
2026-07-11 02:15:02 +02:00
2026-06-14 17:11:58 +02:00
2026-07-02 12:51:39 +02:00
2026-06-23 13:38:51 +02:00
2026-06-25 20:34:52 +02:00
2026-07-11 02:15:12 +02:00
2026-06-15 11:27:24 +02:00
2026-06-15 11:24:19 +02:00
2026-06-15 11:13:21 +02:00
2026-07-09 21:17:52 +02:00
2026-07-11 00:48:59 +02:00
2026-06-26 00:32:46 +02:00
2026-07-11 01:27:15 +02:00
2026-06-14 20:06:52 +02:00
2026-06-19 00:18:14 +02:00
2026-06-14 16:45:36 +02:00
2026-06-19 19:38:19 +02:00
2026-06-28 09:47:35 +02:00
2026-06-15 11:10:13 +02:00
2026-06-13 17:56:19 +02:00
2026-06-15 00:38:17 +02:00
2026-06-15 00:23:05 +02:00
2026-06-23 00:10:39 +02:00
2026-06-20 17:45:00 +02:00
2026-06-22 08:08:47 +02:00
2026-06-14 19:54:57 +02:00
2026-06-23 00:37:58 +02:00
2026-06-18 10:01:36 +02:00
2026-06-21 20:17:56 +02:00
2026-06-17 12:24:29 +02:00
2026-06-28 14:05:18 +02:00
2026-07-10 10:53:17 +02:00
2026-07-09 00:02:20 +02:00
2026-07-10 02:11:52 +02:00
2026-06-14 12:23:09 +02:00
2026-07-09 14:16:18 +02:00
2026-07-09 13:37:00 +02:00
2026-07-10 01:34:35 +02:00
2026-07-10 02:11:52 +02:00
2026-07-09 14:16:18 +02:00
2026-06-09 12:21:47 +02:00
2026-06-14 20:06:52 +02:00
2026-06-21 20:54:50 +02:00
2026-06-13 19:09:08 +02:00
2026-06-23 09:04:18 +02:00
2026-06-17 00:22:38 +02:00
2026-06-21 23:32:36 +02:00
2026-06-21 19:33:15 +02:00
2026-06-22 09:17:01 +02:00
2026-06-14 19:54:08 +02:00
2026-06-13 02:01:04 +02:00
2026-06-14 23:05:03 +02:00
2026-07-11 00:47:15 +02:00
2026-06-26 08:07:42 +02:00
2026-06-27 16:12:37 +02:00
2026-06-13 02:06:30 +02:00
2026-06-22 19:56:51 +02:00
2026-06-21 19:45:32 +02:00
2026-06-21 19:33:15 +02:00
2026-06-21 21:06:01 +02:00
2026-06-23 09:04:18 +02:00
2026-06-24 17:27:10 +02:00
2026-06-14 11:45:42 +02:00
2026-06-09 13:52:32 +02:00
2026-06-21 20:14:30 +02:00
2026-07-09 14:16:18 +02:00
2026-06-14 17:29:37 +02:00
2026-06-22 09:22:07 +02:00
2026-06-09 19:20:23 +02:00
2026-06-14 23:21:08 +02:00
2026-07-10 10:17:52 +02:00
2026-07-09 23:29:07 +02:00
2026-07-07 20:22:30 +02:00
2026-07-07 20:22:30 +02:00
2026-06-26 00:46:10 +02:00
2026-06-23 09:04:18 +02:00
2026-06-14 17:11:58 +02:00
2026-06-14 16:46:05 +02:00
2026-06-23 10:53:15 +02:00
2026-06-21 23:29:30 +02:00
2026-06-28 14:04:03 +02:00
2026-06-14 17:39:29 +02:00
2026-06-22 20:22:31 +02:00
2026-06-26 00:46:10 +02:00
2026-06-21 10:37:05 +02:00
2026-06-14 23:18:09 +02:00
2026-07-09 21:22:06 +02:00
2026-06-14 16:46:45 +02:00
2026-06-14 17:29:37 +02:00
2026-06-19 19:49:46 +02:00
2026-06-21 20:30:05 +02:00
2026-06-22 08:18:22 +02:00
2026-06-26 16:33:47 +02:00
2026-06-22 20:22:31 +02:00
2026-06-20 20:11:07 +02:00
2026-06-13 02:24:41 +02:00
2026-06-22 16:59:24 +02:00
2026-06-25 01:39:07 +02:00
2026-06-15 00:34:55 +02:00
2026-06-15 00:28:40 +02:00
2026-06-25 23:16:18 +02:00
2026-06-21 23:37:58 +02:00
2026-06-23 13:38:51 +02:00
2026-06-23 13:38:51 +02:00
2026-06-23 13:38:51 +02:00
2026-06-21 20:16:15 +02:00