473,394 Members | 2,100 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

PyImport_Import

Hi,
I´m using PyImport_Import function to load a module. After using that module
I call Py_DECREF with the module pointer to free it.
Then I want to load a module with the same filename but different content,
but Python loads the previous loaded module instead.
I verified the symbols of the module and they are the old symbols of the
file.
How can I force to unload the old module so PyImport_Import function loads
the new contents of the file?

Thanks on advance,

Pablo Yabo

Jul 18 '05 #1
0 2080

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

Similar topics

1
by: Andrew Ellem | last post by:
I'm using Python embedded in my app, and I've run into problems creating my own modules. I'm using Python version 2.3 compiled with MSVC .NET (not 2003). When I call Py_InitModule I get the...
8
by: Tero Pihlajakoski | last post by:
Hi, I've been experimenting on embedding Python to a C software, and ran into a little problem with PYTHONPATH (I'm running on linux). Here's the deal: When trying to call...
0
by: Marc Schellens | last post by:
My C++ application crashes at "import_libnumarray()", when I: 1. initalize python and numarray like: .... Py_Initialize(); import_libnumarray(); .... 2 .
3
by: denginere | last post by:
I have a situation where I am embedding python in c++ and calling omniorb within python. c++ -> python -> c++ -> python The python is called using the following // Import the module/script...
0
by: Jim Wallace | last post by:
I'm trying to call a method in a script file given a fully qualified file name, e.g. c:\myscript\test.py. I find that PyImport_Import("test") works fine, with c:\myscript is set as the first item...
0
by: Mark English | last post by:
Basic problem: If there is a C-extension module in a package and it tries to import another python module in the same package without using the fully qualified path, the import fails. Config:...
7
by: Tommy R | last post by:
Hi all pythonistas! I have a problem with my embedding of python inside a c app. very short background I work on a safety critical embedded application that runs on VxWorks. I have...
1
by: Sami Vaisanen | last post by:
This is becoming utterly painful process.... I found out that the return value from "format_exception" function is NOT a list, i.e. PyList_Check() fails. PySequence_Check() succeeds but then...
4
by: castironpi | last post by:
Hello, I'm looking for a one-to-one function from strings to the built-in data types in C. I will be keeping the string in a file. I need the PyTypeObject* back from it. If nothing else I'll...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.