[issue21367] multiprocessing.JoinableQueue requires new kwarg

2016-05-01 Thread Berker Peksag

Changes by Berker Peksag :


--
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> Cryptic error when subclassing multiprocessing classes

___
Python tracker 

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-11-05 Thread larkost

larkost added the comment:

We just got bitten by this issue because we are trying to be compatible across 
2.x and 3.x (including 3.0-3.2). For anyone who runs into the missing 1 
required keyword-only argument: 'ctx' here is an import statement that works:

try:
from multiprocessing import SimpleQueue
except ImportError:
from multiprocessing.queues import SimpleQueue

Replace SimpleQueue with JoinableQueue if you need that. Importing in the other 
order will wind you up in problems in 3.4.2+.

--
nosy: +larkost

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-07-24 Thread Dan O'Reilly

Dan O'Reilly added the comment:

How are you importing JoinableQueue? You'll see this error if you import it 
from multiprocessing.queues instead of directly from multiprocessing. This is 
because multiprocessing.JoinableQueue is now a function:


def JoinableQueue(self, maxsize=0):
'''Returns a queue object'''
from .queues import JoinableQueue
return JoinableQueue(maxsize, ctx=self.get_context())

It provides the required context argument for you. Make sure your application 
is doing from multiprocessing import JoinableQueue, rather than from 
multiprocessing.queues import JoinableQueue.

--
nosy: +dan.oreilly

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-07-24 Thread Dan O'Reilly

Changes by Dan O'Reilly oreil...@gmail.com:


--
components: +Library (Lib) -Interpreter Core
type: compile error - behavior

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-04-27 Thread Lee Clemens

New submission from Lee Clemens:

Not mentioned (at least not specifically) in the release notes, 
multiprocessing.JoinableQueue now requires 'ctx' keyword argument:
  def __init__(self, maxsize=0, *, ctx):

This causes an application calling JoinableQueue() to work with 3.3.2 (my 
single test) to work, but not with 3.4.0

TypeError: __init__() missing 1 required keyword-only argument: 'ctx'

The documentation is also incorrect: 
https://docs.python.org/3.4/library/multiprocessing.html#multiprocessing.JoinableQueue

--
components: Interpreter Core
messages: 217289
nosy: s...@leeclemens.net
priority: normal
severity: normal
status: open
title: multiprocessing.JoinableQueue requires new kwarg
type: compile error
versions: Python 3.4

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-04-27 Thread Lee Clemens

Lee Clemens added the comment:

Same issue (ctx keyword) occurs with multiprocessing.queues.SimpleQueue

--

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



[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-04-27 Thread Claudiu.Popa

Changes by Claudiu.Popa pcmantic...@gmail.com:


--
nosy: +sbt

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