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

WIP: Handle dispersy returning Deferreds #2416

Closed
wants to merge 69 commits into from

Conversation

lfdversluis
Copy link

@lfdversluis lfdversluis commented Jul 5, 2016

Soon™ Dispersy will return deferreds on many calls. This PR makes sure Tribler can handle those.

The following will happen because of this PR:

The wx GUI will no longer function, I did not push any changes (by accident) to wx, so it will call the functions but completely ignore the deferreds returned.

All tests will run on the nose reactor and uses nose's deferred decorator.

Some tests had blocking behavior which blocked the reactor thread if they ran on the reactor, I have refactored this to use deferreds, which should be only a good thing.

@synctext
Copy link
Member

very nice cleaned up history :-)

@lfdversluis
Copy link
Author

All commits need to be squashed and sorted by file. Moreover, this PR modifies wx which was wrong to begin with. That combined with more than 1.5 weeks of debugging why the allchannel experiment does not perform well (reading logs for several hours a day) makes your mind go dull.

@lfdversluis lfdversluis force-pushed the fix-dispersy-deferreds branch 3 times, most recently from 73fcc15 to a85117f Compare July 22, 2016 15:26
@lfdversluis
Copy link
Author

Darn, it checks out the wrong commit of my Dispersy branch. @whirm @devos50 do you know how to specify the current HEAD of my branch? A log statement in Dispersy is faulty and tests are failing because of that, but this log is already removed in my branch HEAD.

@devos50
Copy link
Contributor

devos50 commented Jul 30, 2016

@lfdversluis
Copy link
Author

It's solved now, had to update my pointer

@lfdversluis
Copy link
Author

retest this please

Linux and mac passed, added storm to windows 32 and 64 bit, let's see how that goes!

@lfdversluis
Copy link
Author

All tests passed 👍

It can now handle deferreds returned by Dispersy et al.
It can now handle deferreds returned by Dispersy et al.
It will now asynchronously send the data as it has to wait for deferreds
to resolve.
It will now send the data asynchronously because it has to resolve
deferreds returned by Dispersy et al.
It will now end the data asynchronously because it has to resolve
deferreds returned by Dispersy et al.
Because this will reraise the exception, causing the program and tests
to fail. It has been dealt with so do not propogate it.
It will now end the data asynchronously because it has to resolve
deferreds returned by Dispersy et al.
It can now handle Deferreds being returned.
It can now handle deferreds returned by Dispersy et al.
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
It now uses nose's deferred decorator
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
Else we would get a reactorAlreadyRunningException
Else we get a reactorAlreadyRunningException
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
Else we get a reactorAlreadyRunningException
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
Now using the nose reactor, nose deferred decorator and the test
now handles deferreds returned by Tribler et al.
To handle deferred returned by Dispersy
To handle deferreds returned by Dispersy
To handle deferreds returned by Tribler and Dispersy
To handle deferreds of Dispersy and Tribler
To handle deferreds returned by the tunnel community
To handle deferreds returned by Dispersy and Tribler
To handle deferreds returned by Dispersy
To handle deferreds returned by Tribler
To handle deferreds returned by Dispersy and Tribler
To handle the deferred returned by Tribler
To handle deferreds returned by Tribler
So Jenkins will checkout the right branch
@lfdversluis
Copy link
Author

And now a few fail 👎

And fixed some racy teardowns/setups
@devos50
Copy link
Contributor

devos50 commented Jan 16, 2018

I will close this issue in favor of IPv8.

@devos50 devos50 closed this Jan 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants