From: Zac Medico Date: Sun, 13 Jul 2008 13:38:24 +0000 (-0000) Subject: Remove all traces of the "poll" parameter for the PollScheduler constructor X-Git-Tag: v2.2_rc2~107 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7e3e07c2fd452c30d846518bdd94129a1594f526;p=portage.git Remove all traces of the "poll" parameter for the PollScheduler constructor since it was only used by can_poll_pty(). svn path=/main/trunk/; revision=11040 --- diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index e03b57072..2375546cf 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -8026,7 +8026,7 @@ class PollScheduler(object): class _sched_iface_class(SlotObject): __slots__ = ("register", "schedule", "unregister") - def __init__(self, poll=None): + def __init__(self): self._max_jobs = 1 self._max_load = None self._jobs = 0 @@ -8034,9 +8034,7 @@ class PollScheduler(object): self._poll_event_handler_ids = {} # Increment id for each new handler. self._event_handler_id = 0 - if poll is None: - poll = create_poll_instance() - self._poll = poll + self._poll = create_poll_instance() self._scheduling = False def _schedule(self): @@ -8141,8 +8139,8 @@ class QueueScheduler(PollScheduler): run() method returns when no tasks remain. """ - def __init__(self, max_jobs=None, max_load=None, poll=None): - PollScheduler.__init__(self, poll=poll) + def __init__(self, max_jobs=None, max_load=None): + PollScheduler.__init__(self) if max_jobs is None: max_jobs = 1 @@ -8216,10 +8214,10 @@ class TaskScheduler(object): add tasks and call run(). The run() method returns when no tasks remain. """ - def __init__(self, max_jobs=None, max_load=None, poll=None): + def __init__(self, max_jobs=None, max_load=None): self._queue = SequentialTaskQueue(max_jobs=max_jobs) self._scheduler = QueueScheduler( - max_jobs=max_jobs, max_load=max_load, poll=poll) + max_jobs=max_jobs, max_load=max_load) self.sched_iface = self._scheduler.sched_iface self.run = self._scheduler.run self._scheduler.add(self._queue)