472,808 Members | 2,352 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,808 software developers and data experts.

Need help with extension modules built in debug mode

I've come to the conclusion that posting about Embedded Python on the
Python forums is a complete waste of time. I hope I can get some
useful insights here.

I'm looking for some help with extension modules built using Visual
Studio. I'm using the simple extension module example "hello" (taken
from the "Programming Python" book). I'm building it successfully in
both release and debug mode using a Visual Studio project.

I can successfully import the release build of the module into the
release build of Python. For example:

[E:\]python
Python 2.5 (r25:51908, Sep 19 2006, 09:52:17) [MSC v.1310 32 bit
(Intel)] on win
32
Type "help", "copyright", "credits" or "license" for more
information.
>>import hello
hello.message("Bob")
'Hello, Bob'
>>quit()

I cannot, however, load the debug build of the exact same code (stored
in the exact same location) into the debug build of Python:
[E:\]python_d
Python 2.5.1 (r251:54863, Jun 5 2007, 10:17:28) [MSC v.1400 32
bit (Intel)] on
win32
Type "help", "copyright", "credits" or "license" for more
information.
>>import hello
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named hello
[26848 refs]
>>quit()
[7826 refs]
Does anybody know what tricks or coding magic might be required to get
debug extension modules to load into debug Python?
Aug 26 '08 #1
4 1763
bh****@comcast.net wrote:
I've come to the conclusion that posting about Embedded Python on the
Python forums is a complete waste of time. I hope I can get some
useful insights here.
(just curious, but what are the "Python forums"? isn't the
newsgroup/mailing list *the* Python forum?)

</F>

Aug 26 '08 #2
On Tue, 26 Aug 2008 08:20:44 +0200, Fredrik Lundh
<fr*****@pythonware.comwrote:
>bh****@comcast.net wrote:
>I've come to the conclusion that posting about Embedded Python on the
Python forums is a complete waste of time. I hope I can get some
useful insights here.

(just curious, but what are the "Python forums"? isn't the
newsgroup/mailing list *the* Python forum?)
http://python-forum.org/pythonforum/index.php
Aug 26 '08 #3
En Tue, 26 Aug 2008 01:11:10 -0300, <bh****@comcast.netescribi�:
I've come to the conclusion that posting about Embedded Python on the
Python forums is a complete waste of time. I hope I can get some
useful insights here.

I'm looking for some help with extension modules built using Visual
Studio. I'm using the simple extension module example "hello" (taken
from the "Programming Python" book). I'm building it successfully in
both release and debug mode using a Visual Studio project.

I can successfully import the release build of the module into the
release build of Python. For example:

[E:\]python
Python 2.5 (r25:51908, Sep 19 2006, 09:52:17) [MSC v.1310 32 bit
(Intel)] on win
32
Type "help", "copyright", "credits" or "license" for more
information.
>>import hello
>>hello.message("Bob")
'Hello, Bob'
>>quit()


I cannot, however, load the debug build of the exact same code (stored
in the exact same location) into the debug build of Python:
Does anybody know what tricks or coding magic might be required to get
debug extension modules to load into debug Python?
In debug mode, python looks for hello_d.pyd - NOT hello.pyd.
Note that neither hello.dll nor hello_d.dll are recognized anymore since
version 2.5

--
Gabriel Genellina

Aug 27 '08 #4
On Wed, 27 Aug 2008 00:31:37 -0300, "Gabriel Genellina"
<ga*******@yahoo.com.arwrote:
>In debug mode, python looks for hello_d.pyd - NOT hello.pyd.
Note that neither hello.dll nor hello_d.dll are recognized anymore since
version 2.5
Excellent! Thank you, Gabriel. Just what I was missing.
Aug 27 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Alexander Skwar | last post by:
Hello! I'm having problems getting PHP 4.3.3RC4 successfully to install on my HP-UX 11.00 server. After a (successfull?) compile, "make install" errors out with this error message: ...
0
by: Nick Coghlan | last post by:
Anyone playing with the CPython interpreter's new command line switch might have noticed that it only works with top-level modules (i.e. scripts that are directly on sys.path). If the script is...
4
by: Alexander Eisenhuth | last post by:
Hi alltogether, I use ActivePython 2.4.1 , also the debug part from http://ftp.activestate.com/ActivePython/etc/ and VC 6.0 unter Windows XP. I can't figure out howto debug my c++ extension....
13
by: SpaceCowboy | last post by:
I recently got into a discussion with a co-worker about using enums across a dll interface. He wanted to use chars instead, argueing that depending on compiler settings the size of an enum could...
1
by: E.T. Grey | last post by:
Hi, I have several modules comprising of shared libs (i.e. dlls) and executables. I would like to be able to do the ff: 1). Build each of the modules individually from the command line...
6
by: mark | last post by:
I have an asp.net ecommerce web application on a remote web server. I'm using an Access database on the back end. I've notice a few strange things. When I mimic an multiple user environment by...
4
by: Al Norman | last post by:
We have two separate DLLs that do not interact (directly, at least). One is an MFC extension DLL that was built back in VC++ 6 days (but has been recompiled with VS2005). The other is a DLL that...
0
by: rossabri | last post by:
This topic has been addressed in limited detail in other threads: "sockets don't play nice with new style classes :(" May 14 2005....
3
by: Tony Johansson | last post by:
Hello! We have a C#.ASP.NET web application that runs on a IIS 6. The application contains actually several asp pages but there is no GUI. The application receive an xml file that is processed....
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
linyimin
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
0
by: erikbower65 | last post by:
Here's a concise step-by-step guide for manually installing IntelliJ IDEA: 1. Download: Visit the official JetBrains website and download the IntelliJ IDEA Community or Ultimate edition based on...
0
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
5
by: DJRhino | last post by:
Private Sub CboDrawingID_BeforeUpdate(Cancel As Integer) If = 310029923 Or 310030138 Or 310030152 Or 310030346 Or 310030348 Or _ 310030356 Or 310030359 Or 310030362 Or...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: Mushico | last post by:
How to calculate date of retirement from date of birth

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.