Change by Gustavo J. A. M. Carneiro :
--
nosy: +gustavo
___
Python tracker
<https://bugs.python.org/issue4>
___
___
Python-bugs-list mailing list
Unsub
Gustavo J. A. M. Carneiro added the comment:
What a shame, I've seen this error many times as well.
Surely making it BaseException will not break that much code?...
--
nosy: +gustavo
___
Python tracker
<https://bugs.python.org/is
Gustavo J. A. M. Carneiro added the comment:
New patch that:
1. adds assert(sizeof(uuid_t) == 16); to the extension module;
2. fixes the code path when ctypes has to be used instead of the extension
module (needed a bit more refactoring, apologies if it makes the diff harder to
read);
3
Gustavo J. A. M. Carneiro added the comment:
One issue of note is regarding generate_time(). Originally I found ctypes
bindings for this function, so I wrapped it as well in the extension module.
However, it doesn't appear to be
Gustavo J. A. M. Carneiro added the comment:
This patch fixes the Mac OS X issue @haypo pointed out.
--
Added file: http://bugs.python.org/file40865/issue20519_10941v2.diff
___
Python tracker
<http://bugs.python.org/issue20
Gustavo J. A. M. Carneiro added the comment:
I am not using hg anymore, since asyncio migrated to git.
Here's a github PR, does that help?
https://github.com/python/asyncio/pull/260
--
___
Python tracker
<http://bugs.python.org/is
Gustavo J. A. M. Carneiro added the comment:
I was wrong, there still needs to be some cleanup in cancellation, even with
the new approach. But it does solve the out-of-order problem.
I don't know if it should be applied to rc1. I wish I had more time to test.
Up to you
Gustavo J. A. M. Carneiro added the comment:
Sure, just give me a couple of days.
--
___
Python tracker
<http://bugs.python.org/issue23812>
___
___
Python-bug
Gustavo J. A. M. Carneiro added the comment:
I don't think the order for multiple concurrent getters matters that much.
With analogy with the threading case, if multiple threads are blocked get()ing
an item from the same queue, I would not presume to expect anything about the
ordering
Gustavo J. A. M. Carneiro added the comment:
Don't know if it helps, but I made a github pull request for this:
https://github.com/python/asyncio/pull/256
--
___
Python tracker
<http://bugs.python.org/is
Gustavo J. A. M. Carneiro added the comment:
So I uploaded a new patch version fixing a similar problem in put().
--
___
Python tracker
<http://bugs.python.org/issue23
Gustavo J. A. M. Carneiro added the comment:
> - Are there other places where a cancellation can have a similar effect?
> Maybe the same logic in put()?
Hm.. I didn't look, but yes, it does look like it might be affected by the same
issue. I'll try to create a test for
Gustavo J. A. M. Carneiro added the comment:
I created a codereview issue: https://codereview.appspot.com/222930043
--
___
Python tracker
<http://bugs.python.org/issue23
Changes by Gustavo J. A. M. Carneiro :
Added file: http://bugs.python.org/file38741/Issue23812.diff
___
Python tracker
<http://bugs.python.org/issue23812>
___
___
Pytho
New submission from Gustavo J. A. M. Carneiro:
I have a pattern where I read from a queue with a timeout, generally like this:
while True:
reader = asyncio.async(wait_for(queue.get(), 0.1))
try:
item = (yield from reader)
except asyncio.TimeoutError:
reader.cancel()
continue
Gustavo J. A. M. Carneiro added the comment:
Regardless, if you don't mind, take this patch for Python 3.5 to avoid ctypes,
at least in the Linux case (I don't have Windows to test). Creating a proper
extension module is safer and really not that hard...
--
keywords: +p
Gustavo J. A. M. Carneiro added the comment:
I have narrowed it down to one line of code:
ctypes.create_string_buffer(16)
That is enough to create 7 objects that have reference cycles.
[, {'__module__': 'ctypes', '__doc__': None,
'__weakref__': , '
Gustavo J. A. M. Carneiro added the comment:
Well, this isn't a big problem, but I have an application that needs to run
with the GC disabled, since it causes pauses of a couple of seconds each time a
full collection runs (we have a few million objects allocated). I will run the
GC only
New submission from Gustavo J. A. M. Carneiro:
If you try the attached program, you will find that for every iteration the
uuid.uuid4() call generates objects that contain reference cycles and need the
help of the garbage collector. This is not nice. If I make the ctypes module
not able to
Gustavo J. A. M. Carneiro added the comment:
If this problem does not apply to Python 3.x, by all means go ahead and
close it. It probably is a bug, but probably not worth fixing;
workaround is simple enough, and affected extensions have already
adapted to it
Changes by Gustavo J. A. M. Carneiro <[EMAIL PROTECTED]>:
--
nosy: +gustavo
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2663>
__
___
Python-bugs
New submission from Gustavo J. A. M. Carneiro:
Often python extension modules define submodules like this:
static PyObject *
initfoo_xpto(void)
{
PyObject *m;
m = Py_InitModule3("foo.xpto", foo_xpto_functions, NULL);
[...]
return m;
}
PyMODINIT_FUNC
initfoo(void)
{
Gustavo J. A. M. Carneiro added the comment:
I was about to submit the very same patch :-)
I missed PyErr_NewException, but you missed the PyMapping_* methods ;)
Please look into this matter. GCC 4.2 has arrived and it has a new
warning. The code:
char* kwlist[] = { "target",
Changes by Gustavo J. A. M. Carneiro:
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1583>
__
___
Python-bugs-list mailing list
Unsubscribe:
http://mail.python
Gustavo J. A. M. Carneiro added the comment:
The patch looks great.
But I was wondering if there is any chance to export a C API in addition
to the Python one? That is because PyGTK is mostly C, the code that
needs this is C, it would be easier to call a C API.
--
nosy: +gustavo
Gustavo J. A. M. Carneiro added the comment:
> The minimal patch doesn't initialize dummy_char or dummy_c. It's
harmless here, but please fix it. ;)
The variable is called 'dummy' for a reason. The value written or read
is irrevelant...
__
Gustavo J. A. M. Carneiro added the comment:
Minimal patch that just adds the pipe but does not attempt to fix
anything else.
Added file: http://bugs.python.org/file8898/python-signals-minimal.diff
_
Tracker <[EMAIL PROTECTED]>
<http://bugs.p
Gustavo J. A. M. Carneiro added the comment:
"My understanding is that there are some things that the current patch
does not address."
Well, I don't know what those things are, so it's hard for me to address
them. :-)
_
Tracker <[
28 matches
Mail list logo