ironpython3
ironpython3 copied to clipboard
IronPython.Runtime.Exceptions.ImportException: 'No module named 'xml.etree.ElementTree''
Hi,
I am trying to run python script from C# (.net Framework 4.7 Class Library Project) . I am using Visual studio 2022. I have added IronPython 3.4.1 as reference to my project, IronPython.StdLib 3.4.1 also added.
When there are no import statements inside the script it is running fine, when there is an import statement in my script file its throwing an "No Module Found error" even though the module is found under the lib folder.
This error is not specific to a module its giving me error for all the basic modules like Math module also.
I added the Searchpaths as well mapping to the lib folder, but still getting the error. Can you tell me what needs to be changed here?
Let me know if you require more details......
Why are there {
and }
in your libs
path?
Why are there
{
and}
in yourlibs
path?
Hi I modified the syntax now also the error is coming related to Module _sre. I have not used this one in my Script. From where this is popping up?
Can you provide me the correct way to map the libs?
_sre
is a built-in module and not part of the lib. It sounds like IronPython.Modules.dll
is not getting copied to your output folder (same issue as https://github.com/IronLanguages/ironpython3/issues/1778).
_sre
is a built-in module and not part of the lib. It sounds likeIronPython.Modules.dll
is not getting copied to your output folder (same issue as #1778).
Hi, I manually place the dll's in output folder but now i am getting the error related to Import requests. 1.Requests module is not available in ironpython? 2.I can see request.py is available under urllib folder are these same? 3.Any workaround for requests module in ip?
The requests
module is not part of the standard library. You'll have to find a compatible version (e.g. 2.21.0) and make it (and its dependencies) available in your search paths.