-
Notifications
You must be signed in to change notification settings - Fork 970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AsyncScheduler: Ability to schedule сoroutines #357
base: master
Are you sure you want to change the base?
Conversation
Great job! Hope to see this PR merged soon. |
Awesome! Can we get this merged? |
Bump |
bump again. This is a great feature. I pulled the branch and it works perfectly :) |
@davenewham Thanks! You can fork from my fork ;) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe will be smart to add python 3.9 and test it also
I have related pull request #391 and i noticed yours now. But you solution for running corutines is much better....mine was mostly concerned about handling os signals fast (even with long sleeps/waits between runs of run_pending) i think we should join our efforts since you will eventualy have to write about pitfalls of asyncio and fact it will run concurenly all sechuded jobs... so control/data race condition may emerge |
@07pepa, Hello! I'm so sorry for so long to respond. I am always in favor of cooperation. I suggest you make a PR to my fork. I promise to review it soon as possible. |
# Conflicts: # .travis.yml # schedule/__init__.py
i will try to get it to it in next few weeks |
Hi @SijmenHuizenga!
I don't have a problem with dropping support for python2 and python3.5. Then it would be easy to merge the tests and library support would be greatly simplified. But it doesn't have to be done right now, I wouldn't want to do that work as part of this request. Besides, while this request is pending, I'm getting conflicts( You can make an issue and I will do it in the next request.
There is no sense in explicitly dividing tasks into synchronous and asynchronous. Asynchronous scheduler can handle all types. So the problem is with the methods:
I don't agree that simplicity comes from having a single file. I thought that in this case simplicity meant ease to use and a low threshold to get into the library. I may have misinterpreted the concept of simplicity of this library. But I agree to discuss the possibility of simplicity by separating classes into separate files and by designing a simple and clear architecture. In my opinion it is easier to navigate the code base of the library this way, but I also respect your opinion on this.
Here I agree and disagree. This change is due to the extension of the python language - it became possible to declare asynchronous functions(coroutines), and the lack of support for asynchronous functions and gave a lot of limitations of this library in the modern language. Those examples you described are
I honestly don't like that idea very much either. There would be a need for constant synchronization, and besides I have made changes to the organization of the code base, which would make any synchronization an unpleasant process. I propose to consider this as an extreme case. P.S. Thanks for the feedback. I hope that we will soon come to a common solution that satisfies everyone! I am ready to participate in further support of my solution. So if new issues are born in view of our discussion, I am ready to do it. |
# Conflicts: # schedule/__init__.py
Thanks a lot for the detailed response! I will take some time to experiment and get my thoughts together. But first I will be working on the 1.0.0 release as detailed in #412. After that I will be back here :) |
Any news regarding the progress of this? |
@SijmenHuizenga @ndbeals I apologize for this looong delay. I promise I'll get back to progress this weekend. |
# Conflicts: # .github/workflows/ci.yml # schedule/__init__.py # setup.py # tox.ini
@SijmenHuizenga Honestly, I like my version more. It is stricter and more structured. That is, the explicit creation of an asynchronous scheduler in the code will explicitly talk about the ability to handle asynchronous tasks, while combining asynchronous and synchronous interfaces creates more risks of using synchronous interface on asynchronous tasks. In the recent changes I went a little further and used inheritance only to share common functionality. Interface classes are no longer divided, thought that one interface returning different types is bad. |
@dbader Can we get this merge? PR has been open for almost 2 years! |
I'm also looking for a way to schedule async tasks. Would love to get an update on if / when this might be merged! |
@dbader @SijmenHuizenga Friendly bump |
It'll be nice if a note was placed in the README indicating no support for this library is being provided any longer |
The library had commits this year, but for some reason the developers don't answer on this PR |
@dbader not sure if this PR is just flying under the radar on your github notifications, but this seriously needs merged |
Hi, is there anything new about this? 4 years pass :) |
@Dorbmon One day |
@gaby sad :( |
Hello @SijmenHuizenga @dbader @connorskees Any chance of getting this merged? Having async support would be very helpful for this library. Thanks! |
How is the progress? Are there other asynchronous scheduling libraries available as alternatives? |
@SijmenHuizenga Friendly ping |
Hey. Added the ability to create a scheduler for asynchronous tasks. The implementation of AsyncScheduler does not affect the existing functionality in any way and backward compatibility is fully supported. Even on python 2.7 the library also continue works. The new functionality has been covered with tests.
P.S. I plan to use this tool in my projects, so the asynchronous part will be developed and maintained by me.