Skip to content
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

Synchronization mechanism for non-POSIX #15

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

noc0lour
Copy link

Today I tried to run an application with gnuplotlib on a Windows machine and had to add following patches to make it start.

I still see problems with the polling as under high load the threads probably fire too late but this is a first idea how to solve synchronization for all platforms with one solution.
If this not desirable (select.select is much more elegant) I'd think of modifying the synchronization so this solution is used for Windows (and other platforms which don't support select() and file objects.

Use helper thread to read stderr and block on read instead of
non-crossplatform compatible select()
@noc0lour
Copy link
Author

noc0lour commented Nov 26, 2019

I still need to implement the stop & cleanup on destruction, otherwise the threads will persist over the lifetime of the object.

@dkogan
Copy link
Owner

dkogan commented Nov 26, 2019

Hi. Thanks for working on this. Before we talk about specifics of the patches, some questions:

  1. I don't use windows, so it would be on you to test stuff, and to declare it "done". And preferably I would pass any future bug reports on to you. Is that ok?

  2. Does it work for you after your patches? If not yet, then maybe we shouldn't merge anything yet. You can work in a branch until you get it running. Yes?

@noc0lour
Copy link
Author

To 1. for the near future this would be fine.

To 2. It's not ready to merge yet, I wanted to see if a solution like this is an option at all for you. I will definitely work on it on my own branch until it's ready.

@noc0lour
Copy link
Author

I'm investigating a weird issue where GNUplot hangs after subsequent plotting into it. And then of course gnuplotlib detects correctly that it stopped working.

@dkogan
Copy link
Owner

dkogan commented Nov 27, 2019

OK. I'm definitely interested in getting this working on more platforms, so once you get it running, ping me, and we can get this merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants