[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2019-05-07 Thread Brian Quinlan


Brian Quinlan  added the comment:

How did the experiment go? Are people still interested in this?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2017-10-03 Thread Ben Mather

Ben Mather  added the comment:

@Nathaniel
RE `remove_done_callback`:  This was added as an optimisation to allow the 
`as_completed` iterator to remove callbacks for future that it has visited 
instead of having to store a separate set of visited futures and ignore them 
when their callbacks are triggered.

This matches how the private waiters mechanism works.

It might be worth submitting the core of this change without 
`remove_done_callback` and then discussing it later as a separate optimisation. 
 I will experiment.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2017-10-03 Thread Antoine Pitrou

Change by Antoine Pitrou :


--
versions: +Python 3.7 -Python 3.4, Python 3.5, Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2017-10-03 Thread Ben Mather

Ben Mather  added the comment:

The patch is indeed a little outdated, but I would be happy to pick it and get 
it working again.

First we need a resolution to #22630 though.
Currently calling `cancel` will invoke callbacks, but waiters won't be 
triggered until `set_running_or_notify_cancel` is called.

If both are implemented using the same mechanism, then both will need to be 
cancelled at the same time.  This means that the behaviour of one the other 
will need to be changed in a backwards incompatible way.

Does anyone have a preference for where we should send notification of 
cancellation?
Is the breakage significant enough to kill this patch?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2017-10-03 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

This looks like a good idea.  Unfortunately, the patch is most certainly 
outdated.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22729] concurrent.futures `wait` and `as_completed` depend on private api

2017-10-02 Thread Gregory P. Smith

Gregory P. Smith  added the comment:

any thoughts on this Antoine?

--
nosy: +gregory.p.smith, pitrou
title: `wait` and `as_completed` depend on private api -> concurrent.futures 
`wait` and `as_completed` depend on private api

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com