I'm trying to import the os module with this little script:
import sys
sys.path.append("c:\python25\lib")
import osprint os.getcwd()
print " Press Enter to quit . . . "
raw_input()
If I run it with ipy.exe, it works.
If I run it through SharpDevelop, there's an exception:
IronPython.Runtime.Exceptions.ImportException: No module named errno
at DLRCachedCode.Program
at Microsoft.Scripting.ScriptCode.InvokeTarget
at Microsoft.Scripting.ScriptCode.Run
at IronPython.Runtime.PythonContext.CreateModule
at IronPython.Runtime.ModuleLoader.load_module
at Microsoft.Scripting.Actions.MatchCaller.Call3
at Microsoft.Scripting.Actions.CallSite<Microsoft.Func<Microsoft.Scripting.Actions.CallSite,Microsoft.Scripting.Runtime.CodeContext,System.Object,System.Object[,System.Object>>.UpdateAndExecute
at Microsoft.Scripting.Actions.UpdateDelegates.Update3
at IronPython.Runtime.PythonContext.Call
at IronPython.Runtime.Importer.FindAndLoadModuleFromImporter
at IronPython.Runtime.Importer.TryLoadMetaPathModule
at IronPython.Runtime.Importer.ImportTopAbsolute
at IronPython.Runtime.Importer.ImportModule
at IronPython.Runtime.Builtin.__import__
at Microsoft.Scripting.Actions.MatchCaller.Call7
at Microsoft.Scripting.Actions.CallSite<Microsoft.Func<Microsoft.Scripting.Actions.CallSite,Microsoft.Scripting.Runtime.CodeContext,System.Object,System.String,Microsoft.Scripting.IAttributesCollection,Microsoft.Scripting.IAttributesCollection,IronPython.Runtime.PythonTuple,System.Int32,System.Object>>.UpdateAndExecute
at Microsoft.Scripting.Actions.UpdateDelegates.Update7
at IronPython.Runtime.Importer.Import
at IronPython.Runtime.Operations.PythonOps.InitializeModule
at PythonMain.Main