John Colvin
c5b73eaace
diag: Add log level config to py plugins
2025-06-10 14:54:47 +00:00
John Colvin
584ec6f7e8
fix: Init shared_ptr w/ default obj (not null)
...
Prob a typo
2025-06-10 06:53:58 +00:00
John Colvin
ccd8ea4056
fix build: Remove include of non-existent header
...
I created the file locally, but ended up not using it and forgot to remove an
include before I pushed.
2025-06-10 05:41:44 +00:00
John Colvin
606526a1d9
fix build: Always return value in non-void fn
2025-06-10 05:34:25 +00:00
John Colvin
0a5f1eb825
fix: Don't compare size_t to -1 in SmallString num parsers
2025-06-10 05:33:12 +00:00
John Colvin
968d33adb6
refactor: Manage all py plugins (md and exe) in one class
...
All calls to/from python are performed on one thread via a simple
message queue (necessary because of the global interpreter lock).
2025-06-09 06:33:29 +00:00
John Colvin
000ac9bb00
diag: Log incoming books at Info level in bybit_md_provider
2025-06-09 06:06:50 +00:00
John Colvin
c56246a59f
chore: Add bybit execution config to bybit_dev profile
2025-06-09 06:06:50 +00:00
John Colvin
5e66857fde
Hardcode bybit_md_provider to use testnet
...
TODO: Add bybit md config for this and other params (api credentials,
symbols to subscribe, etc.)
2025-06-09 06:06:50 +00:00
John Colvin
90f2a80568
fix: Include fill id in format str for ExecutionReport
2025-06-09 06:06:50 +00:00
John Colvin
453d516acf
dev qol: Bind PySecurity __format__ to fmt::formatter impl
2025-06-09 06:06:50 +00:00
John Colvin
8f5338d672
refactor: Change floats to doubles in py bridge types
...
Getting rounding errors with floats
2025-06-09 06:06:50 +00:00
John Colvin
8774e55a40
refactor: Use SmallString instead of std::array in ExchangeFillID
2025-06-09 06:06:50 +00:00
John Colvin
c1ba8c177e
Add py bybit exe config to bybit_dev profile
2025-06-09 06:06:50 +00:00
John Colvin
2174162081
refactor: Consolidate all py interop into single lib
...
It was just too hard trying to make it work with separate libs. The
main issue was getting the python md and execution modules to
recognize PySecurityList and other types defined in the core module.
2025-06-09 06:06:50 +00:00
John Colvin
44948ab4db
refactor: Move tick fns into gen-purpose tick_utils.h
2025-06-09 06:02:35 +00:00
John Colvin
276c80309f
Change bybit_dev symbols.conf to list bybit futs (not spots)
2025-06-09 06:02:35 +00:00
John Colvin
a5bc7ecde0
fix: Actually use configured logger in bybit_md_provider.py
2025-06-09 06:02:35 +00:00
John Colvin
d55b5a434e
dev qol: Reduce noisy logs in PositionServicePNLHelper
2025-06-09 06:02:35 +00:00
John Colvin
9204695a8c
build: Add cmake script to sym link py module and plugins
...
We have several of these (python_core, python_md, python_execution),
so the repetative boilerplate code was starting to pile up.
2025-06-09 06:02:35 +00:00
John Colvin
0ef0200f10
dev qol: Add pyrightconfig.json for type hints in py/c++ bridge
2025-06-09 06:02:35 +00:00
John Colvin
d4c370729d
Tweak py to get rid of false positive type hint warns
2025-06-09 06:02:34 +00:00
John Colvin
d54d1b7860
feat: Support python execution plugins
2025-06-09 06:02:34 +00:00
John Colvin
680090fde7
refactor: Move py security (and related types) to python_core lib
...
So the execution gw plugins can use it (as well as the md plugins).
2025-06-09 06:02:34 +00:00
John Colvin
c89b27d0c0
fix: Add missing switch cases for bybit & gateio
2025-06-09 05:58:37 +00:00
John Colvin
5e876b3b4d
fix: Initialize bybit secs as perp futs (not spots)
2025-06-09 05:58:37 +00:00
John Colvin
0837584301
dev qol: Add wait/notify functionality to ConcurrentQueue
2025-06-09 05:58:37 +00:00
John Colvin
7b926ceb76
dev qol: Add ConcurrentValueStore, with notify/wait functionality
...
Uses std::condition_variable
2025-06-09 05:58:37 +00:00
John Colvin
e42d814c84
dev qol: Add gen-purpose validation fns for execution gws
2025-06-09 05:58:37 +00:00
John Colvin
933444ffc7
build: Use new gen-purpose python cmake fns in py md proj
...
Significantly simplifies CMakeLists.txt
2025-06-09 05:58:37 +00:00
John Colvin
2dec5812f6
dev qol: Add fn to make Stopwatch and start it at once
2025-06-09 05:58:37 +00:00
John Colvin
237f525263
chore: Use same log format as sparkd in py md plugins
2025-06-09 05:58:37 +00:00
John Colvin
8a5fcfbe04
improvement: Set PyBook data in single call to reduce interop overhead
2025-06-09 05:58:37 +00:00
John Colvin
ccc8faf353
Reduce log noise in py md providers
2025-06-09 05:58:37 +00:00
John Colvin
4c983c6ec1
doc: Improve py md readme
...
* Put examples in a table
* Show command to create symlinks for intellisense
2025-06-09 05:58:37 +00:00
John Colvin
e7ee1e02dd
refactor: Redesign py md so it doesn't lock the global interpreter
...
We can only embed one interpreter in the sparkd process, so all py
plugins need to share it.
* Move core py interop code to new lib_python_core. We're about to add a
new lib for py execution, so it needs to be accesible from both
execution and md libs
* Fix typo for type hint in py_md_utils.py
* Run py md providers on background thread
* Rename MdSink -> MdBridge
2025-06-09 05:54:10 +00:00
John Colvin
63d5e70add
dev qol: Add to_chrono fns to TimeSpan
2025-06-06 17:41:53 +00:00
John Colvin
5a77102bd2
dev qol: Add -> operators to ValueWrapper for convenience
...
So we can type "foo->" instead of "foo.value()" (much shorter!)
2025-06-06 17:41:53 +00:00
John Colvin
ca1799fa68
build: Link against system installed ssl to support py interop
...
Unless we want to build python packages ourselves, the underlying clibs
they use link to the system installed ssl. Notably, the requests module.
2025-06-06 17:41:53 +00:00
John Colvin
716be146b9
improvement: Generate py stubs for md providers
...
Provides intellisense for the python_md_module
2025-06-06 17:41:53 +00:00
John Colvin
a57d38951e
cleanup: Get rid of unecessary namespace prefixes
2025-06-06 17:41:53 +00:00
John Colvin
99dccbf6d1
cleanup: Get rid of "PyList" classes, bind to stl vector instead
...
I wasn't aware this was possible until recently.
2025-06-06 17:41:53 +00:00
John Colvin
5f16e88bcf
refactor: Move SimpleOrderKeyMap from binance_execution to lib_spark
...
It provides basic functionality that will be useful in other execution gateways.
2025-06-06 17:41:53 +00:00
John Colvin
092ac21fce
chore: Add smart parse and pretty name fns for proto enums
...
Mainly to ease the pain of representing enums as strings in python md
and execution plugins
2025-06-06 17:41:53 +00:00
John Colvin
2cd75209d2
refactor: Move ErrorList from binance_execution to lib_spark
...
It provides basic functionality that will be useful elsewhere
2025-06-06 17:41:53 +00:00
John Colvin
9dc5de4bdb
refactor: Use SmallString std::array in AccountName
2025-06-06 17:41:53 +00:00
John Colvin
34e7e1e01c
refactor: Use SmallString instead of std::array in ExchangeOrderID
2025-06-06 17:41:53 +00:00
John Colvin
f3d32dd918
Add our own "SmallString" class for fixed cap strings
...
This will replace the std::array<char, N> we use in ExecutionReport, etc.
among other things
2025-06-06 17:41:53 +00:00
John Colvin
83e3780964
refactor: Move ExecutionReportStore to lib_spark
...
From lib_binance_execution
2025-06-04 04:37:02 +00:00
Adeel Khan
5d9c7502c9
CLEANUP: BYBIT Symbols.conf.
2025-06-04 04:37:02 +00:00