[WIP] Transition to AsyncIO
As discussed in https://github.com/robhagemans/pcbasic/discussions/243, This PR Ports the whole codebase to asyncio.
Todos:
- [ ] Migrate tests to asyncio.
Hi @nmanumr, apologies I haven't had time to look into the PR in detail and indeed to try the code. Part of the problem is that to be honest I'm unfamiliar with the async style of concurrency in Python, and this is obviously a large PR that pervades the whole code base, so would need to brush up, and there's a lot to test manually (e.g. ON KEY and other event driven structures that are difficult to cover in unit tests). Currently I'm mentally more in maintenance mode with this code with even there a backlog building up (the MOD fix definitely needs to go through e.g.). I guess I was hoping support for the web canvas could be built in a more limited way that didn't take the whole code asynchronous...
I do still intend to try this and play with it, just wanted to be open about my limited time/focus on this project and not create unrealistic expectations.
Hi, @robhagemans, I completely forgot that I had opened the PR. I appreciate your openness, and I’ve been thinking about the number of changes as well. Initially, I didn’t expect it to turn into such a large change, so I think it would be worthwhile to look for a simpler solution. In the meantime, let’s close the PR, as this may not be the right approach. I’ll open a new PR once I come up with a simpler solution.