I'm not a Python programmer.? I would hope that Python has some stock threadpool library for you to use.? Perhaps some of the Python folks could recommend one to you.?
Concurrent programming is hard; most professional programmers can't do it.? You can still handle multiple tickers without concurrent programming though.? There is no reason you need multiple threads.? Just make a callback for each thread (it will run on the TCP socket's thread).? That's far easier and will work well enough.? Like I said, it isn't assured that this single threaded way won't be faster.? Unless you are doing lots of work in your callback (as in doing matrix multiplies or DB queries or something like that), then you are fine.
Hunter
On Wednesday, May 5, 2021, 11:24:56 AM PDT, Patrick C <zenfiretrading@...> wrote:
Hunter, thank you so much. But I've got no idea what you just said to me haha. I am a prime example of a "shade tree" python mechanic. I got no idea how to build an alternator in a car, but I know where it goes haha. I'm trying to build this program for my buddy but I might just tell him that its over my head with multiple stocks that change amount each day. I can actually build this program with multiple stocks. IF.. they didnt change. OR.. IF the number amount didnt change. And I would just tell him... ok copy/paste the new stock name here, here, here, ect ect. But since one day it could be 1 stock, next day 7 stocks. I'm trying to make it so the program just reacts accordingly. I think it might be over my head right now.?