| [gw8] darwin -- Python 3.12.12 /Users/cao/.pyenv/versions/3.12.12/bin/python3.12
|
| tests/test_h5_end_to_end.py:137: in test_e2e_h5_bundle_buys_all_three_at_target_size
|
| result = executor.execute_job(_CUIXIA_BUNDLE_PAYLOAD)
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
| _exec_direct_side_effect = <function test_e2e_h5_bundle_buys_all_three_at_target_size.<locals>._exec_direct_side_effect at 0x12c571300>
|
| _getattr = <function test_e2e_h5_bundle_buys_all_three_at_target_size.<locals>._getattr at 0x12c5719e0>
|
| _resolve_price_side_effect = <function test_e2e_h5_bundle_buys_all_three_at_target_size.<locals>._resolve_price_side_effect at 0x12c5716c0>
|
| executor = <rtrader.services.buy_trader_executor.BuyTraderExecutor object at 0x12c3126c0>
|
| expected_shares = {'DINO': 22, 'PATH': 131, 'TALO': 89}
|
| mock_direct = <MagicMock name='_execute_direct_trade' id='5038291616'>
|
| mock_settings = <MagicMock name='settings' id='5038331024'>
|
| mocks = {'add_trading_plan': <MagicMock id='5036994784'>, 'broker': <MagicMock id='5038911616'>, 'send_discord_async': <MagicMock id='5036251168'>}
|
| rtrader/services/buy_trader_executor.py:599: in execute_job
|
| return self._execute_h5_buy(job, symbol_entries, trading_day)
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
| deadline_info = 'no_deadline'
|
| gap_days = 0
|
| h5_accounts = ['cuixia', 'miaoyong', 'yuchao']
|
| instrument_preference = 'stock'
|
| is_short_job = False
|
| job = BuyTraderJob(job_id='e2e-cuixia-bundle', symbol='PATH', metadata={'trading_day': '2026-04-29', 'broker_backend': 'alpa...}, {'symbol': 'DINO', 'allocation_pct': 0.3333333333333333}, {'symbol': 'TALO', 'allocation_pct': 0.3333333333333333}])
|
| metadata_allocation = 1.0
|
| min_gap_threshold = 2
|
| next_candidate = datetime.date(2026, 4, 30)
|
| next_trading_day = datetime.date(2026, 4, 30)
|
| payload = {'job_id': 'e2e-cuixia-bundle', 'metadata': {'account_nick': 'cuixia', 'allocation_pct': 1.0, 'alpaca_mode': 'live', '...}, {'allocation_pct': 0.3333333333333333, 'symbol': 'DINO'}, {'allocation_pct': 0.3333333333333333, 'symbol': 'TALO'}]}
|
| plan_allocation_pct = 1.0
|
| self = <rtrader.services.buy_trader_executor.BuyTraderExecutor object at 0x12c3126c0>
|
| sequence = 1
|
| symbol_entries = [{'allocation_pct': 0.3333333333333333, 'metadata': {}, 'order_sequence': 1, 'symbol': 'PATH', ...}, {'allocation_pct'...bol': 'DINO', ...}, {'allocation_pct': 0.3333333333333333, 'metadata': {}, 'order_sequence': 3, 'symbol': 'TALO', ...}]
|
| trading_day = datetime.date(2026, 4, 29)
|
| trading_day_str = '2026-04-29'
|
| rtrader/services/buy_trader_executor.py:2885: in _execute_h5_buy
|
| expected_picks_primary = int(
|
| E TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'
|
| BuyConfig = <class 'rtrader.buy_decider.core.BuyConfig'>
|
| base_pct = 0.05
|
| broker = <MagicMock id='5038911616'>
|
| cap_pct = 0.1
|
| decide_buy = <function decide_buy at 0x1294d0180>
|
| equity = 27775.0
|
| job = BuyTraderJob(job_id='e2e-cuixia-bundle', symbol='PATH', metadata={'trading_day': '2026-04-29', 'broker_backend': 'alpa...}, {'symbol': 'DINO', 'allocation_pct': 0.3333333333333333}, {'symbol': 'TALO', 'allocation_pct': 0.3333333333333333}])
|
| self = <rtrader.services.buy_trader_executor.BuyTraderExecutor object at 0x12c3126c0>
|
| symbol_entries = [{'allocation_pct': 0.3333333333333333, 'metadata': {}, 'order_sequence': 1, 'symbol': 'PATH', ...}, {'allocation_pct'...bol': 'DINO', ...}, {'allocation_pct': 0.3333333333333333, 'metadata': {}, 'order_sequence': 3, 'symbol': 'TALO', ...}]
|
| trading_day = datetime.date(2026, 4, 29)
|