David Heffernan added the comment:
@Steve as a user of Python rather than a Python developer, I don't know what
the process here. I understand the need for a test, and then a fix. And I would
not be surprised if the act of fixing the issue led to a broadening of the test
if the scope o
New submission from David Heffernan :
Starting with Python 3.8 certain ctypes callbacks fail to restore the stack
pointer.
In the repo below, when the DLL is compiled with MSVC under default debug
settings, running the Python script leads to a debug error dialog which says:
Run-Time Check
New submission from David Heffernan :
When creating an instance of CDLL (or indeed WinDLL) for a DLL that is already
loaded, you pass the HMODULE in the handle argument to the constructor.
In older versions of ctypes you could pass None as the name argument when doing
so. However, the
David Heffernan added the comment:
Personally I'd hang this off whether handle has been specified. It seems
pointless to set the mode if you are never going to use it.
--
___
Python tracker
<https://bugs.python.org/is
David Heffernan added the comment:
I would approve of that
On Tue, 7 Jan 2020, 20:43 Steve Dower, wrote:
>
> Steve Dower added the comment:
>
> In that case, we should refactor the init method to check whether handle
> has been specified earlier, so that it's
David Heffernan added the comment:
I just ran into this issue. I'm trying to write code like this:
(ctypes.c_char*bufferLen).from_buffer(buffer)
where buffer is a bytearray. When bufferLen is greater than 2GB I fail foul of
this code in _ctypes.c
long length;
l
David Heffernan added the comment:
Erik,
As you can no doubt guess, this is related to the questions I have been asking
on SO that you have so expertly been answering. Thank you!
When I solved the latest problem, getting at the internal buffer of a
bytearray, I used the code in my previous
New submission from David Heffernan:
Environment:
- Python 2.7.11 from python.org, x64.
- Windows 10 or Windows 8.1
- MSVC 2015
I compiled the most basic embedding example, taken from the Python docs:
#include
int
main(int argc, char *argv[])
{
Py_SetProgramName(argv[0]); /* optional
David Heffernan added the comment:
Note that I've just listed the Windows versions on which I have tested this. I
have not tested on Windows 7 or Vista so do not know whether or not the issue
exists there.
--
___
Python tracker
David Heffernan added the comment:
Thanks Eryk, everything you described happens exactly as you describe it. Much
appreciated.
As it happens, I'm not distributing Python because I want to give my users the
flexibility to use whatever version they please, and with whatever third party
mo
David Heffernan added the comment:
Why was this closed as "not a bug"? Shouldn't it have been closed as a
duplicate?
--
___
Python tracker
<http://bugs.pyt
David Heffernan added the comment:
Thanks for following up Steve, and thanks for changing resolution to dupe.
As for 3.5 and embedding the docs are much the same as 2.7 in that the example
code at https://docs.python.org/3/extending/embedding.html doesn't explicitly
set Python home.
A
12 matches
Mail list logo